Take the 2-minute tour ×
Server Fault is a question and answer site for professional system and network administrators. It's 100% free, no registration required.

do you think it is possible to configure the net firewall or proxy or the webserver to redirect every http request (not from proxy server) to a static web page that tells the user how to configure his browser with the correct proxy? I know i can broadcast the proxy.pac configuration, but maybe someone (maybe a guest) could try to connect directly.

Thank you.

share|improve this question

2 Answers 2

up vote 0 down vote accepted

You need to configure the firewall to DNAT all outgoing connections to port 80 (except for connections from the proxy server) to a webserver. The webserver must respond to all requests (i.e. all hostnames and all URL paths) with the page you want to display.

share|improve this answer

You can always configure proxy server to pass additional parameter in headers indicating what is the orginal client ip address that is sending this request. If the parameter will be missing in the request header you will know that the request is direct and you can generate HTTP 400 Bad request Error code, or if you prefer you can generate with php custom page with redirect in meta tag, which will redirect the connection to specific URL.

Here you have a SQUID config for the mentioned additional Header: http://www.squid-cache.org/Doc/config/forwarded_for/

share|improve this answer
    
Hello, sorry maybe i was not very clear. If a client send a request to www.google.it without the proxy configuration it arrives directly to the gateway... maybe you mean i need to configure the gateway responding http request from client with a warning page? –  Tobia Jul 26 '12 at 14:38
    
If you want to limit the access to the internet so only via proxy it will work then create a rule on the gateway to redirect all IP traffic destined to port 80/443 to the specific url/ip of the server hosting page with the advise how to configure proxy. Do this for all IPs except one - your proxy server. –  mnmnc Jul 26 '12 at 14:44

Your Answer

 
discard

By posting your answer, you agree to the privacy policy and terms of service.

Not the answer you're looking for? Browse other questions tagged or ask your own question.