[sr-dev] git:master:ed3bfa32: modules/ims_registrar_scscf: make modparam for using not-std call-id avp

jaybeepee jason.penton at gmail.com
Fri Jun 24 16:22:53 CEST 2016


Module: kamailio
Branch: master
Commit: ed3bfa32de50a6bca49eab23f7ad271001225654
URL: https://github.com/kamailio/kamailio/commit/ed3bfa32de50a6bca49eab23f7ad271001225654

Author: jaybeepee <jason.penton at gmail.com>
Committer: jaybeepee <jason.penton at gmail.com>
Date: 2016-06-24T16:22:34+02:00

modules/ims_registrar_scscf: make modparam for using not-std call-id avp
  - avp called 'send_vs_callid_avp'
  - TODO: use std method for sending call-id as per TS129.229
  - this has been done in such a way as to maintain backwards compatibility - will eventually be deprecated

---

Modified: modules/ims_registrar_scscf/cxdx_sar.c
Modified: modules/ims_registrar_scscf/reg_mod.c

---

Diff:  https://github.com/kamailio/kamailio/commit/ed3bfa32de50a6bca49eab23f7ad271001225654.diff
Patch: https://github.com/kamailio/kamailio/commit/ed3bfa32de50a6bca49eab23f7ad271001225654.patch

---

diff --git a/modules/ims_registrar_scscf/cxdx_sar.c b/modules/ims_registrar_scscf/cxdx_sar.c
index 2e0b25b..7677558 100644
--- a/modules/ims_registrar_scscf/cxdx_sar.c
+++ b/modules/ims_registrar_scscf/cxdx_sar.c
@@ -67,6 +67,7 @@
 #include "pvt_message.h"
 
 extern struct cdp_binds cdpb;
+extern unsigned int send_vs_callid_avp;
 
 int create_return_code(int result) {
     int rc;
@@ -345,7 +346,8 @@ int cxdx_send_sar(struct sip_msg *msg, str public_identity, str private_identity
     }
     if (!sar) goto error1;
 
-    if (!cxdx_add_call_id(sar, cscf_get_call_id(msg, &hdr))) goto error1;
+    if (send_vs_callid_avp)
+		if (!cxdx_add_call_id(sar, cscf_get_call_id(msg, &hdr))) goto error1;
     if (!cxdx_add_destination_realm(sar, cxdx_dest_realm)) goto error1;
 
     if (!cxdx_add_vendor_specific_appid(sar, IMS_vendor_id_3GPP, IMS_Cx, 0 /*IMS_Cx*/)) goto error1;
diff --git a/modules/ims_registrar_scscf/reg_mod.c b/modules/ims_registrar_scscf/reg_mod.c
index b3ddac3..e4d3f12 100644
--- a/modules/ims_registrar_scscf/reg_mod.c
+++ b/modules/ims_registrar_scscf/reg_mod.c
@@ -94,6 +94,7 @@ char *scscf_user_data_dtd = 0; /* Path to "CxDataType.dtd" */
 char *scscf_user_data_xsd = 0; /* Path to "CxDataType_Rel6.xsd" or "CxDataType_Rel7.xsd" */
 int scscf_support_wildcardPSI = 0;
 int store_data_on_dereg = 0; /**< should we store SAR data on de-registration  */
+unsigned int send_vs_callid_avp = 1;	/* flag to enable/disable proprietary use of a callid AVP. TODO: add call-id as per TS129.229 */
 
 int ue_unsubscribe_on_dereg = 0;  /*many UEs do not unsubscribe on de reg - therefore we should remove their subscription and not send a notify
 				   Some UEs do unsubscribe then everything is fine*/
@@ -271,7 +272,7 @@ static param_export_t params[] = {
     {"user_data_always", INT_PARAM, &user_data_always},
     {"notification_list_size_threshold", INT_PARAM, &notification_list_size_threshold},
     {"notification_processes", INT_PARAM, &notification_processes},
-
+    {"send_vs_callid_avp", INT_PARAM, &send_vs_callid_avp},
     {0, 0, 0}
 };
 




More information about the sr-dev mailing list