Code Monkey home page Code Monkey logo

rofl0r / proxychains-ng Goto Github PK

View Code? Open in Web Editor NEW
9.5K 229.0 1.1K 694 KB

proxychains ng (new generation) - a preloader which hooks calls to sockets in dynamically linked programs and redirects it through one or more socks/http proxies. continuation of the unmaintained proxychains project. the sf.net page is currently not updated, use releases from github release page instead.

Home Page: http://sourceforge.net/projects/proxychains-ng/files

License: GNU General Public License v2.0

Makefile 2.27% C 96.32% Shell 1.41%
proxychains proxy socks http hook hack preload

proxychains-ng's Introduction

ProxyChains-NG ver 4.17 README
=============================

  ProxyChains is a UNIX program, that hooks network-related libc functions
  in DYNAMICALLY LINKED programs via a preloaded DLL (dlsym(), LD_PRELOAD)
  and redirects the connections through SOCKS4a/5 or HTTP proxies.
  It supports TCP only (no UDP/ICMP etc).

  The way it works is basically a HACK; so it is possible that it doesn't
  work with your program, especially when it's a script, or starts
  numerous processes like background daemons or uses dlopen() to load
  "modules" (bug in glibc dynlinker).
  It should work with simple compiled (C/C++) dynamically linked programs
  though.

  If your program doesn't work with proxychains, consider using an
  iptables based solution instead; this is much more robust.

  Supported Platforms: Linux, BSD, Mac, Haiku.


*********** ATTENTION ***********

  this program can be used to circumvent censorship.
  doing so can be VERY DANGEROUS in certain countries.

  ALWAYS MAKE SURE THAT PROXYCHAINS WORKS AS EXPECTED
  BEFORE USING IT FOR ANYTHING SERIOUS.

  this involves both the program and the proxy that you're going to
  use.

  for example, you can connect to some "what is my ip" service
  like ifconfig.me to make sure that it's not using your real ip.

  ONLY USE PROXYCHAINS IF YOU KNOW WHAT YOU'RE DOING.

  THE AUTHORS AND MAINTAINERS OF PROXYCHAINS DO NOT TAKE ANY
  RESPONSIBILITY FOR ANY ABUSE OR MISUSE OF THIS SOFTWARE AND
  THE RESULTING CONSEQUENCES.

*** Installation ***

  # needs a working C compiler, preferably gcc
  ./configure --prefix=/usr --sysconfdir=/etc
  make
  [optional] sudo make install
  [optional] sudo make install-config (installs proxychains.conf)

  if you dont install, you can use proxychains from the build directory
  like this: ./proxychains4 -f src/proxychains.conf telnet google.com 80

Changelog:
----------
Version 4.17
- add hook for close_range function, fixing newer versions of openssh
- fat-binary-m1 option for mac
- fix DNS error handling in proxy_dns_old
- simplify init code
- fix openbsd preloading
- fix double-close in multithreaded apps
- various improvements to configure script

Version 4.16
- fix regression in configure script linker flag detection
- remove 10 year old workaround for wrong glibc getnameinfo signature
- support for new DYLD hooking method for OSX Monterey
- netbsd compilation fix
- support IPv6 localnets
- more user-friendly error message when execvp fails
- proxy_getaddrinfo(): fill in ai_socktype if requested

Version 4.15
- fix configure script for buggy binutils version
- initialize rand_seed with nano-second granularity
- add support for numeric ipv6 in getaddrinfo
- fix bug in getaddrinfo when node is null and !passive
- add dnat feature
- add raw proxy type
- add haiku support
- add proxy_dns_old to emulate proxychains 3.1 behaviour
- add new proxy_dns_daemon feature (experimental)
- various other fixes

Version 4.14
- allow alternative proto://user:pass@ip:port syntax for proxylist
- fix endless loop in round robin mode when all proxies are down (#147)
- fix compilation on android (#265)
- fix fd leak in forked processes (#273)
- skip connection attempt to nullrouted ips
- allow hostnames for proxylist under specific circumstances

Version 4.13
- fix robustness of DNS lookup thread and a segfault
- fix socks5 user/pass auth on non-conforming servers
- fix memory leak
- add support for Solaris

Version 4.12
- fix several build issues
  - for MAC
  - with -pie
  - with custom CC
- compatibility fix for some GUI apps (8870140)
- compatibility fix for some HTTP proxies (cf9a16d)
- fix several warnings for cleaner build on debian
- fix random_chain on OSX (0f6b226)

Version 4.11
- preliminary IPv6 support
- fixed bug in hostsreader
- preliminary support for usage on OpenBSD (caveat emptor)

Version 4.10
- fix regression in linking order with custom LDFLAGS
- fix segfault in DNS mapping code in programs with > ~400 different lookups

Version 4.9
- fix a security issue CVE-2015-3887
- add sendto hook to handle MSG_FASTOPEN flag
- replace problematic hostentdb with hostsreader
- fix compilation on OpenBSD (although doesn't work there)

Version 4.8.1:
- fix regression in 4.8 install-config Makefile target

Version 4.8:
- fix for odd cornercase where getaddrinfo was used with AI_NUMERICHOST
  to test for a numeric ip instead of resolving it (fixes nmap).
- allow usage with programs that rely on LD_PRELOAD themselves
- reject wrong entries in config file
- print version number on startup

Version 4.7:
- new round_robin chaintype by crass.
- fix bug with lazy allocation when GCC constructor was not used.
- new configure flag --fat-binary to create a "fat" binary/library on OS X
- return EBADF rather than EINTR in close hook.
  it's legal for a program to retry close() calls when they receive
  EINTR, which could cause an infinite loop, as seen in chromium.

Version 4.6:
- some cosmetic fixes to Makefile, fix a bug when non-numeric ip was
  used as proxy server address.

Version 4.5:
- hook close() to prevent OpenSSH from messing with internal infrastructure.
  this caused ssh client to segfault when proxified.

Version 4.4:
- FreeBSD port
- fixes some installation issues on Debian and Mac.

Version 4.3:
- fixes programs that do dns-lookups in child processes (fork()ed),
  like irssi. to achieve this, support for compilation without pthreads
  was sacrified.
- fixes thread safety for gethostent() calls.
- improved DNS handling speed, since hostent db is cached.

Version 4.2:
- fixes compilation issues with ubuntu 12.04 toolchain
- fixes segfault in rare codepath

Version 4.1
- support for mac os x (all archs)
- all internal functions are threadsafe when compiled with -DTHREAD_SAFE
  (default).

Version 4.0
- replaced dnsresolver script (which required a dynamically linked "dig"
  binary to be present) with remote DNS lookup.
  this speeds up any operation involving DNS, as the old script had to use TCP.
  additionally it allows to use .onion urls when used with TOR.
- removed broken autoconf build system with a simple Makefile.
  there's a ./configure script though for convenience.
  it also adds support for a config file passed via command line switches/
  environment variables.

Version 3.0
- support for DNS resolving through proxy
  supports SOCKS4, SOCKS5 and HTTP CONNECT proxy servers.
  Auth-types: socks - "user/pass" , http - "basic".

When to use it ?
1) When the only way to get "outside" from your LAN is through proxy server.
2) To get out from behind restrictive firewall which filters outgoing ports.
3) To use two (or more) proxies in chain:
	like: your_host <--> proxy1 <--> proxy2 <--> target_host
4) To "proxify" some program with no proxy support built-in (like telnet)
5) Access intranet from outside via proxy.
6) To use DNS behind proxy.
7) To access hidden tor onion services.

