Update ssl library to support EVP_PKEY MAC API. Include generic MAC support.
[openssl.git] / ssl / s2_pkt.c
index a10929a..e6d5d09 100644 (file)
@@ -246,7 +246,7 @@ static int ssl2_read_internal(SSL *s, void *buf, int len, int peek)
                        }
                else
                        {
-                       mac_size=EVP_MD_size(s->read_hash);
+                       mac_size=EVP_MD_CTX_size(s->read_hash);
                        OPENSSL_assert(mac_size <= MAX_MAC_SIZE);
                        s->s2->mac_data=p;
                        s->s2->ract_data= &p[mac_size];
@@ -529,7 +529,7 @@ static int do_ssl_write(SSL *s, const unsigned char *buf, unsigned int len)
        if (s->s2->clear_text)
                mac_size=0;
        else
-               mac_size=EVP_MD_size(s->write_hash);
+               mac_size=EVP_MD_CTX_size(s->write_hash);
 
        /* lets set the pad p */
        if (s->s2->clear_text)