Advertisement
Guest User

Untitled

a guest
Jul 27th, 2017
79
0
Never
Not a member of Pastebin yet? Sign Up, it unlocks many cool features!
text 0.62 KB | None | 0 0
  1. backend default {
  2. .host = "127.0.0.1";
  3. .port = "8080";
  4. }
  5.  
  6. # Drupal.toolbar.collapsed=0
  7. sub vcl_recv {
  8. remove req.http.X-Forwarded-For;
  9. set req.http.X-Forwarded-For = client.ip;
  10.  
  11. // Remove has_js and Google Analytics __* cookies.
  12. set req.http.Cookie = regsuball(req.http.Cookie, "(^|;\s*)(__[a-z]+|has_js)=[^;]*", "");
  13. // Remove a ";" prefix, if present.
  14. set req.http.Cookie = regsub(req.http.Cookie, "^;\s*", "");
  15. // Remove empty cookies.
  16. if (req.http.Cookie ~ "^\s*$") {
  17. unset req.http.Cookie;
  18. }
  19.  
  20. }
  21.  
  22. sub vcl_hash {
  23. if (req.http.Cookie) {
  24. set req.hash += req.http.Cookie;
  25. }
  26. }
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement