From: Jonathan L. <jon...@us...> - 2010-06-01 18:19:12
|
Update of /cvsroot/srtp/srtp/srtp In directory sfp-cvsdas-3.v30.ch3.sourceforge.com:/tmp/cvs-serv2207 Modified Files: srtp.c Log Message: Patch from Jaap Keuter: Call cipher_decrypt() instead of cipher_encrypt() in srtp_unprotect and srtp_unprotect_rtcp. Makes no difference for AES_ICM, but fixes asymmetric ciphers. Index: srtp.c =================================================================== RCS file: /cvsroot/srtp/srtp/srtp/srtp.c,v retrieving revision 1.33 retrieving revision 1.34 diff -C2 -d -r1.33 -r1.34 *** srtp.c 27 May 2010 19:22:25 -0000 1.33 --- srtp.c 1 Jun 2010 18:19:04 -0000 1.34 *************** *** 1159,1165 **** } ! /* if we're encrypting, add keystream into ciphertext */ if (enc_start) { ! status = cipher_encrypt(stream->rtp_cipher, (uint8_t *)enc_start, &enc_octet_len); if (status) --- 1159,1165 ---- } ! /* if we're decrypting, add keystream into ciphertext */ if (enc_start) { ! status = cipher_decrypt(stream->rtp_cipher, (uint8_t *)enc_start, &enc_octet_len); if (status) *************** *** 1965,1969 **** /* if we're decrypting, exor keystream into the message */ if (enc_start) { ! status = cipher_encrypt(stream->rtcp_cipher, (uint8_t *)enc_start, &enc_octet_len); if (status) --- 1965,1969 ---- /* if we're decrypting, exor keystream into the message */ if (enc_start) { ! status = cipher_decrypt(stream->rtcp_cipher, (uint8_t *)enc_start, &enc_octet_len); if (status) |