varnish and cookie being set by backend

Paul McInerney Paul.McInerney at
Tue Aug 27 08:50:15 CEST 2013

Hi all,

I have another problem I am trying to solve.

One of the sites that sits behind a varnish service, uses an on_page_load module that sends a pop-up asking for an email address (for mail list subscription). It needs to then set a cookie that expires in 30 days (so visitors aren't constantly hit with this pop-up)

So, in vcl_fetch, I have this:

        if (!beresp.http.set-cookie ~ "modaldone"){
                unset beresp.http.set-Cookie;

Where 'modaldone' is the name of the cookie being set by the backend - yet this still doesn't get set.

Here's the complete dump of default.vcl

Have I missed something obvious?

Many thanks.

-------------- next part --------------
An HTML attachment was scrubbed...
URL: <>

More information about the varnish-misc mailing list