verify(p1, p2, p3) public

No documentation

This method has no description. You can help the Ruby community by adding new notes.

Hide source
static VALUE
ossl_pkey_verify(VALUE self, VALUE digest, VALUE sig, VALUE data)
{
    EVP_PKEY *pkey;
    EVP_MD_CTX ctx;

    GetPKey(self, pkey);
    EVP_VerifyInit(&ctx, GetDigestPtr(digest));
    StringValue(sig);
    StringValue(data);
    EVP_VerifyUpdate(&ctx, RSTRING_PTR(data), RSTRING_LEN(data));
    switch (EVP_VerifyFinal(&ctx, (unsigned char *)RSTRING_PTR(sig), RSTRING_LEN(sig), pkey)) {
    case 0:
        return Qfalse;
    case 1:
        return Qtrue;
    default:
        ossl_raise(ePKeyError, NULL);
    }
    return Qnil; /* dummy */
}
Register or log in to add new notes.