Filtering by specific cookie

Per Buer perbu at linpro.no
Sun Oct 19 08:02:49 CEST 2008


Mikkel Høgh skrev:

> In http://varnish.projects.linpro.no/wiki/VCLExampleRemovingSomeCookies,
> the example shows removing cookies with regular expressions via the
> regsub function which I can't seem to find documentation on.
> Is there a similar function just for checking whether there's a match,
> or even better, a way to check this that doesn't involve regular
> expressions?

in vcl_revc you can do stuff like:

if (req.http.cookie ~ "foo.*bar|bar.*foo") {
	lookup;
}

-- 
Per Buer - Leder Infrastruktur og Drift - Redpill Linpro
Telefon: 21 54 41 21 - Mobil: 958 39 117
http://linpro.no/ | http://redpill.se/

-------------- next part --------------
A non-text attachment was scrubbed...
Name: signature.asc
Type: application/pgp-signature
Size: 252 bytes
Desc: OpenPGP digital signature
URL: <https://www.varnish-cache.org/lists/pipermail/varnish-misc/attachments/20081019/0c884a11/attachment-0002.pgp>


More information about the varnish-misc mailing list