Re: [SR-Users] remote ip address of sender and receiver

2017-06-30 Thread Mojtaba
Let me know how do you test it? You should write it in Request-route block On 30 Jun 2017 13:04, "vuleetu" wrote: > I tried, but no luck. Could you tell which route block i should place > these code to? > > On Thu, Jun 29, 2017 at 10:57 PM, Mojtaba wrote: >

Re: [SR-Users] remote ip address of sender and receiver

2017-06-30 Thread vuleetu
yes, i just want remote user's ip address. It is the received filed of location table. After try the suggestion you gave, i still can't get remote ip address of remote receiver. On Thu, Jun 29, 2017 at 10:46 PM, Sebastian Damm wrote: > Hi, > > where do you get the IP address of

Re: [SR-Users] remote ip address of sender and receiver

2017-06-30 Thread vuleetu
I tried, but no luck. Could you tell which route block i should place these code to? On Thu, Jun 29, 2017 at 10:57 PM, Mojtaba wrote: > Hi. > I wrote this code, I check do the both peers are in the same network > or not. It works correctly. > # Check if both peers are in the

[SR-Users] remote ip address of sender and receiver

2017-06-29 Thread vuleetu
Hi, all Is there any way to get remote ip address of both sender($si) and receiver(?)? I am configuring kamailio with multiple rtpproxy sets. Basically, rtpproxy set will be choosed based on the country those ip addresses of caller and callee belong to. Lets say if caller and callee are both

Re: [SR-Users] remote ip address of sender and receiver

2017-06-29 Thread Mojtaba
Hi. I wrote this code, I check do the both peers are in the same network or not. It works correctly. # Check if both peers are in the same network(nat). if (is_method("INVITE")){ lookup("location","m"); $var(x) = $(ru{s.select,1,@}); $var(y) =

Re: [SR-Users] remote ip address of sender and receiver

2017-06-29 Thread Sebastian Damm
Hi, where do you get the IP address of the receiver from? You can get the local interface address of Kamailio where the request was received with $Ri, but I guess you want the IP address of the target host. If you are dealing with locally registered users only, you can use the request URI after

[SR-Users] remote ip address of sender and receiver

2017-06-29 Thread vuleetu
Hi, all Is there any way to get remote ip address of both sender($si) and receiver(?)? I am configuring kamailio with multiple rtpproxy sets. Basically, rtpproxy set will be choosed based on the country those ip addresses of caller and callee belong to. Lets say if caller and callee are both