What's new

LAN Clients to External SOCKS5 Proxy

  • SNBForums Code of Conduct

    SNBForums is a community for everyone, no matter what their level of experience.

    Please be tolerant and patient of others, especially newcomers. We are all here to share and learn!

    The rules are simple: Be patient, be nice, be helpful or be gone!

vertigo888

Occasional Visitor
Hi - Is it possible to re-direct LAN clients/ports to an external authenticated socks5 proxy? I can't find any posts about this.
 
I have seen settings on socks5 proxy in DNSCrypt-proxy v2 (never tested it)
From settings file:
Code:
## SOCKS proxy
## Uncomment the following line to route all TCP connections to a local Tor node
## Tor doesn't support UDP, so set `force_tcp` to `true` as well.

# proxy = 'socks5://127.0.0.1:9050'


## HTTP/HTTPS proxy
## Only for DoH servers

# http_proxy = 'http://127.0.0.1:8888'
DNSCrypt-proxy v2 can be installed via amtm or dnscrypt installer thread
 
I have seen settings on socks5 proxy in DNSCrypt-proxy v2 (never tested it)
From settings file:
Code:
## SOCKS proxy
## Uncomment the following line to route all TCP connections to a local Tor node
## Tor doesn't support UDP, so set `force_tcp` to `true` as well.

# proxy = 'socks5://127.0.0.1:9050'


## HTTP/HTTPS proxy
## Only for DoH servers

# http_proxy = 'http://127.0.0.1:8888'
DNSCrypt-proxy v2 can be installed via amtm or dnscrypt installer thread


Thanks - doesn't look like what I'm looking for. I have 1 single LAN client that I want to push through an external hosted SOCKS5 proxy with username and password. Any ideas anyone?
 
Last edited:
Thanks - doesn't look like what I'm looking for. I have 1 single LAN client that I want to push through an external hosted SOCKS5 proxy with username and password. Any ideas anyone?
Would a simple rule such as this work?
Code:
iptables -t nat -A PREROUTING -s xxx.xxx.xxx.xxx -i br0 ! -d $(nvram get lan_ipaddr_rt)/24 -p tcp --dport 80 -j DNAT --to socks5proxyIP:port
 
Last edited:
Would a simple rule such as this work?
Code:
iptables -t nat -A PREROUTING -s xxx.xxx.xxx.xxx -i br0 '!' -d $(nvram get lan_ipaddr_rt)/24 -p tcp --dport 80 -j DNAT --to socks5proxyIP:port


Thank Martineau - this external hosted proxy requires username and password for authentication. Otherwise this'd work, or am I missing something here?
 
Thank Martineau - this external hosted proxy requires username and password for authentication. Otherwise this'd work, or am I missing something here?
You would manually enter your login credentials when presented with a GUI or why not simply issue a curl/wget with the UserID/Password in the URL to automate it?
 
Ok so I solved this issue, what I was trying to do is to use a socks5 proxy with authentication details with my Transmission client.

In the end curl was the clue to the answer, added the following to my Transmission service under init.d folder

Code:
export http_proxy=socks5h://username:password@someproxy.com:someport

(if username contains @, replace with %40 instead)
 
Ok so I solved this issue, what I was trying to do is to use a socks5 proxy with authentication details with my Transmission client.

In the end curl was the clue to the answer, added the following to my Transmission service under init.d folder

Code:
export http_proxy=socks5h://username:password@someproxy.com:someport

(if username contains @, replace with %40 instead)
Again, classic case of not disclosing the actual FULL requirements (with a misleading thread title), i.e. it's not actually a LAN device, but the use of a specific app (Transmission) that needs the proxy. :rolleyes:
 

Latest threads

Sign Up For SNBForums Daily Digest

Get an update of what's new every day delivered to your mailbox. Sign up here!
Top