Module: sip-router
Branch: carstenbock/ims
Commit: 5479620417f017109985ee10d485a0da85588d81
URL: http://git.sip-router.org/cgi-bin/gitweb.cgi/sip-router/?a=commit;h=5479620…
Author: Carsten Bock <carsten(a)bock.info>
Committer: Carsten Bock <carsten(a)bock.info>
Date: Thu Mar 10 14:11:11 2011 +0100
- Updated Typo in the docs (thanks Klaus)
- added a note about reg_avp behaviour.
---
modules_k/registrar/doc/registrar_admin.xml | 21 ++++++++++++++++++---
1 files changed, 18 insertions(+), 3 deletions(-)
diff --git a/modules_k/registrar/doc/registrar_admin.xml b/modules_k/registrar/doc/registrar_admin.xml
index 13947d1..b809338 100644
--- a/modules_k/registrar/doc/registrar_admin.xml
+++ b/modules_k/registrar/doc/registrar_admin.xml
@@ -660,10 +660,13 @@ modparam("registrar", "reg_avp", "$avp(i:2)")
The function processes a REGISTER message. It can add, remove or
modify usrloc records depending on Contact and Expires HFs in the
REGISTER message. On success and when called from the REQUEST_ROUTE,
- 200 OK will be returned listing all contacts that are currently in
+ 200 OK will be returned listing all contacts that are currently in
usrloc. On an error, error message will be send with a short
description in reason phrase.
</para>
+ <para>
+ This function will save the AVP's for this contact.
+ </para>
<para>Meaning of the parameters is as follows:</para>
<itemizedlist>
<listitem>
@@ -715,6 +718,9 @@ save("location");
Same as <function>save()</function> but it accepts a set of flags for
controlling its behaviour.
</para>
+ <para>
+ This function will save the AVP's for this contact.
+ </para>
<para>Meaning of the parameters is as follows:</para>
<itemizedlist>
<listitem>
@@ -776,6 +782,9 @@ save("location","0x01");
the message (depending on append_branches parameter value).
</para>
<para>
+ This function will restore the AVP's for this contact.
+ </para>
+ <para>
If the method_filtering option is enabled, the lookup function
will return only the contacts that support the method of the
processed request.
@@ -837,7 +846,10 @@ switch ($retcode) {
The function returns true if the AOR in the Request-URI is
registered, false otherwise. The function does not modify the
message being processed, it neither rewrites the Request-URI if a
- contact is found not append branches.
+ contact is found nor appends branches.
+ </para>
+ <para>
+ This function will restore the AVP's for this contact.
</para>
<para>Meaning of the parameters is as follows:</para>
<itemizedlist>
@@ -873,7 +885,10 @@ if (registered("location")) {
registered, false otherwise.
The function does not modify the
message being processed, it neither rewrites the Request-URI if a
- contact is found not append branches.
+ contact is found nor appends branches.
+ </para>
+ <para>
+ This function will restore the AVP's for this contact.
</para>
<para>Meaning of the parameters is as follows:</para>
<itemizedlist>
Hey,
On 10.03.2011 02:12, 侯旭光 wrote:
> sorry ,it's my fault.I forgot
I think it's not working because you are simply forwarding()'ing the
request on the first proxy and not t_relay()'ing as you do on the
second. You need to be stateful in order to track dialogs. Do that and
you should be fine.
Cheers,
--Timo
> 在 2011年3月8日 下午7:57,Timo Reimann <timo.reimann(a)1und1.de> 写道:
>> Hey,
>>
>>
>> On 08.03.2011 12:37, 侯旭光 wrote:
>>> I modified the source code and took the solutions in cfg file that
>>> you guys suggested and no error exist.
>>>
>>> But my problem isn't totally solved.
>>>
>>> Actually when I use the dispatcher module and set the profile , in
>>> case the "invite" request forwarded by ds_select_domain function ,
>>> then the dialog terminated.
>>> dlg_list and get_profile_size get nothing.
>>>
>>> In detail:
>>>
>>> there're two proxys : server #1 192.168.1.12 and server #2 192.168.1.13
>>>
>>> two users: 1012 register on 192.168.1.12 and 2013 register on
> 192.168.1.13
>>>
>>> when user 1012 dial 2013, server 1# use the dispatcher module,
>>> forward the request to server #2 and set the profile.server #2 get
>>> the invite request and set the profile too, then call user 2013,Dialog
>>> Establish.
>>>
>>> At this time,server #2 has the dialog info,but server #1 doesn't.
>>>
>>> How can I trace the dialog info at both server #1 and server #2 ?
>>
>> Unless the dispatcher module terminates the dialog in a B2BUA fashion
>> (which I think it doesn't but I am not familiar with the module), calls
>> routed in the setup you described should be listed via dlg_list through
>> the course of dialog lifetime.
>>
>> Are you 100% sure you are tracking dialogs on proxy #1? (I think
>> set_dlg_profile() fails silently if the dialog isn't being tracked.)
>> Maybe you want to provide the relevant configuration snippet of the
>> proxy so we can double-check.
>>
>>
>> Cheers,
>>
>> --Timo
Module: sip-router
Branch: 3.1
Commit: 971cfda1012516f446d990e335b5edf6959e065c
URL: http://git.sip-router.org/cgi-bin/gitweb.cgi/sip-router/?a=commit;h=971cfda…
Author: Juha Heinanen <jh(a)tutpro.com>
Committer: Juha Heinanen <jh(a)tutpro.com>
Date: Tue Mar 8 09:42:18 2011 +0200
* modules_k/nathelper: add_contact_alias() fix
- add_contact_alias() is now able to add alias also to contact URI, where
hostpart contains a domain name instead of an IP address.
(cherry picked from commit 998ae20b26360383386d5f677ec87301e6b3ba23)
---
modules_k/nathelper/nathelper.c | 18 +++++++++---------
1 files changed, 9 insertions(+), 9 deletions(-)
diff --git a/modules_k/nathelper/nathelper.c b/modules_k/nathelper/nathelper.c
index dd737a3..2b07f38 100644
--- a/modules_k/nathelper/nathelper.c
+++ b/modules_k/nathelper/nathelper.c
@@ -775,7 +775,7 @@ fix_nated_contact_f(struct sip_msg* msg, char* str1, char* str2)
#define SALIAS_LEN (sizeof(SALIAS) - 1)
/*
- * Adds ;alias=ip:port param to cotact uri containing received ip:port
+ * Adds ;alias=ip:port param to contact uri containing received ip:port
* if contact uri ip:port does not match received ip:port.
*/
static int
@@ -806,14 +806,14 @@ add_contact_alias_f(struct sip_msg* msg, char* str1, char* str2)
/* Compare source ip and port against contact uri */
if ((ip = str2ip(&(uri.host))) == NULL) {
- LM_ERR("contact uri host is not an ip address\n");
- return -1;
- }
- if (ip_addr_cmp(ip, &(msg->rcv.src_ip)) &&
- ((msg->rcv.src_port == uri.port_no) ||
- ((uri.port.len == 0) && (msg->rcv.src_port == 5060)))) {
- LM_DBG("no need to add alias param\n");
- return 2;
+ LM_DBG("contact uri host is not an ip address\n");
+ } else {
+ if (ip_addr_cmp(ip, &(msg->rcv.src_ip)) &&
+ ((msg->rcv.src_port == uri.port_no) ||
+ ((uri.port.len == 0) && (msg->rcv.src_port == 5060)))) {
+ LM_DBG("no need to add alias param\n");
+ return 2;
+ }
}
/* Check if function has been called already */