End of Life Ruby 3.0 has reached end of life and gets no more fixes. Switch to Ruby 4.0 →
instance method
OpenSSL::PKey::EC#dsa_verify_asn1
key.dsa_verify_asn1(data, sig) => true or false
ext/openssl/ossl_pkey_ec.c
View on GitHub ↗
static VALUE ossl_ec_key_dsa_verify_asn1(VALUE self, VALUE data, VALUE sig)
{
EC_KEY *ec;
GetEC(self, ec);
StringValue(data);
StringValue(sig);
switch (ECDSA_verify(0, (unsigned char *)RSTRING_PTR(data), RSTRING_LENINT(data),
(unsigned char *)RSTRING_PTR(sig), RSTRING_LENINT(sig), ec)) {
case 1:
return Qtrue;
case 0:
return Qfalse;
default:
ossl_raise(eECError, "ECDSA_verify");
}
}
See the OpenSSL documentation for ECDSA_verify()
See also
#dsa_sign_asn1
#export
#dh_compute_key
#generate_key
also in
4.1 · 4.0 · 3.4 · 3.3 · 3.2 · 3.1