diff options
author | Alexander Traud <pabstraud@compuserve.com> | 2017-03-29 15:04:05 +0200 |
---|---|---|
committer | Alexander Traud <pabstraud@compuserve.com> | 2017-03-29 15:04:05 +0200 |
commit | e76cc51d5e1d10f7df3855f5a5f233da1140486e (patch) | |
tree | d31d6f94b559399606cc6294c5498473b758d13f /res/res_srtp.c | |
parent | f43cfb81d92bfdb99ad6467047fdf0469228ca3c (diff) |
srtp: Allow zero as tag value for a sRTP Crypto Suite.
ASTERISK-25490 #close
Change-Id: I1c5fc0942c33c96d62b24203aad0f1e1a1a0131f
Diffstat (limited to 'res/res_srtp.c')
-rw-r--r-- | res/res_srtp.c | 4 |
1 files changed, 2 insertions, 2 deletions
diff --git a/res/res_srtp.c b/res/res_srtp.c index a611e6165..c47a8d55e 100644 --- a/res/res_srtp.c +++ b/res/res_srtp.c @@ -782,8 +782,8 @@ static int res_sdp_crypto_parse_offer(struct ast_rtp_instance *rtp, struct ast_s return -1; } - /* RFC4568 9.1 - tag is 1-9 digits, greater than zero */ - if (sscanf(tag, "%30d", &tag_from_sdp) != 1 || tag_from_sdp <= 0 || tag_from_sdp > 999999999) { + /* RFC4568 9.1 - tag is 1-9 digits */ + if (sscanf(tag, "%30d", &tag_from_sdp) != 1 || tag_from_sdp < 0 || tag_from_sdp > 999999999) { ast_log(LOG_WARNING, "Unacceptable a=crypto tag: %s\n", tag); return -1; } |