]> 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:34 +0000 (15:39 -0600)
commite99d0fe16b65c07d30930713f8611d3c61189c68
tree849224f5685d97fc074b2b42f304ea5320fa2898
parentb7607c41e4825490ffea9d09c0b3b8f9d65f87c0
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