Lines Matching refs:ctx
77 static int do_mac(EVP_MAC_CTX *ctx, unsigned char *tmp, BIO *in,
84 if (!EVP_MAC_init(ctx, NULL, 0, NULL))
86 if (EVP_MAC_CTX_get_mac_size(ctx) > outsz)
89 if (i < 0 || !EVP_MAC_update(ctx, tmp, i))
93 if (!EVP_MAC_final(ctx, out, out_len, outsz))
303 EVP_MAC_CTX *ctx = NULL, *ctx2 = NULL;
440 ctx = EVP_MAC_CTX_new(mac);
441 if (ctx == NULL) {
454 if (!EVP_MAC_CTX_set_params(ctx, params)) {
464 ctx2 = EVP_MAC_CTX_dup(ctx);
470 if (!do_mac(ctx, read_buffer, module_bio, module_mac, &module_mac_len))
536 EVP_MAC_CTX_free(ctx);