]> git.ipfire.org Git - thirdparty/asterisk.git/commit
res_pjsip: set Accept-Encoding to identity in OPTIONS response
authorAlexander Greiner-Baer <alex+asterisk@greiner-baer.de>
Tue, 17 Nov 2020 20:19:35 +0000 (21:19 +0100)
committerKevin Harwell <kharwell@digium.com>
Thu, 19 Nov 2020 22:14:33 +0000 (16:14 -0600)
commitfba10fb54c1b2fe1e4926abe032d2b72815e504d
tree824ce6afa42b6bc54df0ec7abdc211f89297c8c7
parent103d7da3bb9989f5d13f1545866f42e65f6f5bda
res_pjsip: set Accept-Encoding to identity in OPTIONS response

RFC 3261 says that the Accept-Encoding header should be present
in an options response. Permitted values according to RFC 2616
are only compression algorithms like gzip or the default identity
encoding. Therefore "text/plain" is not a correct value here.
As long as the header is hard coded, it should be set to "identity".

Without this fix an Alcatel OmniPCX periodically logs warnings like
"[sip_acceptIncorrectHeader] Header Accept-Encoding is malformed"
on a SIP Trunk.

ASTERISK-29165 #close

Change-Id: I0aa2211ebf0b4c2ed554ac7cda794523803a3840
res/res_pjsip/pjsip_options.c
res/res_pjsip_dlg_options.c