Re: [SR-Users] using myself in equation with from_uri

2016-01-25 Thread Dirk Teurlings - SIGNET B.V.
On 25-01-16 12:49, Daniel-Constantin Mierla wrote: > It should not matter the version, there was no change to is_myself() in > the recent releases Thanks everyone, works like a charm! Cheers, Dirk ___ SIP Express Router (SER) and Kamailio (OpenSER

Re: [SR-Users] using myself in equation with from_uri

2016-01-25 Thread Daniel-Constantin Mierla
OK, thanks for confirming with the docs, I was not sure about it anymore, although I wrote is_myself() function for config (too many functions to remember by heart, that's why I do open source, to check the code :-) ) -- knowing that works always with a sip address, I just wanted to point and try w

Re: [SR-Users] using myself in equation with from_uri

2016-01-25 Thread Dmitri Savolainen
according to docs it takes IP as well: *uri* - Valid SIP URI or IP address to check against the list of local IP addresses or domains. In my instance it works with domain only (version 4.2 checked) 2016-01-25 11:22 GMT+03:00 Daniel-Constantin Mierla : > Hello, > > On 22/01/16 17:10, Dirk Teurli

Re: [SR-Users] using myself in equation with from_uri

2016-01-25 Thread Daniel-Constantin Mierla
Hello, On 22/01/16 17:10, Dirk Teurlings - SIGNET B.V. wrote: > On 22-01-16 11:31, Daniel-Constantin Mierla wrote: >> try with is_myself("sip:$fU@fd"). > Hi Daniel, > > Thanks for the quick response. Comparing the from_uri to myself should > only compare IP or domain name correct? So wouldn't this

Re: [SR-Users] using myself in equation with from_uri

2016-01-23 Thread Dmitri Savolainen
it is possible to use is_myself("$fd"), but there are some issues: if you listen on IP like "listen=xxx.xxx.xxx.xxx", $fd have to be reverse DNS lookup for this IP ; alias and auto_aliases

Re: [SR-Users] using myself in equation with from_uri

2016-01-22 Thread Dirk Teurlings - SIGNET B.V.
On 22-01-16 11:31, Daniel-Constantin Mierla wrote: > try with is_myself("sip:$fU@fd"). Hi Daniel, Thanks for the quick response. Comparing the from_uri to myself should only compare IP or domain name correct? So wouldn't this be enough as a domain check? is_myself("$fd") Cheers, Dirk __

Re: [SR-Users] using myself in equation with from_uri

2016-01-22 Thread Daniel-Constantin Mierla
Hello, try with is_myself("sip:$fU@fd"). That is a function that matches the same addresses as myself condition. Cheers, Daniel On 22/01/16 11:05, Dirk Teurlings - SIGNET B.V. wrote: > Hi, > > The documentation states the following. > https://www.kamailio.org/wiki/cookbooks/4.2.x/core#myself >

[SR-Users] using myself in equation with from_uri

2016-01-22 Thread Dirk Teurlings - SIGNET B.V.
Hi, The documentation states the following. https://www.kamailio.org/wiki/cookbooks/4.2.x/core#myself if(uri==myself) { log("the request is for local processing\n"); }; Now this could also be used to do something like this: (also used in some examples) if(from_uri==myself) { log("the reques