Hi All,
Having the following Header:
Record-Route:
How can i extract only IP value from this header?
Thank You.___
Kamailio (SER) - Users Mailing List
sr-users@lists.kamailio.org
https://lists.kamailio.org/cgi-bin/mailman/listinfo/sr-users
Hi,
On Sat, Oct 28, 2017 at 05:34:04PM +0300, Soltanici Ilie wrote:
> Having the following Header:
> Record-Route:
>
> How can i extract only IP value from this header?
Generally, when presented with a URI, you can extract the host/domain
component using the URI transformations, e.g.
$(hd
Hi Alex,
Thank You, i'm trying to use this config:
if($(hdr(Record-Route)[0]{nameaddr.uri}) != $si and
$(hdr(Record-Route)[0]{nameaddr.uri}) != $null) {
xlog("L_INFO","Spoofing attack detected from $si, blocking");
exit;
} taken from here:
Hi,
A cleaner solution might make use of this, when processing in-dialog
requests where the Record-Route would have been turned into a Route set:
https://www.kamailio.org/wiki/cookbooks/5.0.x/pseudovariables#route_uri_-_uri_in_first_route_header
You could set a dialog-persistent variable indicat