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 have a working SOCKS proxy, which I set up with the command ssh -D 9999 user@host. As mentioned, this works great, and when I browse the public IP is that of the server that I connected to via SSH.

My network overview is:

local pc --> server (local network, running ssh -D command) --> remote server (proxy)

I have run into an issue with a device that can only use a HTTP proxy, so I have set up squid on the local network server. I can access the proxy without any issues, but the IP address displayed is that of my local network, not the proxy.

How can I configure squid to use the socks proxy that I have set up via SSH?


share|improve this question

migrated from stackoverflow.com Feb 11 '12 at 5:16

This question came from our site for professional and enthusiast programmers.

Your question is not programming-related and thus is offtopic here –  Eugene Mayevski 'EldoS Corp Jan 25 '12 at 17:03

2 Answers 2

Maybe you need to remove the X-Forwarded-For headers from your requests to the remote proxy.

On the local squid server's config file, try adding

forwarded_for off
share|improve this answer

Instead of Squid, consider using Privoxy or Polipo, which allows you to forward connections to a upstream SOCKS proxy.

[device]---8118---[privoxy/polipo]---1080---[socks proxy]---80---[http server]

That said, you may still need to

share|improve this answer

Your Answer


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