37 #ifndef RTPSECURESESSION_H 39 #define RTPSECURESESSION_H 41 #include "rtpconfig.h" 43 #ifdef RTP_SUPPORT_SRTP 47 #ifdef RTP_SUPPORT_THREAD 48 #include <jthread/jthread.h> 49 #endif // RTP_SUPPORT_THREAD 87 int InitializeSRTPContext();
94 srtp_ctx_t *LockSRTPContext();
98 int UnlockSRTPContext();
102 int GetLastLibSRTPError();
104 void SetLastLibSRTPError(
int err);
109 virtual void OnErrorChangeIncomingData(
int errcode,
int libsrtperrorcode);
111 int OnChangeRTPOrRTCPData(
const void *origdata,
size_t origlen,
bool isrtp,
void **senddata,
size_t *sendlen);
113 void OnSentRTPOrRTCPData(
void *senddata,
size_t sendlen,
bool isrtp);
115 int encryptData(uint8_t *pData,
int &dataLength,
bool rtp);
116 int decryptRawPacket(
RTPRawPacket *rawpack,
int *srtpError);
118 srtp_ctx_t *m_pSRTPContext;
120 #ifdef RTP_SUPPORT_THREAD 121 jthread::JMutex m_srtpLock;
122 #endif // RTP_SUPPORT_THREAD 129 #endif // RTP_SUPPORT_SRTP 131 #endif // RTPSECURESESSION_H High level class for using RTP.
Definition: rtpsession.h:80
This class is used by the transmission component to store the incoming RTP and RTCP data in...
Definition: rtprawpacket.h:51
virtual void OnErrorChangeIncomingData(int errcode, int libsrtperrorcode)
In case the reimplementation of OnChangeIncomingData (which may take place in a background thread) en...
Definition: rtpsecuresession.h:125
Interface for generating random numbers.
Definition: rtprandom.h:51
Definition: rtpfaketransmitter.h:64
A memory manager.
Definition: rtpmemorymanager.h:150
RTPSession derived class that serves as a base class for an SRTP implementation.
Definition: rtpsecuresession.h:77