[SR-Users] Redirect, maddr, and domain

Daniel-Constantin Mierla miconda at gmail.com
Tue Mar 18 09:11:16 CET 2014


Maybe a function to do these operations at once won't be that bad idea 
... any volunteers for a patch to siputils module?

Cheers,
Daniel

On 17/03/14 21:47, Marc Soda wrote:
> The branch route worked perfectly.  Thanks.
>
>
> On Mon, Mar 17, 2014 at 4:26 PM, Daniel-Constantin Mierla 
> <miconda at gmail.com <mailto:miconda at gmail.com>> wrote:
>
>     IIRC, there was no automatic handling of maddr in request uri,
>     only record route module does it (or at least did it) for route
>     headers via loose route. The sip rfc discouraged use of maddr:
>
>     - http://tools.ietf.org/html/rfc3261#section-19.1.1
>
>     But you can handle it in branch route, for your specific case.
>     After using get_redirect() and before relaying, set a branch
>     route, inside it you can use:
>
>     $(ru{uri.maddr}) to get its value and use it as outbound proxy:
>
>     $du = "sip:" + $(ru{uri.maddr});
>
>     subst_uri() from textops should help removing the parameter.
>
>     Cheers,
>     Daniel
>
>
>     On 17/03/14 17:42, Marc Soda wrote:
>>     I'm trying to handle a redirect with get_redirects().  It seems
>>     that Kamailio is ignoring the maddr param on the contact header.
>>      Is there a way to force maddr to be used?
>>
>>     The Contact header on the 302 looks like this:
>>
>>     <sip:2404441112 at domain.com:5060;maddr=1.1.1.1>;q=0.5,<sip:2404441112 at comain.com:5060;maddr=2.2.2.2>;q=0.25
>>
>>     The message is then being sent to domain.com <http://domain.com>,
>>     rather than 1.1.1.1.
>>
>>
>>
>>     _______________________________________________
>>     SIP Express Router (SER) and Kamailio (OpenSER) - sr-users mailing list
>>     sr-users at lists.sip-router.org  <mailto:sr-users at lists.sip-router.org>
>>     http://lists.sip-router.org/cgi-bin/mailman/listinfo/sr-users
>
>     -- 
>     Daniel-Constantin Mierla -http://www.asipto.com
>     http://twitter.com/#!/miconda  <http://twitter.com/#%21/miconda>  -http://www.linkedin.com/in/miconda
>     Kamailio World Conference - April 2-4, 2014, Berlin, Germany
>     http://www.kamailioworld.com
>
>
>     _______________________________________________
>     SIP Express Router (SER) and Kamailio (OpenSER) - sr-users mailing
>     list
>     sr-users at lists.sip-router.org <mailto:sr-users at lists.sip-router.org>
>     http://lists.sip-router.org/cgi-bin/mailman/listinfo/sr-users
>
>

-- 
Daniel-Constantin Mierla - http://www.asipto.com
http://twitter.com/#!/miconda - http://www.linkedin.com/in/miconda
Kamailio World Conference - April 2-4, 2014, Berlin, Germany
http://www.kamailioworld.com

-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://lists.sip-router.org/pipermail/sr-users/attachments/20140318/9e760262/attachment-0001.html>


More information about the sr-users mailing list