cisco / libsrtp

Library for SRTP (Secure Realtime Transport Protocol)
Other
1.19k stars 472 forks source link

rtp_decoder support for MKI and RCCm3 ROC field #572

Open paulr227 opened 2 years ago

paulr227 commented 2 years ago

MKI: support for MKI was added to libsrtp in 2.1.0, however the support wasn't extended to rtp_decder. These changes update rtp_decoder to use the srtp_unprotect_mki() and srtp_unprotect_rtcp_mki() APIs and to accept a new argument for specifying the MKI of the master key passed in the stream policy provided to libsrtp.

RCCm3: is one of the three integrity transforms specified in RFC4771 to support synchronisation of sender and receiver ROC by inclusion of the sender's ROC value in the optional authentication field at the end of the SRTP packet. RCCm3 is the only unauthenticated transform of the three, and therefore the only one that is supported without changes within libsrtp itself. A new rtp_decoder argument is introduced to specify the ROC transmission rate parameter. Any future support for RCCm1 and RCCm2 would be compatible with this argument.

New arguments introduced: -i sets the MKI given in hexadecimal -n RFC4771 ROC transmission rate (assumes RCCm3)

pabuhler commented 2 years ago

@paulr227 are you able to elaborate on your use of rtp_decoder? I always wondered if it was actually used.