3 ms·
You will probably have to write a VCL plugin if you want to parse the cookie, but that's not a huge hassle.
by Argorak 12y ago
You will probably have to write a VCL plugin if you want to parse the cookie, but that's not a huge hassle.
- acdha 12y agoYou can handle cookies in pure VCL – the code's not particularly elegant but it's manageable for light usage: https://www.varnish-cache.org/trac/wiki/VCLExampleRemovingSomeCookies https://www.varnish-cache.org/trac/wiki/VCLExampleRemovingSo...
- Argorak 12y agoI'm not sure whether I would call "munging the cookie header with regexps" "cookie handling" ;).
- acdha 12y agoAgreed – it's possible and for simple tasks such as stripping an analytics cookie it's workable but for anything more serious you'd want something like https://github.com/lkarsten/libvmod-cookie https://github.com/lkarsten/libvmod-cookie