From: RĂ©mi Denis-Courmont Date: Thu, 17 May 2007 17:36:59 +0000 (+0000) Subject: Fix incorrect hash size limit X-Git-Tag: 0.9.0-test0~7393 X-Git-Url: https://git.sesse.net/?p=vlc;a=commitdiff_plain;h=3f3025aa794fbdad01150af9401bcb708263488f Fix incorrect hash size limit --- diff --git a/libs/srtp/srtp.c b/libs/srtp/srtp.c index efc434fdd8..ec303da83a 100644 --- a/libs/srtp/srtp.c +++ b/libs/srtp/srtp.c @@ -208,7 +208,7 @@ srtp_create (int encr, int auth, unsigned tag_len, int prf, unsigned flags) return NULL; } - if (tag_len > gcry_md_get_algo_dlen (auth)) + if (tag_len > gcry_md_get_algo_dlen (md)) return NULL; if (prf != SRTP_PRF_AES_CM) @@ -331,6 +331,7 @@ srtp_derive (srtp_session_t *s, const void *key, size_t keylen, || gcry_cipher_setkey (prf, key, keylen)) return -1; +#if 0 /* RTP key derivation */ if (s->kdr != 0) { @@ -344,6 +345,7 @@ srtp_derive (srtp_session_t *s, const void *key, size_t keylen, } } else +#endif memset (r, 0, sizeof (r)); if (proto_derive (&s->rtp, prf, salt, saltlen, r, 6, false))