Lines Matching refs:sig
33 static int sign(OSSL_LIB_CTX *libctx, unsigned char **sig, size_t *sig_len) in sign() argument
41 *sig = NULL; in sign()
86 *sig = OPENSSL_malloc(*sig_len); in sign()
87 if (*sig == NULL) { in sign()
93 if (EVP_DigestSignFinal(mctx, *sig, sig_len) == 0) { in sign()
104 OPENSSL_free(*sig); in sign()
114 static int verify(OSSL_LIB_CTX *libctx, const unsigned char *sig, size_t sig_len) in verify() argument
158 if (EVP_DigestVerifyFinal(mctx, sig, sig_len) == 0) { in verify()
175 unsigned char *sig = NULL; in main() local
178 if (sign(libctx, &sig, &sig_len) == 0) in main()
181 if (verify(libctx, sig, sig_len) == 0) in main()
188 OPENSSL_free(sig); in main()