[asterisk-commits] file: trunk r427980 - in /trunk: ./ res/res_pjsip/pjsip_configuration.c

SVN commits to the Asterisk project asterisk-commits at lists.digium.com
Sat Nov 15 12:29:14 CST 2014


Author: file
Date: Sat Nov 15 12:29:12 2014
New Revision: 427980

URL: http://svnview.digium.com/svn/asterisk?view=rev&rev=427980
Log:
res_pjsip: Enforce requirements for session timer minimum expiration period and normal expiration period.

This change enforces the requirements in PJSIP for session timer configuration. The minimum
expiration period must be 90 seconds or higher and the normal expiration period can not
be lower than the minimum expiration period. If either of these were done the code would
assert at session setup time.

ASTERISK-24336 #close
Reported by: Leon Rowland
........

Merged revisions 427978 from http://svn.asterisk.org/svn/asterisk/branches/12
........

Merged revisions 427979 from http://svn.asterisk.org/svn/asterisk/branches/13

Modified:
    trunk/   (props changed)
    trunk/res/res_pjsip/pjsip_configuration.c

Propchange: trunk/
------------------------------------------------------------------------------
Binary property 'branch-13-merged' - no diff available.

Modified: trunk/res/res_pjsip/pjsip_configuration.c
URL: http://svnview.digium.com/svn/asterisk/trunk/res/res_pjsip/pjsip_configuration.c?view=diff&rev=427980&r1=427979&r2=427980
==============================================================================
--- trunk/res/res_pjsip/pjsip_configuration.c (original)
+++ trunk/res/res_pjsip/pjsip_configuration.c Sat Nov 15 12:29:12 2014
@@ -954,6 +954,14 @@
 		ast_sip_push_task_synchronous(NULL, outbound_proxy_validate, (char*)endpoint->outbound_proxy)) {
 		ast_log(LOG_ERROR, "Invalid outbound proxy '%s' specified on endpoint '%s'\n",
 			endpoint->outbound_proxy, ast_sorcery_object_get_id(endpoint));
+		return -1;
+	} else if (endpoint->extensions.timer.min_se < 90) {
+		ast_log(LOG_ERROR, "Session timer minimum expires time must be 90 or greater on endpoint '%s'\n",
+			ast_sorcery_object_get_id(endpoint));
+		return -1;
+	} else if (endpoint->extensions.timer.sess_expires < endpoint->extensions.timer.min_se) {
+		ast_log(LOG_ERROR, "Session timer expires must be greater than minimum session expires time on endpoint '%s'\n",
+			ast_sorcery_object_get_id(endpoint));
 		return -1;
 	}
 




More information about the asterisk-commits mailing list