Questions tagged [socks]

Socket Secure (SOCKS for short) is an Internet protocol that routes network packets between a client and server through a Proxy server.

Resources:

  • RFC 1928 SOCKS Protocol Version 5
  • RFC 1929 Username/Password Authentication for SOCKS V5
  • RFC 1961 GSS-API Authentication Method for SOCKS Version 5
  • RFC 3089 A SOCKS-based IPv6/IPv4 Gateway Mechanism
774 questions
118
votes
9 answers

How to make python Requests work via SOCKS proxy

I'm using the great Requests library in my Python script: import requests r = requests.get("http://example.com") print(r.text) I would like to use a SOCKS proxy, how can I do that? Requests seems to only support HTTP proxies.
lithuak
  • 6,028
  • 9
  • 42
  • 54
106
votes
8 answers

Using a socks proxy with git for the http transport

How to make git use a socks proxy for HTTP transport? I succeed in configuring git with GIT_PROXY_COMMAND to use a socks proxy for GIT transport. Also, I have configured my .curlrc file to defined the socks proxy and I can fetch information directly…
Yves Blusseau
  • 4,244
  • 4
  • 16
  • 7
89
votes
17 answers

Python's requests "Missing dependencies for SOCKS support" when using SOCKS5 from Terminal

I'm trying to interact with an API from my Python 2.7 shell using a package that relies on Python's requests. Thing is the remote address is blocked by my network (university library). So to speak to the API I do the following: ~$ ssh -D 8080…
BringBackCommodore64
  • 4,910
  • 3
  • 27
  • 30
66
votes
2 answers

How to disable debug messages on sockjs- STOMP

I have the follow situation: var options = { protocols_whitelist : [ "websocket", "xhr-streaming", "xdr-streaming", "xhr-polling", "xdr-polling", "iframe-htmlfile", "iframe-eventsource", "iframe-xhr-polling" ], debug : false …
J.R.
  • 2,335
  • 2
  • 19
  • 21
48
votes
3 answers

How can I use a SOCKS 4/5 proxy with urllib2?

How can I use a SOCKS 4/5 proxy with urllib2 to download a web page?
Mike
  • 483
  • 1
  • 5
  • 4
42
votes
6 answers

How to run multiple Tor processes at once with different exit IPs?

I am brand new to Tor and I feel like multiple Tors should be considered. The multiple tors I mentioned here are not only multiple instances, but also using different proxy ports for each, like what has been done here…
B.Mr.W.
  • 18,910
  • 35
  • 114
  • 178
32
votes
2 answers

Why are HTTP proxies able to support protocols like IRC and FTP?

I understand that a SOCKS proxy only establishes a connection at the TCP level while an HTTP proxy interprets traffic at HTTP level. Thus a SOCKS proxy can work for any kind of protocol while an HTTP Proxy can only handle HTTP traffic. But why does…
Khue Vu
  • 3,112
  • 4
  • 37
  • 40
22
votes
3 answers

Selenium chrome driver socks proxy configuration

I am having troubles in setting socks proxy for chrome driver Proxy proxy = new Proxy(); proxy.setProxyType(Proxy.ProxyType.MANUAL); proxy.setAutodetect(false); proxy.setSocksProxy(ProxyHelper.PROXY_HOST + ":" +…
skuzuc
  • 255
  • 1
  • 2
  • 6
22
votes
3 answers

How to use a SOCKS 5 proxy with cURL?

Normal proxies (ex: 72.41.132.22:3128) work well with cURL, however when I use SOCKS 5 proxies with username/pass, It just gives me "[1" on the page. Is there a way to use SOCKY 5 proxies with cURL ? $proxy =…
user198989
  • 4,574
  • 19
  • 66
  • 95
22
votes
6 answers

Use WebClient with socks proxy

Is there any way to use a socks proxy with WebClient? Specifically with the DownloadString method that it provides? I don't want to use any third party stuff like privoxy, freecap whatever and I can't use commercial libraries like those from…
Para
  • 2,022
  • 5
  • 34
  • 73
20
votes
1 answer

How to set nonProxyHosts for a SOCKS proxy?

I want to set the nonProxyHosts list for a SOCKS5 proxy, i.e. the list of hostnames to which a direct connection should be used. As the oracle docs describe, there are options named http.nonProxyHosts and ftp.nonProxyHosts to set proxy exclusions…
unwichtich
  • 13,712
  • 4
  • 53
  • 66
20
votes
4 answers

How to use Socks 5 proxy with Apache HTTP Client 4?

I'm trying to create app that sends HTTP requests via Apache HC 4 via SOCKS5 proxy. I can not use app-global proxy, because app is multi-threaded (I need different proxy for each HttpClient instance). I've found no examples of SOCKS5 usage with HC4.…
user3511070
  • 203
  • 1
  • 2
  • 4
18
votes
3 answers

Python urllib over TOR?

Sample code: #!/usr/bin/python import socks import socket import urllib2 socks.setdefaultproxy(socks.PROXY_TYPE_SOCKS4, "127.0.0.1", 9050, True) socket.socket = socks.socksocket print…
OJW
  • 4,514
  • 6
  • 40
  • 48
17
votes
5 answers

Use socks5 proxy from host for docker build

To build a certain image I need to create a tunnel and make docker use this tunnel as a socks5 proxy (to use the proxy for DNS too). So now i've got several problems: How to make docker use the proxy that is on the host? How to make docker use the…
JSamir
  • 1,057
  • 1
  • 10
  • 20
17
votes
3 answers

How do I install Socks / SocksIPy on Ubuntu?

I am new to python and would like to install SocksIPy on Ubuntu (running within a VirtualBox vm). The README says to place the socks.py file into my lib/site-packages directory. I do not know where to locate this directory. The Terminal command …
user1868039
  • 173
  • 1
  • 1
  • 5
1
2 3
51 52