[asterisk-commits] kmoore: branch 11 r384049 - in /branches/11: ./ res/res_rtp_asterisk.c

SVN commits to the Asterisk project asterisk-commits at lists.digium.com
Wed Mar 27 12:06:11 CDT 2013


Author: kmoore
Date: Wed Mar 27 12:06:07 2013
New Revision: 384049

URL: http://svnview.digium.com/svn/asterisk?view=rev&rev=384049
Log:
Fix white noise on SRTP decryption

When res_rtp_asterisk.c was altered to avoid attempting to apply
unprotect algorithms to non-audio RTP packets, the test used was
incorrect. This caused the audio packets to not be decrypted and
resulted in loud white noise on the other endpoint (or both endpoints
depending on the call legs involved). The test now properly checks the
version field in the RTP header to ensure that RTP and RTCP are
decrypted while other types of packets are not.

(closes issue ASTERISK-21323)
Reported by: andrea
Tested by: Kinsey Moore, andrea, John Bigelow
Patches:
    whitenoise_fix.diff uploaded by Kinsey Moore
........

Merged revisions 384048 from http://svn.asterisk.org/svn/asterisk/branches/1.8

Modified:
    branches/11/   (props changed)
    branches/11/res/res_rtp_asterisk.c

Propchange: branches/11/
------------------------------------------------------------------------------
Binary property 'branch-1.8-merged' - no diff available.

Modified: branches/11/res/res_rtp_asterisk.c
URL: http://svnview.digium.com/svn/asterisk/branches/11/res/res_rtp_asterisk.c?view=diff&rev=384049&r1=384048&r2=384049
==============================================================================
--- branches/11/res/res_rtp_asterisk.c (original)
+++ branches/11/res/res_rtp_asterisk.c Wed Mar 27 12:06:07 2013
@@ -1479,7 +1479,7 @@
 		rtp->passthrough = 0;
 	}
 
-	if ((*in > 1) && res_srtp && srtp && res_srtp->unprotect(srtp, buf, &len, rtcp) < 0) {
+	if ((*in & 0xC0) && res_srtp && srtp && res_srtp->unprotect(srtp, buf, &len, rtcp) < 0) {
 	   return -1;
 	}
 




More information about the asterisk-commits mailing list