How do you confirm cookies are removed from static files?
Chris Altman
caltman at matterco.com
Wed Sep 29 18:06:25 CEST 2010
I am new to Varnish and have read the documentation. My goal is to remove all cookies from static files. I am using Varnish 2.1.3
My VCL is:
sub vcl_recv {
if (req.url ~ "\.(png|gif|jpg|swf|css|js)$") {
unset req.http.cookie;
}
}
sub vcl_fetch {
if (req.url ~ "\.(png|gif|jpg|swf|css|js)$") {
unset beresp.http.set-cookie;
}
}
Question:
I am confused because it appears the static files are served from Varnish but still have a cookie in their Request Headers. How do I remove the Request Headers cookie? Am I still gaining the benefits of Varnish if the Request Headers cookies exist?
Thank you,
Chris Altman
http://my.perqworks.com
http://prtclr.com
Response Headersview source
Server Apache/2.2.14 (Ubuntu)
X-Powered-By PHP/5.3.2-1ubuntu4.5
Expires Thu, 29 Sep 2011 15:56:42 GMT
Vary Accept-Encoding
Last-Modified Thu, 24 Jun 2010 21:16:50 GMT
Cache-Control max-age=31536000, public
Content-Encoding gzip
Content-Type text/css; charset=utf-8
Content-Length 3339
Date Wed, 29 Sep 2010 15:56:42 GMT
X-Varnish 2062520895
Age 0
Via 1.1 varnish
Connection keep-alive
Request Headersview source
Host my.perqapp.com
User-Agent Mozilla/5.0 (Macintosh; U; Intel Mac OS X 10.6; en-US; rv:1.9.2.10) Gecko/20100914 Firefox/3.6.10
Accept text/css,*/*;q=0.1
Accept-Language en-us,en;q=0.5
Accept-Encoding gzip,deflate
Accept-Charset ISO-8859-1,utf-8;q=0.7,*;q=0.7
Keep-Alive 115
Connection keep-alive
Referer http://my.perqapp.com/login
Cookie perq=20; __utma=90567579.1481902958.1285699566.1285768162.1285775102.4; __utmz=90567579.1285699566.1.1.utmcsr=(direct)|utmccn=(direct)|utmcmd=(none); perqworks=c7jcfkdueap5ggtbds500al703; __utmb=90567579.4.10.1285775102; __utmc=90567579
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <https://www.varnish-cache.org/lists/pipermail/varnish-misc/attachments/20100929/fb23a34d/attachment-0003.html>
More information about the varnish-misc
mailing list