[PATCH] Implement std.ip() to simplify ACL checking in VCL

Poul-Henning Kamp phk at phk.freebsd.dk
Mon Aug 5 07:12:11 CEST 2013


In message <CAK-wPOj1RtSKwDzvO5pvZ2NMXEXHCiB2N+MDokppM5crHKqyaA at mail.gmail.com>
, Leif Pedersen writes:

>> > - Using VCL_IP for the fallback parameter restricts what you can use to
>> > client.ip or server.ip. This might or might not be a problem.
>> > I wrote a similar function a while ago that was using a STRING parameter as
>> > suggested by Tollef. Not sure if this is still required.

VCL_IP is the right type.

I can't remember if VCC has code to type-convert a STRING to IP, but
if not, that should be added.

-- 
Poul-Henning Kamp       | UNIX since Zilog Zeus 3.20
phk at FreeBSD.ORG         | TCP/IP since RFC 956
FreeBSD committer       | BSD since 4.3-tahoe    
Never attribute to malice what can adequately be explained by incompetence.



More information about the varnish-dev mailing list