public Signed(T value, ValidatorKey signer, ValidatorSignature signature) { Value = value; Signer = signer; Signature = signature; }
public bool ValidateSignature(byte[] dataBytes, ValidatorSignature signature) { using var ecdsa = ECDsa.Create(Key); return(ecdsa.VerifyData(dataBytes, signature.Bytes, HashAlgorithmName.SHA256)); }