diff --git a/crypto/test/cipher_driver.c b/crypto/test/cipher_driver.c index 5939e818e..0ae6fe34a 100644 --- a/crypto/test/cipher_driver.c +++ b/crypto/test/cipher_driver.c @@ -134,9 +134,9 @@ int main(int argc, char *argv[]) }; /* clang-format on */ int q; - unsigned do_timing_test = 0; - unsigned do_validation = 0; - unsigned do_array_timing_test = 0; + bool do_timing_test = false; + bool do_validation = false; + bool do_array_timing_test = false; /* process input arguments */ while (1) { @@ -145,13 +145,13 @@ int main(int argc, char *argv[]) break; switch (q) { case 't': - do_timing_test = 1; + do_timing_test = true; break; case 'v': - do_validation = 1; + do_validation = true; break; case 'a': - do_array_timing_test = 1; + do_array_timing_test = true; break; default: usage(argv[0]); diff --git a/include/srtp.h b/include/srtp.h index 33082cba9..dd94e3a47 100644 --- a/include/srtp.h +++ b/include/srtp.h @@ -47,6 +47,7 @@ #include #include +#include #ifdef __cplusplus extern "C" { @@ -339,7 +340,7 @@ typedef struct srtp_policy_t { unsigned long num_master_keys; /** Number of master keys */ unsigned long window_size; /**< The window size to use for replay */ /**< protection. */ - int allow_repeat_tx; /**< Whether retransmissions of */ + bool allow_repeat_tx; /**< Whether retransmissions of */ /**< packets with the same sequence */ /**< number are allowed. */ /**< (Note that such repeated */ @@ -474,7 +475,7 @@ srtp_err_status_t srtp_protect(srtp_t ctx, void *rtp_hdr, size_t *len_ptr); srtp_err_status_t srtp_protect_mki(srtp_ctx_t *ctx, void *rtp_hdr, size_t *pkt_octet_len, - unsigned int use_mki, + bool use_mki, unsigned int mki_index); /** @@ -568,7 +569,7 @@ srtp_err_status_t srtp_unprotect(srtp_t ctx, void *srtp_hdr, size_t *len_ptr); srtp_err_status_t srtp_unprotect_mki(srtp_t ctx, void *srtp_hdr, size_t *len_ptr, - unsigned int use_mki); + bool use_mki); /** * @brief srtp_create() allocates and initializes an SRTP session. @@ -1382,7 +1383,7 @@ srtp_err_status_t srtp_protect_rtcp(srtp_t ctx, srtp_err_status_t srtp_protect_rtcp_mki(srtp_t ctx, void *rtcp_hdr, size_t *pkt_octet_len, - unsigned int use_mki, + bool use_mki, unsigned int mki_index); /** @@ -1475,7 +1476,7 @@ srtp_err_status_t srtp_unprotect_rtcp(srtp_t ctx, srtp_err_status_t srtp_unprotect_rtcp_mki(srtp_t ctx, void *srtcp_hdr, size_t *pkt_octet_len, - unsigned int use_mki); + bool use_mki); /** * @} @@ -1702,7 +1703,7 @@ srtp_err_status_t srtp_install_log_handler(srtp_log_handler_func_t func, * */ srtp_err_status_t srtp_get_protect_trailer_length(srtp_t session, - uint32_t use_mki, + bool use_mki, uint32_t mki_index, size_t *length); @@ -1719,7 +1720,7 @@ srtp_err_status_t srtp_get_protect_trailer_length(srtp_t session, * */ srtp_err_status_t srtp_get_protect_rtcp_trailer_length(srtp_t session, - uint32_t use_mki, + bool use_mki, uint32_t mki_index, size_t *length); diff --git a/include/srtp_priv.h b/include/srtp_priv.h index c8b81e109..e0dd8dad9 100644 --- a/include/srtp_priv.h +++ b/include/srtp_priv.h @@ -140,7 +140,7 @@ typedef struct srtp_stream_ctx_t_ { srtp_rdb_t rtcp_rdb; srtp_sec_serv_t rtcp_services; direction_t direction; - int allow_repeat_tx; + bool allow_repeat_tx; int *enc_xtn_hdr; int enc_xtn_hdr_count; uint32_t pending_roc; diff --git a/srtp/srtp.c b/srtp/srtp.c index fd3424a56..f6fca5103 100644 --- a/srtp/srtp.c +++ b/srtp/srtp.c @@ -883,7 +883,7 @@ static inline size_t full_key_length(const srtp_cipher_type_t *cipher) srtp_session_keys_t *srtp_get_session_keys_with_mki_index( srtp_stream_ctx_t *stream, - unsigned int use_mki, + bool use_mki, unsigned int mki_index) { if (use_mki) { @@ -898,7 +898,7 @@ srtp_session_keys_t *srtp_get_session_keys_with_mki_index( size_t srtp_inject_mki(uint8_t *mki_tag_location, srtp_session_keys_t *session_keys, - unsigned int use_mki) + bool use_mki) { size_t mki_size = 0; @@ -1371,11 +1371,6 @@ static srtp_err_status_t srtp_stream_init(srtp_stream_ctx_t *srtp, srtp_rdb_init(&srtp->rtcp_rdb); /* initialize allow_repeat_tx */ - /* guard against uninitialized memory: allow only 0 or 1 here */ - if (p->allow_repeat_tx != 0 && p->allow_repeat_tx != 1) { - srtp_rdbx_dealloc(&srtp->rtp_rdbx); - return srtp_err_status_bad_param; - } srtp->allow_repeat_tx = p->allow_repeat_tx; /* DAM - no RTCP key limit at present */ @@ -1785,7 +1780,7 @@ static srtp_err_status_t srtp_protect_aead(srtp_ctx_t *ctx, void *rtp_hdr, size_t *pkt_octet_len, srtp_session_keys_t *session_keys, - unsigned int use_mki) + bool use_mki) { srtp_hdr_t *hdr = (srtp_hdr_t *)rtp_hdr; uint8_t *enc_start; /* pointer to start of encrypted portion */ @@ -1958,7 +1953,7 @@ static srtp_err_status_t srtp_unprotect_aead(srtp_ctx_t *ctx, size_t *pkt_octet_len, srtp_session_keys_t *session_keys, size_t mki_size, - int advance_packet_index) + bool advance_packet_index) { srtp_hdr_t *hdr = (srtp_hdr_t *)srtp_hdr; uint8_t *enc_start; /* pointer to start of encrypted portion */ @@ -2154,13 +2149,13 @@ srtp_err_status_t srtp_protect(srtp_ctx_t *ctx, void *rtp_hdr, size_t *pkt_octet_len) { - return srtp_protect_mki(ctx, rtp_hdr, pkt_octet_len, 0, 0); + return srtp_protect_mki(ctx, rtp_hdr, pkt_octet_len, false, 0); } srtp_err_status_t srtp_protect_mki(srtp_ctx_t *ctx, void *rtp_hdr, size_t *pkt_octet_len, - unsigned int use_mki, + bool use_mki, unsigned int mki_index) { srtp_hdr_t *hdr = (srtp_hdr_t *)rtp_hdr; @@ -2476,13 +2471,13 @@ srtp_err_status_t srtp_unprotect(srtp_ctx_t *ctx, void *srtp_hdr, size_t *pkt_octet_len) { - return srtp_unprotect_mki(ctx, srtp_hdr, pkt_octet_len, 0); + return srtp_unprotect_mki(ctx, srtp_hdr, pkt_octet_len, false); } srtp_err_status_t srtp_unprotect_mki(srtp_ctx_t *ctx, void *srtp_hdr, size_t *pkt_octet_len, - unsigned int use_mki) + bool use_mki) { srtp_hdr_t *hdr = (srtp_hdr_t *)srtp_hdr; uint8_t *enc_start; /* pointer to start of encrypted portion */ @@ -2499,7 +2494,7 @@ srtp_err_status_t srtp_unprotect_mki(srtp_ctx_t *ctx, srtp_hdr_xtnd_t *xtn_hdr = NULL; size_t mki_size = 0; srtp_session_keys_t *session_keys = NULL; - int advance_packet_index = 0; + bool advance_packet_index = false; uint32_t roc_to_set = 0; uint16_t seq_to_set = 0; @@ -2553,7 +2548,7 @@ srtp_err_status_t srtp_unprotect_mki(srtp_ctx_t *ctx, return status; if (status == srtp_err_status_pkt_idx_adv) { - advance_packet_index = 1; + advance_packet_index = true; roc_to_set = (uint32_t)(est >> 16); seq_to_set = (uint16_t)(est & 0xFFFF); } @@ -3629,7 +3624,7 @@ static srtp_err_status_t srtp_protect_rtcp_aead( void *rtcp_hdr, size_t *pkt_octet_len, srtp_session_keys_t *session_keys, - unsigned int use_mki) + bool use_mki) { srtcp_hdr_t *hdr = (srtcp_hdr_t *)rtcp_hdr; uint8_t *enc_start; /* pointer to start of encrypted portion */ @@ -3800,7 +3795,7 @@ static srtp_err_status_t srtp_unprotect_rtcp_aead( void *srtcp_hdr, size_t *pkt_octet_len, srtp_session_keys_t *session_keys, - unsigned int use_mki) + bool use_mki) { srtcp_hdr_t *hdr = (srtcp_hdr_t *)srtcp_hdr; uint8_t *enc_start; /* pointer to start of encrypted portion */ @@ -3994,13 +3989,13 @@ srtp_err_status_t srtp_protect_rtcp(srtp_t ctx, void *rtcp_hdr, size_t *pkt_octet_len) { - return srtp_protect_rtcp_mki(ctx, rtcp_hdr, pkt_octet_len, 0, 0); + return srtp_protect_rtcp_mki(ctx, rtcp_hdr, pkt_octet_len, false, 0); } srtp_err_status_t srtp_protect_rtcp_mki(srtp_t ctx, void *rtcp_hdr, size_t *pkt_octet_len, - unsigned int use_mki, + bool use_mki, unsigned int mki_index) { srtcp_hdr_t *hdr = (srtcp_hdr_t *)rtcp_hdr; @@ -4223,13 +4218,13 @@ srtp_err_status_t srtp_unprotect_rtcp(srtp_t ctx, void *srtcp_hdr, size_t *pkt_octet_len) { - return srtp_unprotect_rtcp_mki(ctx, srtcp_hdr, pkt_octet_len, 0); + return srtp_unprotect_rtcp_mki(ctx, srtcp_hdr, pkt_octet_len, false); } srtp_err_status_t srtp_unprotect_rtcp_mki(srtp_t ctx, void *srtcp_hdr, size_t *pkt_octet_len, - unsigned int use_mki) + bool use_mki) { srtcp_hdr_t *hdr = (srtcp_hdr_t *)srtcp_hdr; uint8_t *enc_start; /* pointer to start of encrypted portion */ @@ -4636,8 +4631,8 @@ size_t srtp_profile_get_master_salt_length(srtp_profile_t profile) } srtp_err_status_t stream_get_protect_trailer_length(srtp_stream_ctx_t *stream, - uint32_t is_rtp, - uint32_t use_mki, + bool is_rtp, + bool use_mki, uint32_t mki_index, size_t *length) { @@ -4667,10 +4662,10 @@ srtp_err_status_t stream_get_protect_trailer_length(srtp_stream_ctx_t *stream, } struct get_protect_trailer_length_data { - uint32_t found_stream; /* whether at least one matching stream was found */ - size_t length; /* maximum trailer length found so far */ - uint32_t is_rtp; - uint32_t use_mki; + bool found_stream; /* whether at least one matching stream was found */ + size_t length; /* maximum trailer length found so far */ + bool is_rtp; + bool use_mki; uint32_t mki_index; }; @@ -4683,7 +4678,7 @@ static int get_protect_trailer_length_cb(srtp_stream_t stream, void *raw_data) if (stream_get_protect_trailer_length(stream, data->is_rtp, data->use_mki, data->mki_index, &temp_length) == srtp_err_status_ok) { - data->found_stream = 1; + data->found_stream = true; if (temp_length > data->length) { data->length = temp_length; } @@ -4693,13 +4688,13 @@ static int get_protect_trailer_length_cb(srtp_stream_t stream, void *raw_data) } srtp_err_status_t get_protect_trailer_length(srtp_t session, - uint32_t is_rtp, - uint32_t use_mki, + bool is_rtp, + bool use_mki, uint32_t mki_index, size_t *length) { srtp_stream_ctx_t *stream; - struct get_protect_trailer_length_data data = { 0, 0, is_rtp, use_mki, + struct get_protect_trailer_length_data data = { false, 0, is_rtp, use_mki, mki_index }; if (session == NULL) { @@ -4709,7 +4704,7 @@ srtp_err_status_t get_protect_trailer_length(srtp_t session, stream = session->stream_template; if (stream != NULL) { - data.found_stream = 1; + data.found_stream = true; stream_get_protect_trailer_length(stream, is_rtp, use_mki, mki_index, &data.length); } @@ -4726,7 +4721,7 @@ srtp_err_status_t get_protect_trailer_length(srtp_t session, } srtp_err_status_t srtp_get_protect_trailer_length(srtp_t session, - uint32_t use_mki, + bool use_mki, uint32_t mki_index, size_t *length) { @@ -4734,11 +4729,12 @@ srtp_err_status_t srtp_get_protect_trailer_length(srtp_t session, } srtp_err_status_t srtp_get_protect_rtcp_trailer_length(srtp_t session, - uint32_t use_mki, + bool use_mki, uint32_t mki_index, size_t *length) { - return get_protect_trailer_length(session, 0, use_mki, mki_index, length); + return get_protect_trailer_length(session, false, use_mki, mki_index, + length); } /* diff --git a/test/rtp_decoder.c b/test/rtp_decoder.c index 044da32f9..189e1db81 100644 --- a/test/rtp_decoder.c +++ b/test/rtp_decoder.c @@ -523,7 +523,7 @@ int main(int argc, char *argv[]) policy.key = (uint8_t *)key; policy.next = NULL; policy.window_size = 128; - policy.allow_repeat_tx = 0; + policy.allow_repeat_tx = false; policy.rtp.sec_serv = sec_servs; policy.rtcp.sec_serv = sec_servs; // sec_serv_none; /* we don't do RTCP anyway */ diff --git a/test/rtpw.c b/test/rtpw.c index a7717708c..eb8d1895c 100644 --- a/test/rtpw.c +++ b/test/rtpw.c @@ -456,7 +456,7 @@ int main(int argc, char *argv[]) policy.key = (uint8_t *)key; policy.next = NULL; policy.window_size = 128; - policy.allow_repeat_tx = 0; + policy.allow_repeat_tx = false; policy.rtp.sec_serv = sec_servs; policy.rtcp.sec_serv = sec_serv_none; /* we don't do RTCP anyway */ @@ -516,7 +516,7 @@ int main(int argc, char *argv[]) policy.ssrc.type = ssrc_specific; policy.ssrc.value = ssrc; policy.window_size = 0; - policy.allow_repeat_tx = 0; + policy.allow_repeat_tx = false; policy.next = NULL; } diff --git a/test/srtp_driver.c b/test/srtp_driver.c index 0ac243b0f..f13c8abe0 100644 --- a/test/srtp_driver.c +++ b/test/srtp_driver.c @@ -219,13 +219,13 @@ srtp_debug_module_t mod_driver = { int main(int argc, char *argv[]) { int q; - unsigned do_timing_test = 0; - unsigned do_rejection_test = 0; - unsigned do_codec_timing = 0; - unsigned do_validation = 0; - unsigned do_stream_list = 0; - unsigned do_list_mods = 0; - unsigned do_log_stdout = 0; + bool do_timing_test = false; + bool do_rejection_test = false; + bool do_codec_timing = false; + bool do_validation = false; + bool do_stream_list = false; + bool do_list_mods = false; + bool do_log_stdout = false; srtp_err_status_t status; const size_t hdr_size = 12; @@ -264,26 +264,26 @@ int main(int argc, char *argv[]) } switch (q) { case 't': - do_timing_test = 1; + do_timing_test = true; break; case 'r': - do_rejection_test = 1; + do_rejection_test = true; break; case 'c': - do_codec_timing = 1; + do_codec_timing = true; break; case 'v': - do_validation = 1; - do_stream_list = 1; + do_validation = true; + do_stream_list = true; break; case 's': - do_stream_list = 1; + do_stream_list = true; break; case 'o': - do_log_stdout = 1; + do_log_stdout = true; break; case 'l': - do_list_mods = 1; + do_list_mods = true; break; case 'd': status = srtp_set_debug_module(optarg_s, 1); @@ -652,7 +652,7 @@ int main(int argc, char *argv[]) policy.ssrc.value = 0xdecafbad; policy.key = test_key; policy.window_size = 128; - policy.allow_repeat_tx = 0; + policy.allow_repeat_tx = false; policy.next = NULL; printf("mips estimate: %e\n", mips_value); @@ -1044,7 +1044,7 @@ srtp_err_status_t srtp_test_call_protect(srtp_t srtp_sender, if (mki_index == -1) { return srtp_protect(srtp_sender, hdr, len); } else { - return srtp_protect_mki(srtp_sender, hdr, len, 1, mki_index); + return srtp_protect_mki(srtp_sender, hdr, len, true, mki_index); } } @@ -1056,16 +1056,16 @@ srtp_err_status_t srtp_test_call_protect_rtcp(srtp_t srtp_sender, if (mki_index == -1) { return srtp_protect_rtcp(srtp_sender, hdr, len); } else { - return srtp_protect_rtcp_mki(srtp_sender, hdr, len, 1, mki_index); + return srtp_protect_rtcp_mki(srtp_sender, hdr, len, true, mki_index); } } srtp_err_status_t srtp_test_call_unprotect(srtp_t srtp_sender, srtp_hdr_t *hdr, size_t *len, - int use_mki) + bool use_mki) { - if (use_mki == -1) { + if (!use_mki) { return srtp_unprotect(srtp_sender, hdr, len); } else { return srtp_unprotect_mki(srtp_sender, hdr, len, use_mki); @@ -1075,9 +1075,9 @@ srtp_err_status_t srtp_test_call_unprotect(srtp_t srtp_sender, srtp_err_status_t srtp_test_call_unprotect_rtcp(srtp_t srtp_sender, srtcp_hdr_t *hdr, size_t *len, - int use_mki) + bool use_mki) { - if (use_mki == -1) { + if (!use_mki) { return srtp_unprotect_rtcp(srtp_sender, hdr, len); } else { return srtp_unprotect_rtcp_mki(srtp_sender, hdr, len, use_mki); @@ -1102,10 +1102,10 @@ srtp_err_status_t srtp_test(const srtp_policy_t *policy, srtp_policy_t *rcvr_policy; srtp_policy_t tmp_policy; int header = 1; - int use_mki = 0; + bool use_mki = false; if (mki_index >= 0) - use_mki = 1; + use_mki = true; if (extension_header) { memcpy(&tmp_policy, policy, sizeof(srtp_policy_t)); @@ -1333,10 +1333,10 @@ srtp_err_status_t srtcp_test(const srtp_policy_t *policy, int mki_index) size_t tag_length; uint32_t ssrc; srtp_policy_t *rcvr_policy; - int use_mki = 0; + bool use_mki = false; if (mki_index >= 0) - use_mki = 1; + use_mki = true; err_check(srtp_create(&srtcp_sender, policy)); @@ -1806,7 +1806,7 @@ srtp_err_status_t srtp_validate(void) policy.ssrc.value = 0xcafebabe; policy.key = test_key; policy.window_size = 128; - policy.allow_repeat_tx = 0; + policy.allow_repeat_tx = false; policy.next = NULL; status = srtp_create(&srtp_snd, &policy); @@ -1965,7 +1965,7 @@ srtp_err_status_t srtp_validate_null(void) policy.ssrc.value = 0xcafebabe; policy.key = test_key; policy.window_size = 128; - policy.allow_repeat_tx = 0; + policy.allow_repeat_tx = false; policy.next = NULL; status = srtp_create(&srtp_snd, &policy); @@ -2126,7 +2126,7 @@ srtp_err_status_t srtp_validate_gcm(void) policy.ssrc.value = 0xcafebabe; policy.key = test_key_gcm; policy.window_size = 128; - policy.allow_repeat_tx = 0; + policy.allow_repeat_tx = false; policy.next = NULL; status = srtp_create(&srtp_snd, &policy); @@ -2288,7 +2288,7 @@ srtp_err_status_t srtp_validate_encrypted_extensions_headers(void) policy.ssrc.value = 0xcafebabe; policy.key = test_key_ext_headers; policy.window_size = 128; - policy.allow_repeat_tx = 0; + policy.allow_repeat_tx = false; policy.enc_xtn_hdr = headers; policy.enc_xtn_hdr_count = sizeof(headers) / sizeof(headers[0]); policy.next = NULL; @@ -2408,7 +2408,7 @@ srtp_err_status_t srtp_validate_encrypted_extensions_headers_gcm(void) policy.ssrc.value = 0xcafebabe; policy.key = test_key_ext_headers; policy.window_size = 128; - policy.allow_repeat_tx = 0; + policy.allow_repeat_tx = false; policy.enc_xtn_hdr = headers; policy.enc_xtn_hdr_count = sizeof(headers) / sizeof(headers[0]); policy.next = NULL; @@ -2523,7 +2523,7 @@ srtp_err_status_t srtp_validate_aes_256(void) policy.ssrc.value = 0xcafebabe; policy.key = aes_256_test_key; policy.window_size = 128; - policy.allow_repeat_tx = 0; + policy.allow_repeat_tx = false; policy.next = NULL; status = srtp_create(&srtp_snd, &policy); @@ -2650,7 +2650,7 @@ srtp_err_status_t srtp_test_empty_payload(void) policy.ssrc.value = 0xcafebabe; policy.key = test_key; policy.window_size = 128; - policy.allow_repeat_tx = 0; + policy.allow_repeat_tx = false; policy.next = NULL; status = srtp_create(&srtp_snd, &policy); @@ -2725,7 +2725,7 @@ srtp_err_status_t srtp_test_empty_payload_gcm(void) policy.ssrc.value = 0xcafebabe; policy.key = test_key; policy.window_size = 128; - policy.allow_repeat_tx = 0; + policy.allow_repeat_tx = false; policy.next = NULL; status = srtp_create(&srtp_snd, &policy); @@ -2849,7 +2849,7 @@ srtp_err_status_t srtp_test_remove_stream(void) policy.ssrc.value = 0xcafebabe; policy.key = test_key; policy.window_size = 128; - policy.allow_repeat_tx = 0; + policy.allow_repeat_tx = false; policy.next = NULL; status = srtp_create(&session, NULL); @@ -2907,7 +2907,7 @@ srtp_err_status_t srtp_test_update(void) srtp_crypto_policy_set_rtp_default(&policy.rtp); srtp_crypto_policy_set_rtcp_default(&policy.rtcp); policy.window_size = 128; - policy.allow_repeat_tx = 0; + policy.allow_repeat_tx = false; policy.next = NULL; policy.key = test_key; @@ -3073,7 +3073,7 @@ srtp_err_status_t srtp_test_setup_protect_trailer_streams( srtp_crypto_policy_set_rtp_default(&policy.rtp); srtp_crypto_policy_set_rtcp_default(&policy.rtcp); policy.window_size = 128; - policy.allow_repeat_tx = 0; + policy.allow_repeat_tx = false; policy.next = NULL; policy.ssrc.type = ssrc_any_outbound; policy.key = test_key; @@ -3082,7 +3082,7 @@ srtp_err_status_t srtp_test_setup_protect_trailer_streams( srtp_crypto_policy_set_rtp_default(&policy_mki.rtp); srtp_crypto_policy_set_rtcp_default(&policy_mki.rtcp); policy_mki.window_size = 128; - policy_mki.allow_repeat_tx = 0; + policy_mki.allow_repeat_tx = false; policy_mki.next = NULL; policy_mki.ssrc.type = ssrc_any_outbound; policy_mki.key = NULL; @@ -3094,7 +3094,7 @@ srtp_err_status_t srtp_test_setup_protect_trailer_streams( srtp_crypto_policy_set_aes_gcm_128_16_auth(&policy_aes_gcm.rtp); srtp_crypto_policy_set_aes_gcm_128_16_auth(&policy_aes_gcm.rtcp); policy_aes_gcm.window_size = 128; - policy_aes_gcm.allow_repeat_tx = 0; + policy_aes_gcm.allow_repeat_tx = false; policy_aes_gcm.next = NULL; policy_aes_gcm.ssrc.type = ssrc_any_outbound; policy_aes_gcm.key = test_key; @@ -3103,7 +3103,7 @@ srtp_err_status_t srtp_test_setup_protect_trailer_streams( srtp_crypto_policy_set_aes_gcm_128_16_auth(&policy_aes_gcm_mki.rtp); srtp_crypto_policy_set_aes_gcm_128_16_auth(&policy_aes_gcm_mki.rtcp); policy_aes_gcm_mki.window_size = 128; - policy_aes_gcm_mki.allow_repeat_tx = 0; + policy_aes_gcm_mki.allow_repeat_tx = false; policy_aes_gcm_mki.next = NULL; policy_aes_gcm_mki.ssrc.type = ssrc_any_outbound; policy_aes_gcm_mki.key = NULL;