summaryrefslogtreecommitdiff
path: root/CHANGES
diff options
context:
space:
mode:
authorRichard Mudgett <rmudgett@digium.com>2016-02-26 18:57:17 -0600
committerRichard Mudgett <rmudgett@digium.com>2016-03-01 20:13:39 -0600
commit4165ea7778be093f614a8c476e04648b846b862e (patch)
treea7d5ffacbc6a3df6eaa1496555a77cdf7952f499 /CHANGES
parent41f4af4ce535eee2a4a3d0186b9f16f5de825a72 (diff)
SIP diversion: Fix REDIRECTING(reason) value inconsistencies.
Previous chan_sip behavior: Before this patch chan_sip would always strip any quotes from an incoming reason and pass that value up as the REDIRECTING(reason). For an outgoing reason value, chan_sip would check the value against known values and quote any it didn't recognize. Incoming 480 response message reason text was just assigned to the REDIRECTING(reason). Previous chan_pjsip behavior: Before this patch chan_pjsip would always pass the incoming reason value up as the REDIRECTING(reason). For an outgoing reason value, chan_pjsip would send the reason value as passed down. With this patch: Both channel drivers match incoming reason values with values documented by REDIRECTING(reason) and values documented by RFC5806 regardless of whether they are quoted or not. RFC5806 values are mapped to the equivalent REDIRECTING(reason) documented value and is set in REDIRECTING(reason). e.g., an incoming RFC5806 'unconditional' value or a quoted string version ('"unconditional"') is converted to REDIRECTING(reason)'s 'cfu' value. The user's dialplan only needs to deal with 'cfu' instead of any of the aliases. The incoming 480 response reason text supported by chan_sip checks for known reason values and if not matched then puts quotes around the reason string and assigns that to REDIRECTING(reason). Both channel drivers send outgoing known REDIRECTING(reason) values as the unquoted RFC5806 equivalent. User custom values are either sent as is or with added quotes if SIP doesn't allow a character within the value as part of a RFC3261 Section 25.1 token. Note that there are still limitations on what characters can be put in a custom user value. e.g., embedding quotes in the middle of the reason string is silly and just going to cause you grief. * Setting a REDIRECTING(reason) value now recognizes RFC5806 aliases. e.g., Setting REDIRECTING(reason) to 'unconditional' is converted to the 'cfu' value. * Added missing malloc() NULL return check in res_pjsip_diversion.c set_redirecting_reason(). * Fixed potential read from a stale pointer in res_pjsip_diversion.c add_diversion_header(). The reason string needed to be copied into the tdata memory pool to ensure that the string would always be available. Otherwise, if the reason string returned by reason_code_to_str() was a user's reason string then the string could be freed later by another thread. Change-Id: Ifba83d23a195a9f64d55b9c681d2e62476b68a87
Diffstat (limited to 'CHANGES')
-rw-r--r--CHANGES30
1 files changed, 30 insertions, 0 deletions
diff --git a/CHANGES b/CHANGES
index 0e8467830..b1353ece3 100644
--- a/CHANGES
+++ b/CHANGES
@@ -29,6 +29,36 @@ app_confbridge
conference state and made the locked column a yes/no value instead of a
locked/unlocked value.
+REDIRECTING(reason)
+------------------
+ * The REDIRECTING(reason) value is now treated consistently between
+ chan_sip and chan_pjsip.
+
+ Both channel drivers match incoming reason values with values documented
+ by REDIRECTING(reason) and values documented by RFC5806 regardless of
+ whether they are quoted or not. RFC5806 values are mapped to the
+ equivalent REDIRECTING(reason) documented value and is set in
+ REDIRECTING(reason). e.g., an incoming RFC5806 'unconditional' value or a
+ quoted string version ('"unconditional"') is converted to
+ REDIRECTING(reason)'s 'cfu' value. The user's dialplan only needs to deal
+ with 'cfu' instead of any of the aliases.
+
+ The incoming 480 response reason text supported by chan_sip checks for
+ known reason values and if not matched then puts quotes around the reason
+ string and assigns that to REDIRECTING(reason).
+
+ Both channel drivers send outgoing known REDIRECTING(reason) values as the
+ unquoted RFC5806 equivalent. User custom values are either sent as is or
+ with added quotes if SIP doesn't allow a character within the value as
+ part of a RFC3261 Section 25.1 token. Note that there are still
+ limitations on what characters can be put in a custom user value. e.g.,
+ embedding quotes in the middle of the reason string is just going to cause
+ you grief.
+
+ * Setting a REDIRECTING(reason) value now recognizes RFC5806 aliases.
+ e.g., Setting REDIRECTING(reason) to 'unconditional' is converted to the
+ 'cfu' value.
+
res_pjproject
------------------
* This module is the successor of res_pjsip_log_forwarder. As well as