X-Git-Url: https://git.sesse.net/?a=blobdiff_plain;f=libs%2Fsrtp%2Fsrtp.c;h=60c07b6f72bfa0b7e25eecef27fed0c5aa292ded;hb=2a0e2bd242f7dc7cda4ee096e58f42d13db9803f;hp=ec303da83ab5470d1f1981fce45b66e36fb8dcc0;hpb=1761128257afdf85afd24a126bf469dcdd490985;p=vlc diff --git a/libs/srtp/srtp.c b/libs/srtp/srtp.c index ec303da83a..60c07b6f72 100644 --- a/libs/srtp/srtp.c +++ b/libs/srtp/srtp.c @@ -651,7 +651,16 @@ srtp_recv (srtp_session_t *s, uint8_t *buf, size_t *lenp) rcc = roc; const uint8_t *tag = rtp_digest (s, buf, len, rcc); - if (memcmp (buf + len + roc_len, tag, s->tag_len)) +#if 0 + printf ("Computed: 0x"); + for (unsigned i = 0; i < tag_len; i++) + printf ("%02x", tag[i]); + printf ("\nReceived: 0x"); + for (unsigned i = 0; i < tag_len; i++) + printf ("%02x", buf[len + roc_len + i]); + puts (""); +#endif + if (memcmp (buf + len + roc_len, tag, tag_len)) return EACCES; if (roc_len)