[SR-Users] parse errors in rr-callback of path module

Daniel-Constantin Mierla miconda at gmail.com
Wed Sep 14 11:27:53 CEST 2011


Hello,

On 9/14/11 11:08 AM, Andreas Granig wrote:
> Hi,
>
> On 09/14/2011 10:42 AM, Daniel-Constantin Mierla wrote:
>>>> Seems like the rr params value is not set properly. I looked in rr module and such case can happen indeed, but for the case when uri in rr does not match myself. Is this also in your case? I wonder anyhow why the callbacks are executed in route header uri is not local address...
>>> Indeed it happens when it doesn't match itself.
>> ok, so then it is found, fix to be done later.
> That'd be great!
>
>> However, I wonder if it makes sense to execute the rr calbacks when the
>> uri does not match myself. IIRC, the purpose of rr callbacks was to
>> access parameters added by proxy itself in record-route header which
>> should be mirrored by route headers. Do I misunderstand their goal?
>> Afaik path, dialog and uac modules use them to get parameters for dialog
>> id, from header recovery ... which are added by proxy itself. Not sure
>> for path module, is it about accessing parameters set by same instance
>> in record-route?
> At least for path, it's only relevant for extracting information for
> Routes pointing to itself. E.g. for a REGISTER, the lb puts itself into
> the Path, like "Path:
> <sip:own-ip:own-port;lr;received=sip:remote-ip:remote-port>", and in a
> subsequent INVITE that would convert into a Route, and the lb can then
> extract the "received=" information from it in the rr-callback and set
> it as $du..

ok, I committed a fix to master and 3.1 branches:

http://git.sip-router.org/cgi-bin/gitweb.cgi/sip-router/?a=commit;h=10eac9b125ff2a13a2ae240897a3f17bc1243c71

rr callbacks are executed only when URI is myself (it was the only 
working case anyhow for loose routing, otherwise params value was bogus) 
and if there are parameters in Route URI (otherwise further errors were 
issued inside callback functions, with no option of changing anything, 
i.e., no return code from callbacks).

It should fix your case, if not, report again.

Cheers,
Daniel

-- 
Daniel-Constantin Mierla -- http://www.asipto.com
Kamailio Advanced Training, Oct 10-13, Berlin: http://asipto.com/u/kat
http://linkedin.com/in/miconda -- http://twitter.com/miconda




More information about the sr-users mailing list