Hello,
Is it possible to have Kamailio rewrite the Request URI of the INVITE message but sent the INVITE to another address first? For example
- Kamailio (10.0.0.1) receives an INVITE
- Kamailio rewrites the RURI to 10.0.0.3
- Kamailio sends the INVITE to 10.0.0.2
- The application at 10.0.0.2 sends the INVITE to 10.0.0.3
Regards,
Grant
Yes, this is achieved by changing the destination set ($du), or direct arguments to t_relay():
http://kamailio.org/docs/modules/4.0.x/modules/tm.html#t_relay
This has the effect of saying, "set the Request URI to X, but on the network (IP) and transport (UDP, TCP, etc.) level, send the request physically to Y".
-- Alex
On 04/29/2013 04:32 AM, Grant Bagdasarian wrote:
Hello,
Is it possible to have Kamailio rewrite the Request URI of the INVITE message but sent the INVITE to another address first?
For example
-Kamailio (10.0.0.1) receives an INVITE
-Kamailio rewrites the RURI to 10.0.0.3
-Kamailio sends the INVITE to 10.0.0.2
-The application at 10.0.0.2 sends the INVITE to 10.0.0.3
Regards,
Grant
SIP Express Router (SER) and Kamailio (OpenSER) - sr-users mailing list sr-users@lists.sip-router.org http://lists.sip-router.org/cgi-bin/mailman/listinfo/sr-users
Cool. Thanks!
-----Original Message----- From: sr-users-bounces@lists.sip-router.org [mailto:sr-users-bounces@lists.sip-router.org] On Behalf Of Alex Balashov Sent: Monday, April 29, 2013 10:37 AM To: sr-users@lists.sip-router.org Subject: Re: [SR-Users] Rewrite RURI
Yes, this is achieved by changing the destination set ($du), or direct arguments to t_relay():
http://kamailio.org/docs/modules/4.0.x/modules/tm.html#t_relay
This has the effect of saying, "set the Request URI to X, but on the network (IP) and transport (UDP, TCP, etc.) level, send the request physically to Y".
-- Alex
On 04/29/2013 04:32 AM, Grant Bagdasarian wrote:
Hello,
Is it possible to have Kamailio rewrite the Request URI of the INVITE message but sent the INVITE to another address first?
For example
-Kamailio (10.0.0.1) receives an INVITE
-Kamailio rewrites the RURI to 10.0.0.3
-Kamailio sends the INVITE to 10.0.0.2
-The application at 10.0.0.2 sends the INVITE to 10.0.0.3
Regards,
Grant
SIP Express Router (SER) and Kamailio (OpenSER) - sr-users mailing list sr-users@lists.sip-router.org http://lists.sip-router.org/cgi-bin/mailman/listinfo/sr-users
-- Alex Balashov - Principal Evariste Systems LLC 235 E Ponce de Leon Ave Suite 106 Decatur, GA 30030 United States Tel: +1-678-954-0670 Web: http://www.evaristesys.com/, http://www.alexbalashov.com/
_______________________________________________ SIP Express Router (SER) and Kamailio (OpenSER) - sr-users mailing list sr-users@lists.sip-router.org http://lists.sip-router.org/cgi-bin/mailman/listinfo/sr-users
Hi Grant,
that's easy:
$ru = "sip:$rU@10.0.0.3"; $du = "sip:10.0.0.2";
Done.
Carsten
2013/4/29 Grant Bagdasarian GB@cm.nl:
Hello,
Is it possible to have Kamailio rewrite the Request URI of the INVITE message but sent the INVITE to another address first?
For example
Kamailio (10.0.0.1) receives an INVITE
Kamailio rewrites the RURI to 10.0.0.3
Kamailio sends the INVITE to 10.0.0.2
The application at 10.0.0.2 sends the INVITE to 10.0.0.3
Regards,
Grant
SIP Express Router (SER) and Kamailio (OpenSER) - sr-users mailing list sr-users@lists.sip-router.org http://lists.sip-router.org/cgi-bin/mailman/listinfo/sr-users
29 apr 2013 kl. 10:32 skrev Grant Bagdasarian GB@cm.nl:
Hello,
Is it possible to have Kamailio rewrite the Request URI of the INVITE message but sent the INVITE to another address first? For example
Kamailio (10.0.0.1) receives an INVITE
Kamailio rewrites the RURI to 10.0.0.3
Kamailio sends the INVITE to 10.0.0.2
The application at 10.0.0.2 sends the INVITE to 10.0.0.3
Check the $du pseudo-variable that sets the destination of the message (outbound proxy) for a request. You can also use the functions that relay/forward to specific address instead of the RURI.
So yes, it's possible.
/O