Some cool features:

* This program can mix different proxy types in the same chain
	like: your_host <-->socks5 <--> http <--> socks4 <--> target_host
* Different chaining options supported
	random order from the list ( user defined length of chain ).
	exact order  (as they appear in the list )
	dynamic order (smart exclude dead proxies from chain)
* You can use it with most TCP client applications, possibly even network
	scanners, as long as they use standard libc functionality.
	pcap based scanning does not work.
* You can use it with servers, like squid, sendmail, or whatever.
* DNS resolving through proxy.


Configuration:
--------------

proxychains looks for config file in following order:
1)	file listed in environment variable PROXYCHAINS_CONF_FILE or
	provided as a -f argument to proxychains script or binary.
2)	./proxychains.conf
3)	$(HOME)/.proxychains/proxychains.conf
4)	$(sysconfdir)/proxychains.conf  **

** usually /etc/proxychains.conf

Usage Example:

	$ proxychains telnet targethost.com

in this example it will run telnet through proxy(or chained proxies)
specified by proxychains.conf

Usage Example:

	$ proxychains -f /etc/proxychains-other.conf telnet targethost2.com

in this example it will use different configuration file then proxychains.conf
to connect to targethost2.com host.

Usage Example:

	$ proxyresolv targethost.com

in this example it will resolve targethost.com through proxy(or chained proxies)
specified by proxychains.conf

Known Problems:
---------------
- newer versions of nmap try to determine the network interface to use
  even if it's not needed (like when doing simple syn scans which use the
  standard POSIX socket API. this results in errors when proxychains hands
  out an ip address to a reserved address space.
  possible workarounds: disable proxy_dns, use a numeric ip, or use nmap's
  native support for SOCKS proxies.

- Mac OS X 10.11 (El Capitan) ships with a new security feature called SIP
  that prevents hooking of system apps.
  workarounds are to partially disable SIP by issuing
  csrutil enable --without debug in recovery mode,
  or to copy the system binary into the home directory and run it from there.
  see github issue #78 for details.

- the glibc dynlinker has a bug or security feature that inhibits dlopen()ed
  modules from being subject to the same dlsym hooks as installed for the main
  program. this mainly affects scripting languages such as perl or python
  that heavily rely on dlopen() for modules written in C to work.
  there are unconfirmed reports that it works as root though.
  musl libc is unaffected from the bug.


Community:
----------
#proxychains on irc.libera.chat

Donations:
----------
bitcoins donations are welcome - please send to this address:
1C9LBpuy56veBqw5N33sZMoZW8mwCw3tPh

proxychains-ng's People

Contributors

amyangfei avatar aviau avatar biergaizi avatar cybershadow avatar david9991 avatar e7appew avatar eehakkin avatar ffontaine avatar forkbomber avatar freed-wu avatar guijan avatar haad avatar jackyzy823 avatar jahrome avatar jaytaylor avatar jianingy avatar low-power avatar mancha1 avatar minoru avatar nmcv avatar ordex avatar papadave66 avatar recolic avatar rofl0r avatar soflare avatar tomgilon avatar tyll avatar urdarinda avatar zenithalhourlyrate avatar

Stargazers

 avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar

Watchers

 avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar

proxychains-ng's Issues

Proxychains4 and Python

I recognized that proxychains4 won't work with Pyhton scripts.

Simple IP checking script:

#!/usr/bin/python
import urllib, json

data = json.loads(urllib.urlopen("http://ip.jsontest.com/").read())
print data["ip"]

Output:

$: ./ip.py
2***:4f8:110:312*::2
$: proxychains4 ./ip.py
[proxychains] config file found: /etc/proxychains.conf
[proxychains] preloading /usr/local/lib/libproxychains4.so
2***:4f8:110:312*::2 # same ip like above
$: curl http://ip.jsontest.com/
{"ip": "2***:4f8:110:312*::2"}
]$: proxychains4 curl http://ip.jsontest.com/
[proxychains] config file found: /etc/proxychains.conf
[proxychains] preloading /usr/local/lib/libproxychains4.so
[proxychains] DLL init: proxychains-ng 4.8.1-git-11-gba61b48
[proxychains] Strict chain  ...  127.0.0.1:9050  ...  ip.jsontest.com:80  ...  OK
{"ip": "91.109.247.173"}

Any hint what causes this and how to resolve this?

proxy address works only as IPv4

when using something like
http my.server.com 8080

proxychains will fail with connection refused.
of course that won't work, since DNS is only resolved on the server

socket error or timeout!

Hi,
I often have to socksify different applications that I use and usually have no problem.
If i run "proxychains4 Armitage" though it looks like it may be timing out...

I have used several other proxychains on it and they work fine...

Armitage is the gui that supports metasploit so while Armitage is loading it also starts
"msfrpcd daemon" which it does fine, and then it has to start "msfconsole" by way of MSGRPC I think...
Anyway that's where it chokes when it is waiting for msfconsole.

Your proxychains are very quick so I've begun using them exclusively and I see now that you are heading up
that project so just wanted to let you know as I'm not the only one who does this for pentesting or hacking etc...

This is the error:
[*] MSGRPC starting on 127.0.0.1:55553 (NO SSL):Msg...
[proxychains4] Strict chain ... 127.0.0.1:9050 ... 127.0.0.1:40481 <-- socket error or timeout!

I tried other proxychains forks today for the same program with no issue...

Thanks
xclr8tr

Versioning libproxychains4 so file

It would be great if we could version the so file. Currently proxychains-ng provide only unversioned so file which usually goes in -dev, -devel packages when one packages it downstream. Versioning the so file would solve such problems.

symbol lookup error: ./libproxychains4.so: undefined symbol: pthread_once

Hello. I am having issues with wget & proxychains4 on Ubuntu:

$ proxychains4 -f /var/storage/random.conf wget -qO- http://ipecho.net/plain ; echo
[proxychains] config file found: /var/storage/random.conf
[proxychains] preloading ./libproxychains4.so
wget: symbol lookup error: ./libproxychains4.so: undefined symbol: pthread_once

Ping works just fine:

