is there any way of getting the received ip/port/proto from nathelper?
modparam("nathelper|registrar", "received_avp", "$avp(RECEIVED)")
set_contact_alias(); xlog("$avp(RECEIVED)");
this gives me <null>
Kelvin Chua
Hello,
the received avp is set by fix_nated_registrar(), iirc. set_contact_alias() doesn't do it.
If you want to get the source IP and port, use $si and $sp. Local IP and port is $Ri and $Rp (iirc, you should check the cookbook). The protocol type is $pr. With these variables you can construct any address you need related to source or local socket.
Cheers, Daniel
On 02/07/14 10:22, Kelvin Chua wrote:
is there any way of getting the received ip/port/proto from nathelper?
modparam("nathelper|registrar", "received_avp", "$avp(RECEIVED)")
set_contact_alias(); xlog("$avp(RECEIVED)");
this gives me <null>
Kelvin Chua
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
as always, thanks daniel :)
Kelvin Chua
On Thu, Jul 3, 2014 at 4:21 PM, Daniel-Constantin Mierla miconda@gmail.com wrote:
Hello,
the received avp is set by fix_nated_registrar(), iirc. set_contact_alias() doesn't do it.
If you want to get the source IP and port, use $si and $sp. Local IP and port is $Ri and $Rp (iirc, you should check the cookbook). The protocol type is $pr. With these variables you can construct any address you need related to source or local socket.
Cheers, Daniel
On 02/07/14 10:22, Kelvin Chua wrote:
is there any way of getting the received ip/port/proto from nathelper?
modparam("nathelper|registrar", "received_avp", "$avp(RECEIVED)")
set_contact_alias(); xlog("$avp(RECEIVED)");
this gives me <null>
Kelvin Chua
SIP Express Router (SER) and Kamailio (OpenSER) - sr-users mailing listsr-users@lists.sip-router.orghttp://lists.sip-router.org/cgi-bin/mailman/listinfo/sr-users
-- Daniel-Constantin Mierla - http://www.asipto.comhttp://twitter.com/#!/miconda - http://www.linkedin.com/in/miconda
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
Welcome!
Daniel
On 07/07/14 08:39, Kelvin Chua wrote:
as always, thanks daniel :)
Kelvin Chua
On Thu, Jul 3, 2014 at 4:21 PM, Daniel-Constantin Mierla <miconda@gmail.com mailto:miconda@gmail.com> wrote:
Hello, the received avp is set by fix_nated_registrar(), iirc. set_contact_alias() doesn't do it. If you want to get the source IP and port, use $si and $sp. Local IP and port is $Ri and $Rp (iirc, you should check the cookbook). The protocol type is $pr. With these variables you can construct any address you need related to source or local socket. Cheers, Daniel On 02/07/14 10:22, Kelvin Chua wrote:
is there any way of getting the received ip/port/proto from nathelper? modparam("nathelper|registrar", "received_avp", "$avp(RECEIVED)") set_contact_alias(); xlog("$avp(RECEIVED)"); this gives me <null> Kelvin Chua _______________________________________________ SIP Express Router (SER) and Kamailio (OpenSER) - sr-users mailing list sr-users@lists.sip-router.org <mailto:sr-users@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 _______________________________________________ SIP Express Router (SER) and Kamailio (OpenSER) - sr-users mailing list sr-users@lists.sip-router.org <mailto:sr-users@lists.sip-router.org> http://lists.sip-router.org/cgi-bin/mailman/listinfo/sr-users