[Pdns-users] lua variables

Peter van Dijk peter.van.dijk at netherlabs.nl
Mon Sep 16 07:45:10 UTC 2013


Hello,

On Sep 12, 2013, at 22:39 , chayes wrote:

> I'd like to isolate the domain inside of an lua script.
> I know about the "domain" variable ... but it can contain subdomain like
> "alt1-safebrowsing.google.com."
> Is there a variable that only contains the "google.com" in the above
> example? 
> Or do I have to do the string manipulation to get it?


The Recursor does not know what humans consider 'domains', so it has no idea.

You will have to do your own string manipulation - as soon as you figure out what "domain" means to you.

Kind regards,
-- 
Peter van Dijk
Netherlabs Computer Consulting BV - http://www.netherlabs.nl/

-------------- next part --------------
A non-text attachment was scrubbed...
Name: signature.asc
Type: application/pgp-signature
Size: 841 bytes
Desc: Message signed with OpenPGP using GPGMail
URL: <http://mailman.powerdns.com/pipermail/pdns-users/attachments/20130916/26b81005/attachment-0001.sig>


More information about the Pdns-users mailing list