Child of:
MISC-2: Make bentasker.co.uk Available as Tor Hidden Service
Description
For any error generated by the reverse proxy at Tor's end, need to create a custom error page detailing useful information (for example, where we block tor2web it'd be helpful to explain why the request has been blocked).
Have configured a basic notification page for tor2web pages, but because NGinx is being a pain, it doesn't really return an appropriate status code. Currently it'll 301 the visitor to a page called 405.html which details why the request was blocked.
For some reason, NGinx seems to be quite determined not to use custom error pages for 405/406 etc, will come back and look at sorting that out later. For now the config in place is
error_page 405 = /405.html; # This has no impact currently
location /405.html {
root /usr/share/nginx/onions/bentaskercouk;
}
if ($http_x_tor2web){
set $tor2web T;
}
# Avoid redirect loops
if ($request_uri = '/405.html'){
set $tor2web R;
}
if ($tor2web = T){
return 301 /405.html;
}
Activity
2015-05-21 16:29:58
2015-05-22 15:42:00
For some reason, NGinx seems to be quite determined not to use custom error pages for 405/406 etc, will come back and look at sorting that out later. For now the config in place is
2015-05-22 17:24:51
2017-07-06 15:55:32
2017-07-06 15:55:32
2017-07-06 15:55:37