$ proxychains4 -f /var/storage/random.conf ping google.com
[proxychains] config file found: /var/storage/configs/random-mixed-pool.conf
[proxychains] preloading ./libproxychains4.so
PING google.com (173.194.67.101) 56(84) bytes of data.
64 bytes from wi-in-f101.1e100.net (173.194.67.101): icmp_seq=1 ttl=49 time=22.0 ms
64 bytes from wi-in-f101.1e100.net (173.194.67.101): icmp_seq=2 ttl=49 time=22.0 ms
64 bytes from wi-in-f101.1e100.net (173.194.67.101): icmp_seq=3 ttl=49 time=21.8 ms
64 bytes from wi-in-f101.1e100.net (173.194.67.101): icmp_seq=4 ttl=49 time=23.0 ms
64 bytes from wi-in-f101.1e100.net (173.194.67.101): icmp_seq=5 ttl=49 time=24.8 ms
64 bytes from wi-in-f101.1e100.net (173.194.67.101): icmp_seq=6 ttl=49 time=22.0 ms
^C
--- google.com ping statistics ---
6 packets transmitted, 6 received, 0% packet loss, time 5006ms
rtt min/avg/max/mdev = 21.891/22.659/24.826/1.063 ms

To install, I cloned this git repo, and ran the following as advised:

sudo ./configure --prefix=/usr --sysconfdir=/etc
sudo make
sudo make install
sudo make install-config

There were no errors returned.

uname -a
Linux lemon 2.6.32-042stab094.7 #1 SMP Wed Oct 22 12:43:21 MSK 2014 x86_64 x86_64 x86_64 GNU/Linux

$ nm /lib/libpthread_.so | grep pthread_once
nm: '/lib/libpthread_.so': No such file

$ for i in /lib /lib32 /lib64 ; do

find $i -name 'libpthread_.so_'
find /usr/$i -name 'libpthread_.so_'
done
/lib/x86_64-linux-gnu/libpthread-2.19.so
/lib/x86_64-linux-gnu/libpthread.so.0
/usr//lib/x86_64-linux-gnu/libpthread.so
find: /lib32': No such file or directory find:/usr//lib32': No such file or directory
find: `/usr//lib64': No such file or directory

$ objdump -T /lib/x86_64-linux-gnu/libpthread-2.19.so | grep pthread_once
000000000000da40 g DF .text 0000000000000070 GLIBC_2.2.5 pthread_once
000000000000da40 g DF .text 0000000000000070 GLIBC_2.2.5 __pthread_once
$ objdump -T /lib/x86_64-linux-gnu/libpthread.so.0 | grep pthread_once
000000000000da40 g DF .text 0000000000000070 GLIBC_2.2.5 pthread_once
000000000000da40 g DF .text 0000000000000070 GLIBC_2.2.5 __pthread_once
$ objdump -T /usr//lib/x86_64-linux-gnu/libpthread.so | grep pthread_once
objdump: /usr//lib/x86_64-linux-gnu/libpthread.so: File format not recognized

$ ldd which wget
linux-vdso.so.1 => (0x00007fff789fe000)
libssl.so.1.0.0 => /lib/x86_64-linux-gnu/libssl.so.1.0.0 (0x00007f537b571000)
libcrypto.so.1.0.0 => /lib/x86_64-linux-gnu/libcrypto.so.1.0.0 (0x00007f537b196000)
libz.so.1 => /lib/x86_64-linux-gnu/libz.so.1 (0x00007f537af7c000)
libidn.so.11 => /usr/lib/x86_64-linux-gnu/libidn.so.11 (0x00007f537ad49000)
libuuid.so.1 => /lib/x86_64-linux-gnu/libuuid.so.1 (0x00007f537ab44000)
libc.so.6 => /lib/x86_64-linux-gnu/libc.so.6 (0x00007f537a77e000)
libdl.so.2 => /lib/x86_64-linux-gnu/libdl.so.2 (0x00007f537a57a000)
/lib64/ld-linux-x86-64.so.2 (0x00007f537b7d8000)

Any ideas what's wrong? Do I have to change something in the Makefile for it to work on my system?

could not load libproxychains4.dylib - image not found

I installed proxychains with the --fat-binary parameter. Everything went fine and the sample command (telnet) from the readme works me fine. I tried to start a cider-wrapper on my MacBook then:

$ proxychains4 /Applications/Games/Guild\ Wars\ 2.app/Contents/MacOS/cider
[proxychains] config file found: /etc/proxychains.conf
[proxychains] preloading ./libproxychains4.dylib
[proxychains] DLL init: proxychains-ng 4.8.1
[proxychains] DLL init: proxychains-ng 4.8.1
[proxychains] DLL init: proxychains-ng 4.8.1
[proxychains] DLL init: proxychains-ng 4.8.1
dyld: could not load inserted library './libproxychains4.dylib' because image not found

When I try the same command with sudo, I get this:
sudo proxychains4 /Applications/Games/Guild\ Wars\ 2.app/Contents/MacOS/cider
[proxychains] config file found: /etc/proxychains.conf
[proxychains] preloading ./libproxychains4.dylib
[proxychains] DLL init: proxychains-ng 4.8.1
[proxychains] DLL init: proxychains-ng 4.8.1
[proxychains] DLL init: proxychains-ng 4.8.1
[proxychains] DLL init: proxychains-ng 4.8.1
[proxychains] DLL init: proxychains-ng 4.8.1
2014-12-17 09:46:34.284 cider[5584:836723] SendRequestWithTimeout failed - no server response
dyld: could not load inserted library './libproxychains4.dylib' because image not found

Any solutions?

Edit: after deleting the directory from where I installed proxychains from, I get this:
sudo proxychains4 /Applications/Games/Guild\ Wars\ 2.app/Contents/MacOS/cider
sudo: cannot get working directory
[proxychains] config file found: /etc/proxychains.conf
[proxychains] preloading /usr/lib/libproxychains4.dylib
[proxychains] DLL init: proxychains-ng 4.8.1
[proxychains] DLL init: proxychains-ng 4.8.1
shell-init: error retrieving current directory: getcwd: cannot access parent directories: No such file or directory
[proxychains] DLL init: proxychains-ng 4.8.1
[proxychains] DLL init: proxychains-ng 4.8.1
shell-init: error retrieving current directory: getcwd: cannot access parent directories: No such file or directory
2014-12-17 09:56:36.300 cider[5699:844452] SendRequestWithTimeout failed - no server response
[proxychains] DLL init: proxychains-ng 4.8.1
[proxychains] Strict chain ... 127.0.0.1:1336 [proxychains] Strict chain ... 127.0.0.1:1336 ... assetcdn.101.arenanetworks.com:80 ... cligate.101.ncplatform.net.:6112 ... OK
<--socket error or timeout!
[proxychains] Strict chain ... 127.0.0.1:1336 ... assetcdn.101.arenanetworks.com:80 ... OK
[proxychains] Strict chain ... 127.0.0.1:1336 ... assetcdn.101.arenanetworks.com:80 ... OK
[proxychains] Strict chain ... 127.0.0.1:1336 ... cligate.101.ncplatform.net.:6112 <--socket error or timeout!
[proxychains] Strict chain ... 127.0.0.1:1336 ... cligate.101.ncplatform.net.:6112 [proxychains] Strict chain ... 127.0.0.1:1336 ... assetcdn.101.arenanetworks.com:80 ... OK
<--socket error or timeout!
[proxychains] Strict chain ... 127.0.0.1:1336 ... assetcdn.101.arenanetworks.com:80 ... OK
[proxychains] Strict chain ... 127.0.0.1:1336 ... assetcdn.101.arenanetworks.com:80 ... OK
[proxychains] Strict chain ... 127.0.0.1:1336 ... cligate.101.ncplatform.net.:6112 <--socket error or timeout!

This loops endlessly, although my socks proxy is working fine. Maybe there's an issue with port 6112?

GitHub source repository reference

Hi rofl0r,

I just got your message about the proxychains repository. I'm glad you are taking some action against this misunderstanding. Thanks for contacting me.
I think one of things that is the main cause for this issue is that the source-forge page is not making any reference to the new source repository. And by the looks of it is still distributing quite a old release of proxychains. Probably changing or updating this reference should get rid of the major confusion.

Cheers.

rpmlint warning: shared-lib-calls-exit

As according to rpmlint warning, the shared library (libproxychains4.so in this case) is calling exit(1) at various places in libproxychains.c.

Quoting from rpmlint documentation for "shared-lib-calls-exit" :
This library package calls exit() or _exit(), probably in a non-fork() context. Doing so from a library is strongly discouraged - when a library function calls exit(), it prevents the calling program from handling the error, reporting it to the user, closing files properly, and cleaning up any state that the program has. It is preferred for the library to return an actual error code and let the calling program decide how to handle the situation.

Hence, some alternative to exit() must be used.

Proxychains dll loading issue

Hi as per your suggestion i tried your version of proxy.

compilation process i used
./configure
make
sudo make install

anant@anant-Studio ~/proxychains $ proxychains4 telnet google.com 80
[proxychains] config file found: /etc/proxychains.conf
[proxychains] preloading /usr/local/lib/libproxychains4.so
telnet: symbol lookup error: /usr/local/lib/libproxychains4.so: undefined symbol: pthread_once

other details

anant@anant-Studio ~ $ file /usr/bin/telnet.netkit
/usr/bin/telnet.netkit: ELF 64-bit LSB executable, x86-64, version 1 (SYSV), dynamically linked (uses shared libs), for GNU/Linux 2.6.15, BuildID[sha1]=0xfe742dee4a474247f9ced957c33b768c2279dc4d, stripped

anant@anant-Studio ~ $ file which wget
/usr/bin/wget: ELF 64-bit LSB executable, x86-64, version 1 (SYSV), dynamically linked (uses shared libs), for GNU/Linux 2.6.24, BuildID[sha1]=0x503d2786854075a5b0e7ee079584b0728a2c006d, stripped

anant@anant-Studio ~ $ file /usr/local/lib/libproxychains4.so
/usr/local/lib/libproxychains4.so: ELF 64-bit LSB shared object, x86-64, version 1 (SYSV), dynamically linked, BuildID[sha1]=0xd3a4ac770326dc94626169b7031078fcbc0ca804, not stripped

anant@anant-Studio ~ $ nm /lib/libpthread.so | grep pthread_once
nm: '/lib/libpthread.so': No such file

However i do have libpthread
anant@anant-Studio ~/proxychains $ file /lib32/libpthread-2.15.so
/lib32/libpthread-2.15.so: ELF 32-bit LSB shared object, Intel 80386, version 1 (SYSV), dynamically linked (uses shared libs), BuildID[sha1]=0x190143c6a1bdd750bab0147f02e8df71fe2e64e7, for GNU/Linux 2.6.24, not stripped

Mac OS X 'make' fails

Hi rofl0r,

When trying to 'make' the current repository of proxychains I get the following error:
cc -shared -fPIC -Wl,--no-as-needed -ldl -lpthread -Wl,-install_name,libproxychains4.dylib -o libproxychains4.dylib src/core.o src/common.o src/libproxychains.o src/shm.o src/allocator_thread.o src/ip_type.o src/stringdump.o src/hostentdb.o src/hash.o
ld: unknown option: --no-as-needed
collect2: ld returned 1 exit status
make: *** [libproxychains4.dylib] Error 1

Is this something on my side or a known issue?

Cheers.

proxychains can't load process....: Permission denied

I'm trying to run an .app file with proxychain4 and I seem to be out of luck:

sudo proxychains4 /Applications/BBC\ iPlayer\ Downloads.app
[proxychains] config file found: /etc/proxychains.conf
[proxychains] preloading ./libproxychains4.dylib
proxychains can't load process....: Permission denied

I can't think of any reason why there could be a permission problem. What could cause this?

php curl module ignores proxychains

try this simple script:

<?php
echo "file_get_contents:\n";
echo file_get_contents("http://ifconfig.me/ip");
echo "curl:\n";
$ch=curl_init();
curl_setopt($ch,CURLOPT_URL,"http://ifconfig.me/ip");
curl_setopt($ch,CURLOPT_HEADER,0);
curl_exec($ch);
curl_close($ch);

assume that my real ip is 123.45.67.89 and socks proxy ip is 10.10.10.10
without proxychains:

# php php_curl.php 
file_get_contents:
123.45.67.89
curl:
123.45.67.89

with proxychains:

# proxychains php php_curl.php 
[proxychains] config file found: /etc/proxychains.conf
[proxychains] preloading /usr/lib/libproxychains4.so
file_get_contents:
10.10.10.10
curl:
123.45.67.89

i.e. curl was not proxified even with proxychains library preloaded.

LD_PRELOAD cannot be preloaded

Hi rofl0r,
Great works! thank you.

Some issue when executing on my machine:
ERROR: ld.so: object '/test/lib/libproxychains4.so' from LD_PRELOAD cannot be preloaded (wrong ELF class: ELFCLASS64): ignored.

Server information:
Ubuntu 14.04.1 LTS running on VMware Workstation
Configure parameters: ./configure --prefix=/test --sbindir=/test --bindir=/test --sysconfdir=/test/etc
Proxychains are compiled from: gcc version 4.8.2 (Ubuntu 4.8.2-19ubuntu1)

Thank you again.

4.8 release?

Hi, sorry to ask (and look like urging), but was the 4.8 release ready and just forgot to tag?

A user of Arch has contacted me for this, and I don't think so myself - but it would be great if you can confirm, thanks!

build fails with error in function 'proxy_getaddrinfo' on SmartOS (Illumios/Solaris)

cat /etc/motd

__ . .
| | | .-. . . .-. :--. |-
|_ _| ;| || |(.-' | | |
|__| --'-' ;-|-' ' ' -' / ; Instance (base-64-lts 14.4.1) -' https://docs.joyent.com/images/smartos/base

]# make
cc -Wall -O0 -g -std=c99 -D_GNU_SOURCE -pipe -DLIB_DIR="/usr/local/lib" -DSYSCONFDIR="/usr/local/etc" -DDLL_NAME="libproxychains4.so" -fPIC -c -o src/core.o src/core.c
src/core.c: In function 'proxy_getaddrinfo':
src/core.c:839:2: error: too many arguments to function 'getservbyname_r'
In file included from src/core.c:23:0:
/usr/include/netdb.h:247:17: note: declared here
Makefile:82: recipe for target 'src/core.o' failed
make: *** [src/core.o] Error 1

I'm try to use the patch in this bug report:
#52

Segmentation fault with SSH

➜ core proxychains4 ssh [email protected]
[proxychains] config file found: /etc/proxychains.conf
[proxychains] preloading /usr/lib/libproxychains4.so
[proxychains] DLL init
[1] 4790 segmentation fault (core dumped) proxychains4 ssh [email protected]

➜ core sudo systemd-coredumpctl gdb 4790
TIME PID UID GID SIG EXE
Sun 2013-01-20 15:12:52 PST 4790 1000 100 11 /usr/bin/ssh
GNU gdb (GDB) 7.5.1
Copyright (C) 2012 Free Software Foundation, Inc.
License GPLv3+: GNU GPL version 3 or later http://gnu.org/licenses/gpl.html
This is free software: you are free to change and redistribute it.
There is NO WARRANTY, to the extent permitted by law. Type "show copying"
and "show warranty" for details.
This GDB was configured as "x86_64-unknown-linux-gnu".
For bug reporting instructions, please see:
http://www.gnu.org/software/gdb/bugs/...
Reading symbols from /usr/bin/ssh...(no debugging symbols found)...done.
[New LWP 4791]
[New LWP 4790]

warning: Could not load shared library symbols for linux-vdso.so.1.
Do you need "set solib-search-path" or "set sysroot"?
[Thread debugging using libthread_db enabled]
Using host libthread_db library "/usr/lib/libthread_db.so.1".
Core was generated by `ssh [email protected]'.
Program terminated with signal 11, Segmentation fault.
#0 0x00007fbb32a0bf73 in buffered_vfprintf () from /usr/lib/libc.so.6

Cant make on x86_64-linux-gnu Debian

I tried with different machines but i always get the same compiling error.

root@iceland:~/proxychains-4.3# ./configure 
done, now run make && make install
root@iceland:~/proxychains-4.3# make
cc -Wall -O0 -g -std=c99 -D_GNU_SOURCE -pipe   -DLIB_DIR=\"/usr/local/lib\" -DSYSCONFDIR=\"/usr/local/etc\" -DDLL_NAME=\"libproxychains4.so\"  -fPIC -c -o src/core.o src/core.c
cc -Wall -O0 -g -std=c99 -D_GNU_SOURCE -pipe   -DLIB_DIR=\"/usr/local/lib\" -DSYSCONFDIR=\"/usr/local/etc\" -DDLL_NAME=\"libproxychains4.so\"  -fPIC -c -o src/common.o src/common.c
cc -Wall -O0 -g -std=c99 -D_GNU_SOURCE -pipe   -DLIB_DIR=\"/usr/local/lib\" -DSYSCONFDIR=\"/usr/local/etc\" -DDLL_NAME=\"libproxychains4.so\"  -fPIC -c -o src/libproxychains.o src/libproxychains.c
src/libproxychains.c:387: error: conflicting types for 'getnameinfo'
/usr/include/netdb.h:677: note: previous declaration of 'getnameinfo' was here
make: *** [src/libproxychains.o] Error 1

root@iceland:~/proxychains-4.3# gcc -v
Using built-in specs.
Target: x86_64-linux-gnu
Configured with: ../src/configure -v --with-pkgversion='Debian 4.4.5-8' --with-bugurl=file:///usr/share/doc/gcc-4.4/README.Bugs --enable-languages=c,c++,fortran,objc,obj-c++ --prefix=/usr --program-suffix=-4.4 --enable-shared --enable-multiarch --enable-linker-build-id --with-system-zlib --libexecdir=/usr/lib --without-included-gettext --enable-threads=posix --with-gxx-include-dir=/usr/include/c++/4.4 --libdir=/usr/lib --enable-nls --enable-clocale=gnu --enable-libstdcxx-debug --enable-objc-gc --with-arch-32=i586 --with-tune=generic --enable-checking=release --build=x86_64-linux-gnu --host=x86_64-linux-gnu --target=x86_64-linux-gnu
Thread model: posix
gcc version 4.4.5 (Debian 4.4.5-8) 

Socket error or timeoute! 127.0.0.1

Hello.
I want try to connect to tor with vip72 client (socks5). This two application use this same ip 127.0.0.1, tor use port 9050, and vip72client 9951 for socks5 or 9953 for http proxy.
I have this error when i want to connect:
Strict chain ... 127.0.0.1:9050 ... 127.0.0.1:9953 <--socket error or timeout!

I have add loopback adress in proxychains.conf:

' localnet 127.0.0.0/255.0.0.0

localnet 127.0.0.0/255.0.0.0

remote_dns_subnet 224

change env variables during execution

Does this new generation proxychains do something with environment variables. It seems that some of the programs that I am running with proxychains-ng and which read environment variables are no longer working because proxychains-ng wouldn't let it read the env variables.

Though I never faced this problem with proxychains 3.1

proxyresolv dig awk fix

Scenario:
proxyresolv wants to resolve omns.americanexpress.com
The executed command is: dig omns.americanexpress.com @8.8.8.8 +tcp | awk '/A.+[0-9]+.[0-9]+.[0-9]/{print $5;}'

Result:
americanexpress.com.102.122.2o7.net.
63.140.32.87

But IP only is expected, proxychains wont work.

FIX:
Change the regex to '/A.?[0-9]+.[0-9]+.[0-9]/{print $5;}'

New result:
63.140.32.87

:)

UDP support /IPv6 support

proxychain does not support UDP and ipv6, how about proxychain-ng.
Actually, is there any document about the change from original proxychain to proxychain-ng. Thank you :)

Possible to exclude certain addresses or ports

I'm using proxychains-ng around a node.js script, however I don't want connections to my database to be proxied. My database isn't hosted locally, it's remotely hosted on AWS, will the localnet rules work for this?

I've tried localnet 0.0.0.0:3306/0.0.0.0 to exclude connections to port 3306 (the port I connect to my AWS database over) but it seems to have no affect.

Allow specifying dns names as proxy hosts

I realize this was disabled in a previous issue. However, there are plenty of cases where dns names can be allowed. For instance, when proxy_dns is off. Perhaps there should be a new option proxy_proxy_dns which should take a parameter, one of: force, disallow, if_possible.

  • force - ensures that no dns requests are leaked.
  • disallow - all dns is done locally
  • if_possible - resolve remotely if possible, otherwise do it locally.

Note that if proxy_proxy_dns = force could still allow proxies to be specified as DNS names by proxying the dns through the partially created proxy chain.

Strict chaining may not be "strict" in multithreaded scenarios

Suppose we have threads T1 and T2, both using a strict proxychain of proxy servers A, B, and C in that order. Further suppose that T2's execution closely follows T1's. It could happen that T1 has just finished connecting and set the proxy to the BUSY_STATE, when T2 is scheduled to run. When T2 does select_proxy it will get B because A is not in the play state. T2 will not know what the first proxy in its chain has been skipped nor that "strict mode" has been violated. This could also happen in non-multithreaded situations. For instance, if a signal handler is invoked from within hooked connect and the signal handler calls connect.

I see several solutions:

  1. Do nothing and note that this may not work as expected with multiple threads.
  2. Put a big lock around the STRICT_TYPE case in connect_proxy_chain. But that could make for very long connect times with many threads or many proxies in the chain.
  3. Have proxy state be a thread local variable. This will be a non-trivial amount of work though, since we can't declare the state property in the struct to be thread local.
  4. Make a copy of the global chain list on connect and use the copy. This is fairly simple to implement, but it seems like a waste of bytes and cpu.
  5. Remove the state variable from the proxy_data struct and create a state list in connect_proxy_chain. Means lots of code changes.

I think option 2 is worse than option 1 and should be avoided.

OS X: mach-o, but wrong architecture / Allow for multiple architectures

The current Makefile helps build proxychains for the local architecture (x86_64 in my case and, I believe, anybody with a recent Mac) which will render the following error when trying to use proxychains with a piece of software built for i386 (like Spotify desktop app):

    ... snip ...

[proxychains] preloading ./libproxychains4.dylib
dyld: could not load inserted library './libproxychains4.dylib' because no suitable image found.  Did find:
    ./libproxychains4.dylib: mach-o, but wrong architecture

    ... snip ...

# Actual architecture
$ lipo -info /Applications/Spotify.app/Contents/MacOS/Spotify
Non-fat file: /Applications/Spotify.app/Contents/MacOS/Spotify is architecture: i386

For the sake of being able to proxify applications compiled for these both architectures I suggest adding -arch i386 -arch x86_64 to both CFLAGS and LDFLAGS in Makefile (or config.mak). This helps create a "universal" libproxychains4.dylib:

$ lipo -info ./libproxychains4.dylib
Architectures in the fat file: ./libproxychains4.dylib are: i386 x86_64

Now it's fine to proxify both i386 and x86_64 apps at any time.

OpenBSD: proxychains crashes with 'Abort trap (core dumped)' error on launch

Environment;
OpenBSD i386 5.7-release
pf disabled

/etc/proxychains.conf
---------------------------
strict_chain
proxy_dns 
tcp_read_time_out 15000
tcp_connect_time_out 8000
[ProxyList]
socks5 192.168.0.100 9050

Tried getting proxychains4 to run both znc and nc (netcat). Fails on both with error "Abort trap (core dumped) "

$ proxychains4 nc -vz yahoo.com 80                                                                                                                                      
[proxychains] config file found: /etc/proxychains.conf
[proxychains] preloading /usr/local/lib/libproxychains4.so
Abort trap (core dumped) 
$ gdb -c nc.core                                                                                                                                                        
This GDB was configured as "i386-unknown-openbsd5.7".
Core was generated by `nc'.
Program terminated with signal 6, Aborted.
#0  0x0fbf2471 in ?? ()

Kernel trace using OpenBSD ktrace util:
https://cryptobin.org/02y0f065 (password is 'proxychains')

Exclude connection by hostname

Since Proxychains proxies DNS requestes, it'll be nice if you could specify by configuration an hostname as localnet.

# Exclude connection to host google.com on port 80
localnet google.com:80

dns resolution doesnt work for irssi

because it forks, does the dns lookup in the child, and then uses the ip in the parent.
of course the parent cant see what the child wrote into its own local memory, so the ip <-> dns mapping gets lost.

see README for details

Critical regeression: Proxychains no longer uses local DNS, even when told so

Sometimes i need my proxychains to use local dns instead the remote one (i put an entry into my /etc/hosts so i don't have to write remote server IP every time). That works with proxychains 4.2.0, but not later versions.

Tried the same command with both versions 4.2.0 and 4.7. The version 4.8.1 has the same bug.
Reproductible: ALWAYS

My proxychains.conf:
random_chain
chain_len = 1

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

[ProxyList]
socks5 10.XX.XX.XX 45671
socks5 10.XX.XX.XX 45672
socks5 10.XX.XX.XX 45673
socks5 10.XX.XX.XX 45674
socks5 10.XX.XX.XX 45675
socks5 10.XX.XX.XX 45676
socks5 10.XX.XX.XX 45677
socks5 10.XX.XX.XX 45678

Version 4.2.0 Output:
$ proxychains -f /path/to/proxychains-test.conf ssh [email protected]

[proxychains] preloading /usr/lib/libproxychains.so.4.2.0
[proxychains] DLL init
[proxychains] Random chain ... 10.XX.XX.XX ... REMOTE.SERVER.IP.ADDRESS:22 ... OK

$ proxychains -f /path/to/proxychains-test.conf ssh [email protected]

[proxychains] preloading /usr/lib/libproxychains.so.4.2.0
[proxychains] DLL init
[proxychains] Random chain ... 10.XX.XX.XX ... REMOTE.SERVER.IP.ADDRESS:22 ... OK

Version 4.7.0 Output:

$ proxychains -f /path/to/proxychains-test.conf ssh [email protected]

[proxychains] preloading /usr/lib64/libproxychains.so.4.7
[proxychains] DLL init
[proxychains] Random chain ... 10.XX.XX.XX ... REMOTE.SERVER.IP.ADDRESS:22 ... OK

$ proxychains -f /path/to/proxychains-test.conf ssh [email protected]

[proxychains] config file found: /freak/crypt/safe0/etc.conf/proxychains-test.conf
[proxychains] preloading /usr/lib64/libproxychains.so.4.7
[proxychains] DLL init
ssh-noproxy: Could not resolve hostname LOCAL.ETC.HOSTS.NAME: No address associated with hostname

As you can see, when i specify remote host's IP, it works. It does not work when i tell it to resolve a local host.
I suspect it always uses remote host DNS instead local one's, even when it's turned off in the config file.

SYSTEM: Gentoo Linux 64Bit
Kernel: 3.10.41

Mac OS X - libproxychains4.dylib coult not be inserted

Hey mate,

A lot of the time under mac os x the following error occurs while running tools (nmap, nping etc):
[proxychains] config file found: proxychains/src/proxychains.conf
[proxychains] preloading /usr/local/lib/libproxychains4.dylib
dyld: could not load inserted library: /usr/local/lib/libproxychains4.dylib

Trace/BPT trap: 5
Any idea what might be causing this?

Cheers.

Running app on Mac OS X

Is it possible to open .app files with proxychains? Now if I type ./proxychains4 open /Applications/Firefox.app it fails with an error dyld: could not load inserted library: ./libproxychains4.dylib
Although ../libproxychains4.dylib is the correct relative path and command ./proxychains4 curl icanhazip.com works fine.
Is there any restriction to run only daemons and shell programms?
Thanks

issues with localnet

I have compiled rofl0 proxychains 4.4 for linux on an ARM processor.

First it would get stuck during the hb_fill() call, so I basically commented out the contents (much like is done for BSD). Subsequently the application runs seemingly correctly, however, even with localhost allowed as a localnet in my configuration file, I cannot access that application (transmission) on the same host.

Transmission has both a web interface and a local interface accessed via RPC. Neither work, both hang until a long timeout occurs. This leads me to believe that proxychains is not sending responses back to localhost.

Can someone provide some debugging tips such that I can try to offer the maintainers more details that might track down the problem? I turned on DEBUG, but I quickly lose the output as the program backgrounds as a daemon and all output disappears.

Thanks.

Error while building on my iPhone

Make fails with A lot of messages:

_lazy_ptr" minus "L18"
{standard input}:788:symbol: "L_true_connect$non_lazy_ptr" can't be undefined in a subtraction expression
{standard input}:787:non-relocatable subtraction expression, "L_connect$non_lazy_ptr" minus "L17"
{standard input}:787:symbol: "L_connect$non_lazy_ptr" can't be undefined in a subtraction expression
{standard input}:784:non-relocatable subtraction expression, "L_proxychains_ct$non_lazy_ptr" minus "L14"
{standard input}:784:symbol: "L_proxychains_ct$non_lazy_ptr" can't be undefined in a subtraction expression
{standard input}:782:non-relocatable subtraction expression, "L_proxychains_pd$non_lazy_ptr" minus "L12"
{standard input}:782:symbol: "L_proxychains_pd$non_lazy_ptr" can't be undefined in a subtraction expression
{standard input}:560:non-relocatable subtraction expression, "L___stderrp$non_lazy_ptr" minus "L4"
{standard input}:560:symbol: "L___stderrp$non_lazy_ptr" can't be undefined in a subtraction expression
{standard input}:unknown:Undefined local symbol L_dlsym$stub
{standard input}:unknown:Undefined local symbol L_dlerror$stub
{standard input}:unknown:Undefined local symbol L_fprintf$stub
{standard input}:unknown:Undefined local symbol L_exit$stub
{standard input}:unknown:Undefined local symbol L_abort$stub
{standard input}:unknown:Undefined local symbol L___stderrp$non_lazy_ptr
{standard input}:unknown:Undefined local symbol L_time$stub
{standard input}:unknown:Undefined local symbol L_srand$stub
{standard input}:unknown:Undefined local symbol L_dumpstring_init$stub
{standard input}:unknown:Undefined local symbol L_core_initialize$stub
{standard input}:unknown:Undefined local symbol L_at_init$stub
{standard input}:unknown:Undefined local symbol L_get_chain_data$stub
{standard input}:unknown:Undefined local symbol L_proxychains_write_log$stub
{standard input}:unknown:Undefined local symbol L_proxychains_pd$non_lazy_ptr
{standard input}:unknown:Undefined local symbol L_proxychains_ct$non_lazy_ptr
{standard input}:unknown:Undefined local symbol L_connect$non_lazy_ptr
{standard input}:unknown:Undefined local symbol L_true_connect$non_lazy_ptr
{standard input}:unknown:Undefined local symbol L_gethostbyname$non_lazy_ptr
{standard input}:unknown:Undefined local symbol L_true_gethostbyname$non_lazy_ptr
{standard input}:unknown:Undefined local symbol L_getaddrinfo$non_lazy_ptr
{standard input}:unknown:Undefined local symbol L_true_getaddrinfo$non_lazy_ptr
{standard input}:unknown:Undefined local symbol L_freeaddrinfo$non_lazy_ptr
{standard input}:unknown:Undefined local symbol L_true_freeaddrinfo$non_lazy_ptr
{standard input}:unknown:Undefined local symbol L_gethostbyaddr$non_lazy_ptr
{standard input}:unknown:Undefined local symbol L_true_gethostbyaddr$non_lazy_ptr
{standard input}:unknown:Undefined local symbol L_getnameinfo$non_lazy_ptr
{standard input}:unknown:Undefined local symbol L_true_getnameinfo$non_lazy_ptr
{standard input}:unknown:Undefined local symbol L_close$non_lazy_ptr
{standard input}:unknown:Undefined local symbol L_true_close$non_lazy_ptr
{standard input}:unknown:Undefined local symbol L_pthread_once$stub
{standard input}:unknown:Undefined local symbol L_getenv$stub
{standard input}:unknown:Undefined local symbol L_get_config_path$stub
{standard input}:unknown:Undefined local symbol L_fopen$stub
{standard input}:unknown:Undefined local symbol L_strspn$stub
{standard input}:unknown:Undefined local symbol L_memset$stub
{standard input}:unknown:Undefined local symbol L_sscanf$stub
{standard input}:unknown:Undefined local symbol L_inet_addr$stub
{standard input}:unknown:Undefined local symbol L_strcmp$stub
{standard input}:unknown:Undefined local symbol L_strstr$stub
{standard input}:unknown:Undefined local symbol L_fwrite$stub
{standard input}:unknown:Undefined local symbol L_inet_pton$stub
{standard input}:unknown:Undefined local symbol L_atoi$stub
{standard input}:unknown:Undefined local symbol L_strchr$stub
{standard input}:unknown:Undefined local symbol L_fgets$stub
{standard input}:unknown:Undefined local symbol L_fclose$stub
{standard input}:unknown:Undefined local symbol L_tcp_read_time_out$non_lazy_ptr
{standard input}:unknown:Undefined local symbol L_tcp_connect_time_out$non_lazy_ptr
{standard input}:unknown:Undefined local symbol L_localnet_addr$non_lazy_ptr
{standard input}:unknown:Undefined local symbol L___error$stub
{standard input}:unknown:Undefined local symbol L_req_pipefd$non_lazy_ptr
{standard input}:unknown:Undefined local symbol L_resp_pipefd$non_lazy_ptr
{standard input}:unknown:Undefined local symbol L_getsockopt$stub
{standard input}:unknown:Undefined local symbol L_fcntl$stub
{standard input}:unknown:Undefined local symbol L_connect_proxy_chain$stub
{standard input}:unknown:Undefined local symbol L_proxy_gethostbyname$stub
{standard input}:unknown:Undefined local symbol L_proxy_getaddrinfo$stub
{standard input}:unknown:Undefined local symbol L_proxy_freeaddrinfo$stub
make: *** [src/libproxychains.o] Error 1

Quiet mode in config doesn't suppress all output

Just got up and running with proxychains. Such a useful tool! I've been doing a lot of manual work to proxy terminal stuff outside of a restrictive connection that I'm commonly behind, and this is definitely a huge timesaver! Thanks so much for reviving & maintaining this project!

I have a question (possible bug?) about the quiet mode setting.

I have my config file in my home directory and have uncommented the quiet mode line. It appears to suppress most output, however I still see:

$ proxychains4 curl 'https://api.ipify.org?format=json'
[proxychains] config file found: ~/.proxychains/proxychains.conf
[proxychains] preloading /usr/local/Cellar/proxychains-ng/4.7/lib/libproxychains4.dylib

I've tried adding a -s flag, but that doesn't seem to be recognized. Is there anyway to suppress this output (or is quiet mode supposed to suppress it in the first place)?

I suspect the problem is that those two lines are outputted before the config is loaded (so maybe it might make sense to queue them for printing until the config is loaded so that they can be suppressed if there is a quiet mode flag in the config).

Proxychains-ng

This is wonderful software.

With so many people now trying to hide they're coming out of a tor exit node many more linux noobs, like myself, are looking to proxychains-ng as their solution.

Does install documentation exist anywhere other than the readme?

localnet in proxychains.conf seems to cause error

When I add to /etc/proxychains.conf:

localnet 127.0.0.0/255.0.0.0

or any localnet setting so I can communicate to my localhost, and I try to run proxchains4 I get an error.

root:~# proxychains4 nmap
[proxychains] config file found: /etc/proxychains.conf
[proxychains] preloading /usr/lib/libproxychains4.so
error: invalid item in proxylist section: localnet 127.0.0.0/255.0.0.0
root:~# proxychains nmap
ProxyChains-3.1 (http://proxychains.sf.net)
Nmap 6.47 ( http://nmap.org )
Usage: nmap [Scan Type(s)] [Options]

The "proxychains4" command causes an error but "proxychains" doesn't.

Removing the localnet from my conf file causes it to work fine:

root:~# proxychains4 nmap
[proxychains] config file found: /etc/proxychains.conf
[proxychains] preloading /usr/lib/libproxychains4.so
[proxychains] DLL init: proxychains-ng 4.8.1
Nmap 6.47 ( http://nmap.org )
Usage: nmap [Scan Type(s)] [Options] 

Not work with Chromium

root@ebers:~/Workspace/ebers/view# proxychains4 chromium-browser --user-data-dir=/tmp/chromium
[proxychains] config file found: /etc/proxychains.conf
[proxychains] preloading /usr/local/lib/libproxychains4.so
[proxychains] DLL init: proxychains-ng 4.8.1
[proxychains] DLL init: proxychains-ng 4.8.1
[proxychains] DLL init: proxychains-ng 4.8.1
[proxychains] DLL init: proxychains-ng 4.8.1
[proxychains] DLL init: proxychains-ng 4.8.1
[proxychains] DLL init: proxychains-ng 4.8.1
[proxychains] DLL init: proxychains-ng 4.8.1
[proxychains] DLL init: proxychains-ng 4.8.1
[proxychains] DLL init: proxychains-ng 4.8.1

Haven't any error, but chromium isn't work.

I tested with Version 39.0.2171.65 Ubuntu 14.04 (64-bit).
I also try build from latest code of chromium and proxychains-ng, but receiving same results.

Help me!

NULL pointer deref - segfault

Hello.

Proxychains 4.5 has a potential NULL pointer deref. For example, if /etc/proxychains.conf is used and passes the access() check but is access-blocked by a MAC infrastructure, proxychains will segfault on fgets(). This happened to me. Patch below addresses.

Cheers and keep up the great work!

--mancha

--- proxychains-4.5/src/libproxychains.c.orig   2013-04-29
+++ proxychains-4.5/src/libproxychains.c        2013-04-29
@@ -168,7 +168,11 @@ static void get_chain_data(proxy_data *
        *ct = DYNAMIC_TYPE;

        env = get_config_path(getenv(PROXYCHAINS_CONF_FILE_ENV_VAR), buff, sizeo
f(buff));
-       file = fopen(env, "r");
+       if( ( file = fopen(env, "r") ) == NULL )
+       {
+               perror("couldnt read configuration file");
+               exit(1);
+       }

        env = getenv(PROXYCHAINS_QUIET_MODE_ENV_VAR);
        if(env && *env == '1')

firefox segmentation fault and possible memory leak

I replaced an older proxychains 3.x with proxychains-ng and use it via an ssh-proxy.

When I start "proxychains4 firefox" then everything is fine for a while, but then
I start to see things like this:
[proxychains] Strict chain ... 127.0.0.1:7829 ... qa.sockets.stackexchange.com:443 ... OK
[proxychains] Strict chain ... 127.0.0.1:7829 ... �:80 <--socket error or timeout!
[proxychains] Strict chain ... 127.0.0.1:7829 ... �:80 <--socket error or timeout!
[proxychains] Strict chain ... 127.0.0.1:7829 ... security.stackexchange.com:80 ... OK
[proxychains] Strict chain ... 127.0.0.1:7829 ... security.stackexchange.com:80 ... OK
[proxychains] Strict chain ... 127.0.0.1:7829 ... �:80 <--socket error or timeout!
[proxychains] Strict chain ... 127.0.0.1:7829 ... �:80 <--socket error or timeout!
[proxychains] Strict chain ... 127.0.0.1:7829 ... �:80 <--socket error or timeout!
[proxychains] Strict chain ... 127.0.0.1:7829 ... �:80 <--socket error or timeout!
[proxychains] Strict chain ... 127.0.0.1:7829 ... �:443 <--socket error or timeout!
[proxychains] Strict chain ... 127.0.0.1:7829 ... ajax.googleapis.com:80 ... OK
[proxychains] Strict chain ... 127.0.0.1:7829 ... �:80 <--socket error or timeout!

I assume the dns resolution is somehow screwed and overwrites the hostname with garbage.

A few minutes later proxychains/firefox crash (sometimes saying "segmentation fault" and sometimes not).
I couldn't find a coredump nowhere.

build fails with error in function 'proxy_getaddrinfo' on OpenBSD 5.6

Environment:
OpenBSD 5.6 release
gmake-4.0p0

Build fails as detailed below:

# ./configure --prefix=/usr/local --sysconfdir=/etc
Done, now run gmake && gmake install
# gmake
cc  -Wall -O0 -g -std=c99 -D_GNU_SOURCE -pipe -DIS_BSD   -DLIB_DIR=\"/usr/local/lib\" -DSYSCONFDIR=\"/etc\" -DDLL_NAME=\"libproxychains4.so\"  -fPIC -c -o src/core.o src/core.c
src/core.c: In function 'proxy_getaddrinfo':
src/core.c:835: warning: passing argument 4 of 'getservbyname_r' from incompatible pointer type
src/core.c:835: error: too many arguments to function 'getservbyname_r'
src/core.c:856: error: 'AI_V4MAPPED' undeclared (first use in this function)
src/core.c:856: error: (Each undeclared identifier is reported only once
src/core.c:856: error: for each function it appears in.)
Makefile:82: recipe for target 'src/core.o' failed
gmake: *** [src/core.o] Error 1

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. 📊📈🎉

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google ❤️ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.