webkit  2cdf99a9e3038c7e01b3c37e8ad903ecbe5eecf1
https://github.com/WebKit/webkit
srtp.h
Go to the documentation of this file.
1 /*
2  * srtp.h
3  *
4  * interface to libsrtp
5  *
6  * David A. McGrew
7  * Cisco Systems, Inc.
8  */
9 /*
10  *
11  * Copyright (c) 2001-2006, Cisco Systems, Inc.
12  * All rights reserved.
13  *
14  * Redistribution and use in source and binary forms, with or without
15  * modification, are permitted provided that the following conditions
16  * are met:
17  *
18  * Redistributions of source code must retain the above copyright
19  * notice, this list of conditions and the following disclaimer.
20  *
21  * Redistributions in binary form must reproduce the above
22  * copyright notice, this list of conditions and the following
23  * disclaimer in the documentation and/or other materials provided
24  * with the distribution.
25  *
26  * Neither the name of the Cisco Systems, Inc. nor the names of its
27  * contributors may be used to endorse or promote products derived
28  * from this software without specific prior written permission.
29  *
30  * THIS SOFTWARE IS PROVIDED BY THE COPYRIGHT HOLDERS AND CONTRIBUTORS
31  * "AS IS" AND ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT
32  * LIMITED TO, THE IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS
33  * FOR A PARTICULAR PURPOSE ARE DISCLAIMED. IN NO EVENT SHALL THE
34  * COPYRIGHT HOLDERS OR CONTRIBUTORS BE LIABLE FOR ANY DIRECT,
35  * INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES
36  * (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR
37  * SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION)
38  * HOWEVER CAUSED AND ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT,
39  * STRICT LIABILITY, OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE)
40  * ARISING IN ANY WAY OUT OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED
41  * OF THE POSSIBILITY OF SUCH DAMAGE.
42  *
43  */
44 
45 
46 #ifndef SRTP_H
47 #define SRTP_H
48 
49 #include <stdint.h>
50 
51 #ifdef __cplusplus
52 extern "C" {
53 #endif
54 
64 /*
65  * SRTP_MASTER_KEY_LEN is the nominal master key length supported by libSRTP
66  */
67 
68 #define SRTP_MASTER_KEY_LEN 30
69 
70 /*
71  * SRTP_MAX_KEY_LEN is the maximum key length supported by libSRTP
72  */
73 #define SRTP_MAX_KEY_LEN 64
74 
75 /*
76  * SRTP_MAX_TAG_LEN is the maximum tag length supported by libSRTP
77  */
78 
79 #define SRTP_MAX_TAG_LEN 16
80 
89 #define SRTP_MAX_TRAILER_LEN SRTP_MAX_TAG_LEN
90 
91 /*
92  * SRTP_AEAD_SALT_LEN is the length of the SALT values used with
93  * GCM mode. GCM mode requires an IV. The SALT value is used
94  * as part of the IV formation logic applied to each RTP packet.
95  */
96 #define SRTP_AEAD_SALT_LEN 12
97 #define SRTP_AES_128_GCM_KEYSIZE_WSALT SRTP_AEAD_SALT_LEN + 16
98 #define SRTP_AES_192_GCM_KEYSIZE_WSALT SRTP_AEAD_SALT_LEN + 24
99 #define SRTP_AES_256_GCM_KEYSIZE_WSALT SRTP_AEAD_SALT_LEN + 32
100 
101 /*
102  * an srtp_hdr_t represents the srtp header
103  *
104  * in this implementation, an srtp_hdr_t is assumed to be 32-bit aligned
105  *
106  * (note that this definition follows that of RFC 1889 Appendix A, but
107  * is not identical)
108  */
109 
110 #ifndef WORDS_BIGENDIAN
111 
112 /*
113  * srtp_hdr_t represents an RTP or SRTP header. The bit-fields in
114  * this structure should be declared "unsigned int" instead of
115  * "unsigned char", but doing so causes the MS compiler to not
116  * fully pack the bit fields.
117  */
118 
119 typedef struct {
120  unsigned char cc:4; /* CSRC count */
121  unsigned char x:1; /* header extension flag */
122  unsigned char p:1; /* padding flag */
123  unsigned char version:2; /* protocol version */
124  unsigned char pt:7; /* payload type */
125  unsigned char m:1; /* marker bit */
126  uint16_t seq; /* sequence number */
127  uint32_t ts; /* timestamp */
128  uint32_t ssrc; /* synchronization source */
129 } srtp_hdr_t;
130 
131 #else /* BIG_ENDIAN */
132 
133 typedef struct {
134  unsigned char version:2; /* protocol version */
135  unsigned char p:1; /* padding flag */
136  unsigned char x:1; /* header extension flag */
137  unsigned char cc:4; /* CSRC count */
138  unsigned char m:1; /* marker bit */
139  unsigned char pt:7; /* payload type */
140  uint16_t seq; /* sequence number */
141  uint32_t ts; /* timestamp */
142  uint32_t ssrc; /* synchronization source */
143 } srtp_hdr_t;
144 
145 #endif
146 
147 typedef struct {
148  uint16_t profile_specific; /* profile-specific info */
149  uint16_t length; /* number of 32-bit words in extension */
151 
152 
153 /*
154  * srtcp_hdr_t represents a secure rtcp header
155  *
156  * in this implementation, an srtcp header is assumed to be 32-bit
157  * alinged
158  */
159 
160 #ifndef WORDS_BIGENDIAN
161 
162 typedef struct {
163  unsigned char rc:5; /* reception report count */
164  unsigned char p:1; /* padding flag */
165  unsigned char version:2; /* protocol version */
166  unsigned char pt:8; /* payload type */
167  uint16_t len; /* length */
168  uint32_t ssrc; /* synchronization source */
169 } srtcp_hdr_t;
170 
171 typedef struct {
172  unsigned int index:31; /* srtcp packet index in network order! */
173  unsigned int e:1; /* encrypted? 1=yes */
174  /* optional mikey/etc go here */
175  /* and then the variable-length auth tag */
177 
178 
179 #else /* BIG_ENDIAN */
180 
181 typedef struct {
182  unsigned char version:2; /* protocol version */
183  unsigned char p:1; /* padding flag */
184  unsigned char rc:5; /* reception report count */
185  unsigned char pt:8; /* payload type */
186  uint16_t len; /* length */
187  uint32_t ssrc; /* synchronization source */
188 } srtcp_hdr_t;
189 
190 typedef struct {
191  unsigned int version:2; /* protocol version */
192  unsigned int p:1; /* padding flag */
193  unsigned int count:5; /* varies by packet type */
194  unsigned int pt:8; /* payload type */
195  uint16_t length; /* len of uint32s of packet less header */
196 } rtcp_common_t;
197 
198 typedef struct {
199  unsigned int e:1; /* encrypted? 1=yes */
200  unsigned int index:31; /* srtcp packet index */
201  /* optional mikey/etc go here */
202  /* and then the variable-length auth tag */
204 
205 #endif
206 
207 
208 
222 
236 
237 /*
238  * @brief srtp_err_status_t defines error codes.
239  *
240  * The enumeration srtp_err_status_t defines error codes. Note that the
241  * value of srtp_err_status_ok is equal to zero, which can simplify error
242  * checking somewhat.
243  *
244  */
245 typedef enum {
272 
274 typedef struct srtp_ctx_t_ srtp_ctx_t;
275 
276 /*
277  * nota bene: since libSRTP doesn't support the use of the MKI, the
278  * SRTP_MAX_TRAILER_LEN value is just the maximum tag length
279  */
280 
289 typedef enum {
295 
306 typedef struct srtp_crypto_policy_t {
307  srtp_cipher_type_id_t cipher_type;
311  srtp_auth_type_id_t auth_type;
320 
321 
329 typedef enum {
339 
350 typedef struct {
352  unsigned int value;
353 } srtp_ssrc_t;
354 
355 
360 
361 
366 
367 
395 typedef struct srtp_policy_t {
403  unsigned char *key;
405  srtp_ekt_policy_t ekt;
407  unsigned long window_size;
415  int *enc_xtn_hdr;
417  struct srtp_policy_t *next;
418 } srtp_policy_t;
419 
420 
421 
422 
437 
438 
452 
453 
454 
463 
471 
513 srtp_err_status_t srtp_protect(srtp_t ctx, void *rtp_hdr, int *len_ptr);
514 
556 srtp_err_status_t srtp_unprotect(srtp_t ctx, void *srtp_hdr, int *len_ptr);
557 
558 
581 srtp_err_status_t srtp_create(srtp_t *session, const srtp_policy_t *policy);
582 
583 
599 srtp_err_status_t srtp_add_stream(srtp_t session, const srtp_policy_t *policy);
600 
601 
624 srtp_err_status_t srtp_remove_stream(srtp_t session, unsigned int ssrc);
625 
651 srtp_err_status_t srtp_update(srtp_t session, const srtp_policy_t *policy);
652 
675 srtp_err_status_t srtp_update_stream(srtp_t session, const srtp_policy_t *policy);
676 
697 
718 
734 #define srtp_crypto_policy_set_aes_cm_128_hmac_sha1_80(p) srtp_crypto_policy_set_rtp_default(p)
735 
736 
769 
770 
771 
799 
800 
826 
851 
852 
878 
879 
913 
940 
963 
986 
1009 
1032 
1055 
1078 
1079 
1097 
1098 
1099 /*
1100  * @brief identifies a particular SRTP profile
1101  *
1102  * An srtp_profile_t enumeration is used to identify a particular SRTP
1103  * profile (that is, a set of algorithms and parameters). These
1104  * profiles are defined in the DTLS-SRTP draft.
1105  */
1106 
1107 typedef enum {
1115 } srtp_profile_t;
1116 
1117 
1140 
1141 
1142 
1143 
1166 
1170 unsigned int
1172 
1173 
1177 unsigned int
1179 
1192 void
1193 srtp_append_salt_to_key(unsigned char *key, unsigned int bytes_in_key,
1194  unsigned char *salt, unsigned int bytes_in_salt);
1195 
1196 
1197 
1262 srtp_err_status_t srtp_protect_rtcp(srtp_t ctx, void *rtcp_hdr, int *pkt_octet_len);
1263 
1303 srtp_err_status_t srtp_unprotect_rtcp(srtp_t ctx, void *srtcp_hdr, int *pkt_octet_len);
1304 
1333 void
1334 srtp_set_user_data(srtp_t ctx, void *data);
1335 
1352 void*
1353 srtp_get_user_data(srtp_t ctx);
1354 
1402 typedef enum {
1415 } srtp_event_t;
1416 
1425 typedef struct srtp_event_data_t {
1426  srtp_t session;
1427  srtp_stream_t stream;
1428  srtp_event_t event;
1430 
1443 
1458 
1463 const char *srtp_get_version_string(void);
1464 
1469 unsigned int srtp_get_version(void);
1470 
1479 srtp_err_status_t srtp_set_debug_module(char *mod_name, int v);
1480 
1486 
1487 
1491 /* in host order, so outside the #if */
1492 #define SRTCP_E_BIT 0x80000000
1493 /* for byte-access */
1494 #define SRTCP_E_BYTE_BIT 0x80
1495 #define SRTCP_INDEX_MASK 0x7fffffff
1496 
1497 #ifdef __cplusplus
1498 }
1499 #endif
1500 
1501 #endif /* SRTP_H */
Definition: srtp.h:262
uint32_t ssrc
Definition: srtp.h:128
struct srtp_ekt_stream_ctx_t * srtp_ekt_stream_t
points to EKT stream data
Definition: srtp.h:365
GLint GLsizei count
Definition: gl2.h:421
srtp_t session
Definition: srtp.h:1426
void srtp_crypto_policy_set_aes_cm_128_hmac_sha1_32(srtp_crypto_policy_t *p)
srtp_crypto_policy_set_aes_cm_128_hmac_sha1_32() sets a crypto policy structure to a short-authentica...
Definition: srtp.c:2638
Definition: srtp.h:267
void srtp_crypto_policy_set_aes_gcm_128_16_auth(srtp_crypto_policy_t *p)
srtp_crypto_policy_set_aes_gcm_128_16_auth() sets a crypto policy structure to an AEAD encryption pol...
srtp_err_status_t srtp_add_stream(srtp_t session, const srtp_policy_t *policy)
srtp_add_stream() allocates and initializes an SRTP stream within a given SRTP session.
Definition: srtp.c:2284
struct srtp_event_data_t srtp_event_data_t
srtp_event_data_t is the structure passed as a callback to the event handler function ...
unsigned int srtp_get_version(void)
Returns the numeric representation of the library version.
Definition: srtp.c:116
Definition: srtp_priv.h:135
srtp_crypto_policy_t describes a particular crypto policy that can be applied to an SRTP stream...
Definition: srtp.h:306
uint16_t seq
Definition: srtp.h:126
unsigned char version
Definition: srtp.h:123
int cipher_key_len
Definition: srtp.h:309
Definition: srtp.h:1403
DOMString p
Definition: WebCryptoAPI.idl:116
srtp_err_status_t srtp_crypto_policy_set_from_profile_for_rtcp(srtp_crypto_policy_t *policy, srtp_profile_t profile)
srtp_crypto_policy_set_from_profile_for_rtcp() sets a crypto policy structure to the appropriate valu...
Definition: srtp.c:3735
srtp_ssrc_type_t type
Definition: srtp.h:351
uint32_t srtp_auth_type_id_t
An srtp_auth_type_id_t is an identifier for a particular authentication function. ...
Definition: srtp.h:235
Definition: srtp.h:254
srtp_ssrc_type_t
srtp_ssrc_type_t describes the type of an SSRC.
Definition: srtp.h:329
int * enc_xtn_hdr
Definition: srtp.h:415
struct srtp_policy_t srtp_policy_t
represents the policy for an SRTP session.
void srtp_crypto_policy_set_aes_cm_256_hmac_sha1_80(srtp_crypto_policy_t *p)
srtp_crypto_policy_set_aes_cm_256_hmac_sha1_80() sets a crypto policy structure to a encryption and a...
Definition: srtp.c:2709
uint32_t ts
Definition: srtp.h:127
s ts
Definition: plot_neteq_delay.m:55
Definition: srtp.h:249
unsigned int uint32_t
Definition: ptypes.h:105
Definition: srtp.h:268
Definition: srtp.h:266
srtp_crypto_policy_t rtcp
Definition: srtp.h:402
void srtp_crypto_policy_set_null_cipher_hmac_sha1_80(srtp_crypto_policy_t *p)
srtp_crypto_policy_set_null_cipher_hmac_sha1_80() sets a crypto policy structure to an authentication...
Definition: srtp.c:2676
uint16_t length
Definition: srtp.h:149
Definition: srtp.h:251
unsigned int index
Definition: srtp.h:172
struct srtp_policy_t * next
Definition: srtp.h:417
uint16_t profile_specific
Definition: srtp.h:148
srtp_stream_ctx_t * srtp_stream_t
An srtp_stream_t points to an SRTP stream structure.
Definition: srtp.h:451
srtp_event_t event
Definition: srtp.h:1428
Definition: srtp.h:1406
Definition: srtp.h:265
Definition: srtp.h:261
srtp_err_status_t srtp_shutdown(void)
srtp_shutdown() de-initializes the srtp library.
Definition: srtp.c:2192
Definition: srtp.h:1412
Definition: srtp.h:331
const GLfloat * m
Definition: gl2ext.h:850
Definition: srtp.h:250
srtp_err_status_t srtp_create(srtp_t *session, const srtp_policy_t *policy)
srtp_create() allocates and initializes an SRTP session.
Definition: srtp.c:2344
Definition: srtp.h:252
srtp_event_t
srtp_event_t defines events that need to be handled
Definition: srtp.h:1402
Definition: srtp.h:269
uint32_t ssrc
Definition: srtp.h:168
Definition: srtp.h:255
Definition: srtp.h:292
Definition: srtp.h:330
Definition: srtp.h:1112
Definition: srtp.h:256
Definition: srtp.h:270
Definition: srtp.h:1113
uint16_t version
Definition: ssl_lib.c:2731
Definition: ekt.h:89
void * srtp_get_user_data(srtp_t ctx)
srtp_get_user_data() retrieves the pointer to the custom data previously stored with srtp_set_user_da...
Definition: srtp.c:3695
Definition: srtp.h:258
srtp_profile_t
Definition: srtp.h:1107
Definition: srtp.h:260
srtp_ekt_policy_t ekt
Definition: srtp.h:405
Definition: srtp.h:1409
int auth_tag_len
Definition: srtp.h:315
Definition: ekt.h:117
void
Definition: AVFoundationCFSoftLinking.h:81
void srtp_crypto_policy_set_aes_gcm_256_8_auth(srtp_crypto_policy_t *p)
srtp_crypto_policy_set_aes_gcm_256_8_auth() sets a crypto policy structure to an AEAD encryption poli...
srtp_ctx_t * srtp_t
An srtp_t points to an SRTP session structure.
Definition: srtp.h:436
unsigned char * key
Definition: srtp.h:403
Definition: srtp.h:247
srtp_event_data_t is the structure passed as a callback to the event handler function ...
Definition: srtp.h:1425
Definition: srtp.h:293
unsigned char x
Definition: srtp.h:121
OPENSSL_EXPORT const ASN1_OBJECT int const unsigned char int len
Definition: x509.h:1053
Definition: srtp.h:171
unsigned char p
Definition: srtp.h:164
EGLSurface EGLint x
Definition: eglext.h:950
Definition: srtp.h:1111
GLuint index
Definition: gl2.h:383
srtp_cipher_type_id_t cipher_type
Definition: srtp.h:307
Definition: srtp.h:332
EGLContext ctx
Definition: eglext.h:192
srtp_crypto_policy_t rtp
Definition: srtp.h:401
GLenum func
Definition: gl2.h:481
srtp_err_status_t srtp_update(srtp_t session, const srtp_policy_t *policy)
srtp_update() udpates all streams in the session.
Definition: srtp.c:2419
void srtp_crypto_policy_set_null_cipher_hmac_null(srtp_crypto_policy_t *p)
srtp_crypto_policy_set_null_cipher_hmac_null() sets a crypto policy structure to use no encryption or...
Definition: srtp.c:2692
uint16_t len
Definition: srtp.h:167
unsigned short uint16_t
Definition: ptypes.h:97
const char * srtp_get_version_string(void)
Returns the version string of the library.
Definition: srtp.c:108
srtp_stream_t stream
Definition: srtp.h:1427
Definition: srtp.h:259
Definition: srtp.h:162
unsigned int srtp_profile_get_master_key_length(srtp_profile_t profile)
returns the master key length for a given SRTP profile
Definition: srtp.c:3773
unsigned char version
Definition: srtp.h:165
Definition: srtp.h:119
Definition: srtp.h:1108
pt
Definition: parse_delay_file.m:32
srtp_err_status_t srtp_install_event_handler(srtp_event_handler_func_t func)
sets the event handler to the function supplied by the caller.
Definition: srtp.c:1062
void srtp_crypto_policy_set_aes_gcm_128_8_auth(srtp_crypto_policy_t *p)
srtp_crypto_policy_set_aes_gcm_128_8_auth() sets a crypto policy structure to an AEAD encryption poli...
void srtp_crypto_policy_set_aes_cm_256_hmac_sha1_32(srtp_crypto_policy_t *p)
srtp_crypto_policy_set_aes_cm_256_hmac_sha1_32() sets a crypto policy structure to a short-authentica...
Definition: srtp.c:2725
srtp_ssrc_t ssrc
Definition: srtp.h:396
int enc_xtn_hdr_count
Definition: srtp.h:416
srtp_err_status_t srtp_update_stream(srtp_t session, const srtp_policy_t *policy)
srtp_update_stream() udpates a SRTP stream.
Definition: srtp.c:2575
Definition: srtp.h:1114
const GLfloat * v
Definition: gl2.h:514
srtp_err_status_t srtp_protect(srtp_t ctx, void *rtp_hdr, int *len_ptr)
srtp_protect() is the Secure RTP sender-side packet processing function.
Definition: srtp.h:253
unsigned char m
Definition: srtp.h:125
uint32_t srtp_cipher_type_id_t
A srtp_cipher_type_id_t is an identifier for a particular cipher type.
Definition: srtp.h:221
srtp_err_status_t srtp_init(void)
srtp_init() initializes the srtp library.
Definition: srtp.c:2175
Definition: srtp.h:257
Definition: srtp_priv.h:108
srtp_err_status_t srtp_unprotect_rtcp(srtp_t ctx, void *srtcp_hdr, int *pkt_octet_len)
srtp_unprotect_rtcp() is the Secure RTCP receiver-side packet processing function.
Definition: srtp.c:3415
void srtp_append_salt_to_key(unsigned char *key, unsigned int bytes_in_key, unsigned char *salt, unsigned int bytes_in_salt)
appends the salt to the key
Definition: srtp.c:3768
EGLStreamKHR EGLint EGLint EGLint const void * data
Definition: eglext.h:984
void srtp_crypto_policy_set_rtcp_default(srtp_crypto_policy_t *p)
srtp_crypto_policy_set_rtcp_default() sets a crypto policy structure to the SRTP default policy for R...
Definition: srtp.c:2626
srtp_err_status_t srtp_set_debug_module(char *mod_name, int v)
srtp_set_debug_module(mod_name, v)
Definition: srtp.c:3827
srtp_auth_type_id_t auth_type
Definition: srtp.h:311
unsigned char pt
Definition: srtp.h:166
void srtp_set_user_data(srtp_t ctx, void *data)
srtp_set_user_data() stores the given pointer into the SRTP session for later retrieval.
Definition: srtp.c:3690
Definition: srtp.h:1110
Definition: srtp.h:147
unsigned int e
Definition: srtp.h:173
void srtp_crypto_policy_set_aes_cm_128_null_auth(srtp_crypto_policy_t *p)
srtp_crypto_policy_set_aes_cm_128_null_auth() sets a crypto policy structure to an encryption-only po...
Definition: srtp.c:2657
unsigned int srtp_profile_get_master_salt_length(srtp_profile_t profile)
returns the master salt length for a given SRTP profile
Definition: srtp.c:3799
srtp_err_status_t srtp_protect_rtcp(srtp_t ctx, void *rtcp_hdr, int *pkt_octet_len)
srtp_protect_rtcp() is the Secure RTCP sender-side packet processing function.
Definition: srtp.c:3218
unsigned char pt
Definition: srtp.h:124
srtp_sec_serv_t
srtp_sec_serv_t describes a set of security services.
Definition: srtp.h:289
void srtp_crypto_policy_set_aes_cm_256_null_auth(srtp_crypto_policy_t *p)
srtp_crypto_policy_set_aes_cm_256_null_auth() sets a crypto policy structure to an encryption-only po...
Definition: srtp.c:2745
struct A s
struct srtp_crypto_policy_t srtp_crypto_policy_t
srtp_crypto_policy_t describes a particular crypto policy that can be applied to an SRTP stream...
Definition: srtp.h:335
Definition: srtp.h:246
Definition: srtp.h:263
srtp_err_status_t srtp_list_debug_modules(void)
srtp_list_debug_modules() outputs a list of debugging modules
Definition: srtp.c:3832
unsigned int value
Definition: srtp.h:352
unsigned char cc
Definition: srtp.h:120
unsigned long window_size
Definition: srtp.h:407
represents the policy for an SRTP session.
Definition: srtp.h:395
void srtp_crypto_policy_set_aes_gcm_256_8_only_auth(srtp_crypto_policy_t *p)
srtp_crypto_policy_set_aes_gcm_256_8_only_auth() sets a crypto policy structure to an AEAD authentica...
void srtp_crypto_policy_set_rtp_default(srtp_crypto_policy_t *p)
srtp_crypto_policy_set_rtp_default() sets a crypto policy structure to the SRTP default policy for RT...
Definition: srtp.c:2614
srtp_err_status_t srtp_dealloc(srtp_t s)
srtp_dealloc() deallocates storage for an SRTP session context.
Definition: srtp.c:2249
unsigned char p
Definition: srtp.h:122
srtp_err_status_t srtp_unprotect(srtp_t ctx, void *srtp_hdr, int *len_ptr)
srtp_unprotect() is the Secure RTP receiver-side packet processing function.
DOMString e
Definition: WebCryptoAPI.idl:115
srtp_err_status_t
Definition: srtp.h:245
const Profile profile
Definition: profile_level_id.cc:65
Definition: srtp.h:1109
struct srtp_ekt_policy_ctx_t * srtp_ekt_policy_t
points to an EKT policy
Definition: srtp.h:359
Definition: srtp.h:290
void srtp_crypto_policy_set_aes_gcm_256_16_auth(srtp_crypto_policy_t *p)
srtp_crypto_policy_set_aes_gcm_256_16_auth() sets a crypto policy structure to an AEAD encryption pol...
int allow_repeat_tx
Definition: srtp.h:409
Definition: srtp.h:248
srtp_err_status_t srtp_crypto_policy_set_from_profile_for_rtp(srtp_crypto_policy_t *policy, srtp_profile_t profile)
srtp_crypto_policy_set_from_profile_for_rtp() sets a crypto policy structure to the appropriate value...
Definition: srtp.c:3705
srtp_err_status_t srtp_remove_stream(srtp_t session, unsigned int ssrc)
srtp_remove_stream() deallocates an SRTP stream.
unsigned char rc
Definition: srtp.h:163
CFArrayRef CFTypeRef key
Definition: AVFoundationCFSoftLinking.h:129
srtp_sec_serv_t sec_serv
Definition: srtp.h:317
void() srtp_event_handler_func_t(srtp_event_data_t *data)
srtp_event_handler_func_t is the function prototype for the event handler.
Definition: srtp.h:1442
int auth_key_len
Definition: srtp.h:313
void srtp_crypto_policy_set_aes_gcm_128_8_only_auth(srtp_crypto_policy_t *p)
srtp_crypto_policy_set_aes_gcm_128_8_only_auth() sets a crypto policy structure to an AEAD authentica...
Definition: srtp.h:291
GLuint GLsizei GLsizei * length
Definition: gl2.h:435
An srtp_ssrc_t represents a particular SSRC value, or a `wildcard&#39; SSRC.
Definition: srtp.h:350
Definition: srtp.h:264