[OpenSIPS-Users] How much A records are retained in IP comparison
Dave Singer
dave.singer at wideideas.com
Wed Mar 2 18:49:42 CET 2011
Igor,
I'm pretty sure that won't work at all. You would need to use the
transformation ip.resolve.
I don't know if it returns multiple IPs but if it does you would want to
assign it to an avp that can handle multiple.
An example to try:
$var(fqdn) = "some.server.com"; # Not sure if you can do a transformation
directly on a string. Never tried.
$avp(s:ips) = $(var(fqdn){ip.resolve});
xlog("INFO", "$(avp(s:ips)[0])::$(avp(s:ips)[1])::$(avp(s:ips)[2])\n");
if ( avp_check("$avp(s:ips)", "eq/$si/") ) { .... }
Let me know what you find.
Dave
On Wed, Mar 2, 2011 at 9:20 AM, Igor Solovyov <igor at choochee.com> wrote:
> Hi,
>
> If I use
> if ($si=="some.server.com")
> {
> ...
> }
> and some.server.com has several A records,
> are all of them used in upper comparison?
> How does TTL influence on saved IPs?
>
> Regards,
> Igor.
>
> _______________________________________________
> Users mailing list
> Users at lists.opensips.org
> http://lists.opensips.org/cgi-bin/mailman/listinfo/users
>
>
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://lists.opensips.org/pipermail/users/attachments/20110302/6d3d356a/attachment.htm>
More information about the Users
mailing list