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.

I'd like traffic to be routed via a proxy or VPN based on a the client's hosts file (or DNS that is given to the client).

This doesn't seem like a problem for http traffic on port 80 as a simple squid proxy can do that however I don't know which protocols the client will be sending so I need to proxy all ports.

I have no control over the client apart from hosts/DNS.

Typical Proxy - Can only work for certain protocols/ports

SOCKS Proxy - Works for all but requires client config

VPN - Works for all but requires client config

How can I have a Proxy or VPN that listens on all ports and will act as a transparent endpoint for certain hosts?

Thank you very much in advance.

share|improve this question
    
i think squid do it for you:tldp.org/HOWTO/TransparentProxy.html, but i prefer you to use OpenVPN, or poptop –  pylover Jan 8 '13 at 1:32
    
@pylover - how do you propose using Squid to proxy anything other than HTTP and possibly FTP? –  EEAA Jan 8 '13 at 1:37
    
you can use squid as a transparent proxy behind a VPN. see the link. i already tested it in my private ubuntu server. –  pylover Jan 8 '13 at 1:40
    
@pylover - Sure for HTTP and FTP. Doesn't help you with anything else, though. Besides, the OP mentioned that VPN isn't a possibility. –  EEAA Jan 8 '13 at 1:43

1 Answer 1

Well I think you've answered your own question. You're out of luck.

It is very odd to only have administrative access to DNS and host file configuration on your clients. What is your use case here? Typically in this situation, one would install a VPN client and a default route pointing through the tunnel.

share|improve this answer
    
The thing is, I know it's possible as there are a number of sites doing it which is what I'm trying to emulate such as Overplay and unblock-us. Obviously what they have is proprietary so they won't share but it's really bugging me that I can't work out how they do it! –  Dogsbody Jan 16 '13 at 12:43
    
sshuttle pretty much does what I want but I don't think that's ready for production. –  Dogsbody Jan 16 '13 at 12:47

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.