DEV Community

RAHUL DHOLE
RAHUL DHOLE

Posted on

SOCKS5 Proxy Quickstart

Dante SOCKS5 Proxy Server

sudo apt update
sudo apt -y install dante-server
sudo systemctl is-enabled danted
sudo cp /etc/danted.conf{,.bak}
Enter fullscreen mode Exit fullscreen mode

sudo nano /etc/danted.conf # change internet port eth0

logoutput: syslog
user.privileged: root
user.unprivileged: nobody

# The listening network interface or address.
internal: 0.0.0.0 port=1080

# The proxying network interface or address.
external: eth0 # *IMP internet port

# socks-rules determine what is proxied through the external interface.
socksmethod: username

# client-rules determine who can connect to the internal interface.
clientmethod: none

client pass {
    from: 0.0.0.0/0 to: 0.0.0.0/0
}

socks pass {
    from: 0.0.0.0/0 to: 0.0.0.0/0
}
Enter fullscreen mode Exit fullscreen mode

Secure SOCKS5

Create a non shell blank secure user

sudo useradd -r -s /bin/false your_dante_user
sudo passwd your_dante_user
Enter fullscreen mode Exit fullscreen mode
sudo systemctl restart danted.service
systemctl status danted.service
Enter fullscreen mode Exit fullscreen mode

Test

curl -v -x socks5://rahul-socks:password@172.27.7.9:1080 http://example.com/
Enter fullscreen mode Exit fullscreen mode
ssh -N -D 1080 rahul-socks@172.27.7.9
Enter fullscreen mode Exit fullscreen mode

Image of Timescale

Timescale – the developer's data platform for modern apps, built on PostgreSQL

Timescale Cloud is PostgreSQL optimized for speed, scale, and performance. Over 3 million IoT, AI, crypto, and dev tool apps are powered by Timescale. Try it free today! No credit card required.

Try free

Top comments (0)

Sentry image

See why 4M developers consider Sentry, “not bad.”

Fixing code doesn’t have to be the worst part of your day. Learn how Sentry can help.

Learn more

👋 Kindness is contagious

Immerse yourself in a wealth of knowledge with this piece, supported by the inclusive DEV Community—every developer, no matter where they are in their journey, is invited to contribute to our collective wisdom.

A simple “thank you” goes a long way—express your gratitude below in the comments!

Gathering insights enriches our journey on DEV and fortifies our community ties. Did you find this article valuable? Taking a moment to thank the author can have a significant impact.

Okay