Some debugging demonstrates the bug lies in the parser.c file from the tsocks ubuntu/debian patches. In function find_config(), line 46
pw = getpwuid(getuid());
locks (strace & ps shows process is locked waiting for a futex).
BTW, it is actually easier to isolate and reproduce the problem using the attached me.c program. Just compile me.c and run tsocks ./a.out
Basically, tsocks looks for its config file while it is already using the socks proxy. Therefore, getpwuid() looks for the LDAP server through the socks proxy (exceptions are in the config file!).
Binary package hint: tsocks
I'm behind a firewall and login using Kerberos & LDAP.
My /etc/nsswitch.conf file
passwd: files ldap
group: files ldap
shadow: files ldap
When logged as a ldap/kerberos user (i.e. not a local user) attempting to use tsocks always locks.
~>tsocks wget --no-proxy ftp://ftp. ubuntu. com ubuntu. com/ com|91. 189.88. 46|:21. ..
--2010-11-18 17:07:15-- ftp://ftp.
=> `.listing'
Resolving ftp.ubuntu.com... 91.189.88.46, 91.189.92.169, 91.189.92.170, ...
Connecting to ftp.ubuntu.
Some debugging demonstrates the bug lies in the parser.c file from the tsocks ubuntu/debian patches. In function find_config(), line 46
pw = getpwuid(getuid());
locks (strace & ps shows process is locked waiting for a futex).
BTW, it is actually easier to isolate and reproduce the problem using the attached me.c program. Just compile me.c and run tsocks ./a.out
Basically, tsocks looks for its config file while it is already using the socks proxy. Therefore, getpwuid() looks for the LDAP server through the socks proxy (exceptions are in the config file!).
Stock upstream tsock does not have the problem.
ProblemType: Bug ature: Ubuntu 2.6.35- 23.40-generic 2.6.35.7 dules: nvidia
DistroRelease: Ubuntu 10.10
Package: tsocks 1.8beta5-9.1
ProcVersionSign
Uname: Linux 2.6.35-23-generic x86_64
NonfreeKernelMo
Architecture: amd64
Date: Thu Nov 18 17:26:32 2010
InstallationMedia: Ubuntu 10.10 "Maverick Meerkat" - Release amd64 (20101007)
ProcEnviron:
PATH=(custom, no user)
LANG=en_US.UTF-8
SHELL=/bin/csh
SourcePackage: tsocks