Index: modules/registrar/reg_mod.c
===================================================================
--- modules/registrar/reg_mod.c (revision 8952)
+++ modules/registrar/reg_mod.c (working copy)
@@ -98,8 +98,8 @@
* use 0 to switch expires checking off */
int max_contacts = 0; /*!< Maximum number of contacts per AOR (0=no checking) */
int retry_after = 0; /*!< The value of Retry-After HF in 5xx replies */
+int add_gruu_to_contact = 1;
-
char* rcv_avp_param = 0;
unsigned short rcv_avp_type = 0;
int rcv_avp_name;
@@ -180,6 +180,7 @@
{"sock_hdr_name", STR_PARAM, &sock_hdr_name.s },
{"mcontact_avp", STR_PARAM, &mct_avp_param },
{"gruu_secret", STR_PARAM, &gruu_secret.s },
+ {"add_gruu_to_contact",INT_PARAM, &add_gruu_to_contact },
{0, 0, 0}
};
Index: modules/registrar/reg_mod.h
===================================================================
--- modules/registrar/reg_mod.h (revision 8952)
+++ modules/registrar/reg_mod.h (working copy)
@@ -88,6 +88,7 @@
extern int reg_use_domain;
extern str realm_prefix;
extern float def_q;
+extern int add_gruu_to_contact;
extern unsigned short rcv_avp_type;
extern int rcv_avp_name;
Index: modules/registrar/reply.c
===================================================================
--- modules/registrar/reply.c (revision 8952)
+++ modules/registrar/reply.c (working copy)
@@ -282,7 +282,7 @@
*p++ = '\"';
}
- if (c->instance.s) {
+ if (add_gruu_to_contact && c->instance.s) {
/* build pub GRUU */
memcpy(p,PUB_GRUU,PUB_GRUU_SIZE);
p += PUB_GRUU_SIZE;
Index: modules/registrar/doc/registrar_admin.xml
===================================================================
--- modules/registrar/doc/registrar_admin.xml (revision 8952)
+++ modules/registrar/doc/registrar_admin.xml (working copy)
@@ -482,8 +482,27 @@
...
+
+
+ add_gruu_to_contact (integer)
+
+ If set to 1, gruu is added to the contact.
+
+
+
+ Default value is 1.
+
+
+
+ Set add_gruu_to_contact parameter
+
+...
+modparam("registrar", "add_gruu_to_contact", 0)
+...
+
+
+
-