]> git.ipfire.org Git - thirdparty/asterisk.git/commit
AST-2017-014: res_pjsip - Missing contact header can cause crash
authorKevin Harwell <kharwell@digium.com>
Wed, 20 Dec 2017 22:17:40 +0000 (16:17 -0600)
committerKevin Harwell <kharwell@digium.com>
Fri, 22 Dec 2017 21:39:18 +0000 (15:39 -0600)
commit6d994c8223561acc00da796140ec6123ca76c2e0
tree3232779a08202aff5d189600f05040ae3bdfb23f
parentb64c02e414a2b9ae30d1725cfff87f9e63bfab51
AST-2017-014: res_pjsip - Missing contact header can cause crash

Those SIP messages that create dialogs require a contact header to be present.
If the contact header was missing from the message it could cause Asterisk to
crash.

This patch checks to make sure SIP messages that create a dialog contain the
contact header. If the message does not and it is required Asterisk now returns
a "400 Missing Contact header" response. Also added NULL checks when retrieving
the contact header that were missing as a "just in case".

ASTERISK-27480 #close

Change-Id: I1810db87683fc637a9e3e1384a746037fec20afe
res/res_pjsip.c
res/res_pjsip/pjsip_message_filter.c
res/res_pjsip_pubsub.c