RE: [squid-users] SQUID behind SOCKS5

From: Henrik Nordstrom <henrik_at_henriknordstrom.net>
Date: Sun, 22 Jun 2008 02:37:42 +0200

On sön, 2008-06-22 at 06:25 +0800, Chad Z. Hower aka Kudzu wrote:

> I know how to do that, but I need the reverse. Not SSH to SQUID, but SQUID to SSH or SOCKS5.

Then do Squid -> SSH -> Squid.

How do you connect to the Internet over SSH? There must be something I
miss here...

> I'm not super fond of C/C++ so I'm not a good candidate. Actually I
> could make the changes if I didn’t kill myself trying to get it to
> build first. SOCKS5 support is really really easy. I've built it into
> other apps in other languages. All that needs to be done is for each
> outbound socket to create a small struct, and instead of opening the
> TCP connection to the real destination, open it to the SOCKS server
> and write the structure after connection. The struct contains the real
> destination info. It really is a few lines of code.

Exactly.

And in Squid it's pretty much isolated to what happens around the
commConnectStart() call.

To get it to use SOCKS5 for DNS lookups as well is perhaps a little
tricker however.. but only needed if yuu really need DNS resolving for
acl checks etc..

Regards
Henrik

Received on Sun Jun 22 2008 - 00:37:47 MDT

This archive was generated by hypermail 2.2.0 : Sun Jun 22 2008 - 12:00:04 MDT