Skip to content

Instantly share code, notes, and snippets.

@fearblackcat
Last active October 4, 2017 12:05
Show Gist options
  • Save fearblackcat/0b682ddeb12f3dce8df9d8c73291d686 to your computer and use it in GitHub Desktop.
Save fearblackcat/0b682ddeb12f3dce8df9d8c73291d686 to your computer and use it in GitHub Desktop.
Use shadowsocks with command line

First, set up shadowsocks as usual. Suppose your local is running on 127.0.0.1:1080.

Install proxychains.

On Debian/Ubuntu:

apt-get install proxychains On Mac OS X:

brew install proxychains-ng Make a config file at ~/.proxychains/proxychains.conf with content:

strict_chain proxy_dns remote_dns_subnet 224 tcp_read_time_out 15000 tcp_connect_time_out 8000 localnet 127.0.0.0/255.0.0.0 quiet_mode

[ProxyList] socks5 127.0.0.1 1080 Then run command with proxychains. Examples:

proxychains4 curl https://www.twitter.com/ proxychains4 git push origin master Or just proxify bash:

proxychains4 bash curl https://www.twitter.com/ git push origin master

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment