Skip to content

HTTPS clone URL

Subversion checkout URL

You can clone with
or
.
Download ZIP
Browse files

raw synthetic response

  • Loading branch information...
commit 290e3a5de6bee34fc18ef0dac2a54847b6099734 1 parent 5f15653
@comotion authored
Showing with 6 additions and 1 deletion.
  1. +6 −1 vcl/main.vcl
View
7 vcl/main.vcl
@@ -57,6 +57,7 @@ include "/etc/varnish/security/handlers.vcl";
* 803 - Restart, forward to backend honey
* 804 - Synthetic response
* 805 - Attempt to drop or reset the request (not implemented yet)
+ * 808 - Raw synthetic deliver
*/
sub vcl_error {
# are we insecure?
@@ -99,9 +100,13 @@ sub vcl_error {
</body></html>
"};
return (deliver);
- } elsif (obj.status == 805){
+ } elsif (obj.status == 805) {
set obj.status = 501;
set obj.response = "Get outta here";
+ } elsif (obj.status == 808) {
+ set obj.status = 200;
+ set obj.response = "OK";
+ synthetic req.http.X-SEC-Response;
}
# fallthrough to other vcl_error's
}
Please sign in to comment.
Something went wrong with that request. Please try again.