44 ast_debug(1,
"No SRTP module loaded, can't setup SRTP session.\n");
104 unsigned int force_avp)
110 return using_avpf ?
"RTP/SAVPF" :
"RTP/SAVP";
112 return using_avpf ?
"UDP/TLS/RTP/SAVPF" :
"UDP/TLS/RTP/SAVP";
116 return sdes_active ?
"RTP/SAVPF" :
"RTP/AVPF";
118 return sdes_active ?
"RTP/SAVP" :
"RTP/AVP";
Asterisk main include file. File version handling, generic pbx functions.
#define ast_calloc(num, len)
A wrapper for calloc()
Support for logging to various files, console and syslog Configuration in file logger....
#define ast_debug(level,...)
Log a DEBUG message.
A set of macros to manage forward-linked lists.
#define AST_LIST_NEXT(elm, field)
Returns the next entry in the list after the given entry.
int ast_rtp_engine_srtp_is_registered(void)
struct ast_rtp_engine_dtls * ast_rtp_instance_get_dtls(struct ast_rtp_instance *instance)
Obtain a pointer to the DTLS support present on an RTP instance.
int ast_sdp_crypto_register(struct ast_sdp_crypto_api *api)
Register SDP SRTP crypto processing routines.
const char * ast_sdp_srtp_get_attrib(struct ast_sdp_srtp *srtp, int dtls_enabled, int default_taglen_32)
Get the crypto attribute line for the srtp structure.
struct ast_sdp_crypto * ast_sdp_crypto_alloc(void)
Initialize an return an ast_sdp_crypto struct.
struct ast_sdp_srtp * ast_sdp_srtp_alloc(void)
allocate a ast_sdp_srtp structure
int ast_sdp_crypto_build_offer(struct ast_sdp_crypto *p, int taglen)
Generate an SRTP a=crypto offer.
int ast_sdp_crypto_process(struct ast_rtp_instance *rtp, struct ast_sdp_srtp *srtp, const char *attr)
Parse the a=crypto line from SDP and set appropriate values on the ast_sdp_crypto struct.
void ast_sdp_crypto_unregister(struct ast_sdp_crypto_api *api)
Unregister SDP SRTP crypto processing routines.
void ast_sdp_crypto_destroy(struct ast_sdp_crypto *crypto)
Destroy a previously allocated ast_sdp_crypto struct.
char * ast_sdp_get_rtp_profile(unsigned int sdes_active, struct ast_rtp_instance *instance, unsigned int using_avpf, unsigned int force_avp)
Get the RTP profile in use by a media session.
void ast_sdp_srtp_destroy(struct ast_sdp_srtp *srtp)
free a ast_sdp_srtp structure
static struct ast_sdp_crypto_api * sdp_crypto_api
SRTP and SDP Security descriptions.
Structure that represents the optional DTLS SRTP support within an RTP engine.
int(* active)(struct ast_rtp_instance *instance)
sdp_crypto_parse_offer_cb parse_offer
sdp_crypto_alloc_cb alloc
sdp_crypto_build_offer_cb build_offer
sdp_crypto_destroy_cb dtor
sdp_srtp_get_attr_cb get_attr
structure for secure RTP audio
struct ast_sdp_srtp * next
struct ast_sdp_srtp::@278 sdp_srtp_list
struct ast_sdp_crypto * crypto