[asterisk-commits] dlee: branch 11 r380043 - /branches/11/channels/sip/sdp_crypto.c

SVN commits to the Asterisk project asterisk-commits at lists.digium.com
Thu Jan 24 10:39:36 CST 2013


Author: dlee
Date: Thu Jan 24 10:39:33 2013
New Revision: 380043

URL: http://svnview.digium.com/svn/asterisk?view=rev&rev=380043
Log:
Corrected crypto tag in SDP ANSWER for SRTP.

When Asterisk responds with an SDP ANSWER for SRTP, it had the code to
correctly fill in the cryot data, which was overwritten by a call to
sdb_crypto_offer. Corrected the situation by changing sdp_crypto_offer
to not replacing crypto data if it already exists.

(closes issue ASTERISK-20849)
Reported by: José Luis Millán
Tested by: Iñaki Baz Castillo
Patches:
	fix_sdp_crypto_tags.diff uploaded by Pedro Kiefer (license 6407)

Modified:
    branches/11/channels/sip/sdp_crypto.c

Modified: branches/11/channels/sip/sdp_crypto.c
URL: http://svnview.digium.com/svn/asterisk/branches/11/channels/sip/sdp_crypto.c?view=diff&rev=380043&r1=380042&r2=380043
==============================================================================
--- branches/11/channels/sip/sdp_crypto.c (original)
+++ branches/11/channels/sip/sdp_crypto.c Thu Jan 24 10:39:33 2013
@@ -291,7 +291,7 @@
 	char crypto_buf[128];
 
 	if (p->a_crypto) {
-		ast_free(p->a_crypto);
+		return 0;
 	}
 
 	if (snprintf(crypto_buf, sizeof(crypto_buf), "a=crypto:1 AES_CM_128_HMAC_SHA1_%i inline:%s\r\n",




More information about the asterisk-commits mailing list