rofl0r / rofl0r/proxychains-ng
proxychains only works with HTTPS protocol and displays "denied" with HTTP protocol when combined with squid proxy
Nobody has claimed this yet.
- Dominant language
- C
- Stars
- 10.7k
- Forks
- 1.1k
- PR merge metrics
- No merged PRs in 30d
Description
Tested with proxychains-ng 4.13 and squid 4.1 packages from Ubuntu 18.10. Also reproduced with the latest proxychains-ng 4.13 release and Git version of this GitHub repository.
Proxychains fails when doing an HTTP request to a domain like example.com:
bapt@dell:~$ proxychains curl http://example.com
[proxychains] config file found: /etc/proxychains.conf
[proxychains] preloading /usr/lib/x86_64-linux-gnu/libproxychains.so.4
[proxychains] DLL init: proxychains-ng 4.13
[proxychains] Strict chain ... 127.0.0.1:3128 ... 93.184.216.34:80 <--denied
[proxychains] Strict chain ... 127.0.0.1:3128 ... 2606:2800:220:1:248:1893:25c8:1946:80 <--denied
curl: (7) Couldn't connect to server
bapt@dell:~$
However it works when doing an HTTPS request to the same domain:
bapt@dell:~$ proxychains curl https://example.com
[proxychains] config file found: /etc/proxychains.conf
[proxychains] preloading /usr/lib/x86_64-linux-gnu/libproxychains.so.4
[proxychains] DLL init: proxychains-ng 4.13
[proxychains] Strict chain ... 127.0.0.1:3128 ... 93.184.216.34:443 ... OK
<!doctype html>
<html>
...
</html>
bapt@dell:~$
I can confirm that the problem comes from proxychains because the squid proxy works correctly without proxychains if I set the http_proxy and https_proxy shell variables:
bapt@dell:~$ export http_proxy=http://localhost:3128
bapt@dell:~$ export https_proxy=http://localhost:3128
bapt@dell:~$ curl http://example.com
<!doctype html>
<html>
...
</html>
bapt@dell:~$ curl https://example.com
<!doctype html>
<html>
...
</html>
bapt@dell:~$
I reproduced the problem when using Firefox with proxychains also. It worked correctly on Firefox when I did not use proxychains and directly configured Firefox preferences to use the proxy.
When using proxychains with another HTTP proxy like Privoxy instead of squid, everything worked correctly for HTTP and HTTPS requests. So it looks like proxychains has an issue when using squid proxy.
By the way, I recently reported another issue on the original proxychains repository but I did not get a reply yet: https://github.com/haad/proxychains/issues/80
Contributor guide
No contributing guide indexed for this repository
First steps
- Read the whole issue, then the project's contributing guide.
- Comment on the issue to say you are picking it up — it saves two people doing the same work.
- Fork the repository and make your change on a branch.
- Open a pull request that references the issue number.
Research direction
Reproduce the failure with proxychains curl http://example.com through Squid at 127.0.0.1:3128, then compare it with HTTPS and Privoxy requests. Trace the HTTP proxy connection path and determine why Squid is reported as denied; done means HTTP requests work through proxychains as they do without it.
Written by the indexing model from the issue text.
Assessment
- Tech stack
- c
- Domain
- networking
- Issue type
- Bug
- Difficulty
- 4/5
- Estimated time
- 3-5 days
- Activity status
- Stale
- Clarity
- Needs clarification
- Newbie friendliness
- 35/100