ProxyChains

Create a local SOCKS5 proxy

sudo nano /etc/proxychains4.conf

Add this line, can be other port number. Use 8082 not to interfere with Burp Suite.

#socks4  127.0.0.1 8082
socks5  127.0.0.1 8082

Use Firefox with proxychains

  • Install FoxyProxy Firefox extension.
  • Add a new proxy:
Title: proxychains
Proxy Type: SOCKS5 (or SOCKS4 if configured in /etc/proxychains4.conf)
Proxy IP: 127.0.0.1
Port: 8082

Select “proxychains” in FoxyProxy and go the to target URL in Firefox.

Use Burp with proxychains

In the User options tab, under the SOCKS Proxy section, select Use SOCKS proxy.

SOCKS proxy host: 127.0.0.1
SOCKS proxy port: 8082

In Firefox, set proxy to Burp as usual.

Use Kali Tools

SOCKS proxies require a TCP connection to be made. SYN scan or ICMP cannot get through (disable pinging with the -Pn).

Use -q option to remove messages “[proxychains] Strict chain” in command output.

sudo proxychains -q nmap ...
proxychains -q hydra -t 10 -V -f -C $CREDS ftp://$IP
proxychains rdesktop -u user -p pass -r disk:myshare=/home/kali/share $IP

FTP is limited, enter “passive” quick after password. Should be able to list and upload files. If possible, access FTP from the jump server instead.

proxychains -q ftp user@$IP
[password]
passive
dir

To validate

proxychains -q python exploit.py ...

Web Crawling

Web crawling using gobuster is super slow when using proxychains…

gobuster --proxy socks5://127.0.0.1:8082 ...
WL=/usr/share/dirb/wordlists/common.txt
ffuf -u https://$IP/FUZZ -w $WL -x socks5://127.0.0.1:8082

Using Curl – not perfect…

WL=/usr/share/dirb/wordlists/common.txt
URL="http://x.x.x.x"
for FUZZ in $(cat $WL); do for EXT in {"",".php",".txt",".bak",".old",".aspx",".asp"}; do echo "Debug: ${URL}/${FUZZ}${EXT}" >> curl.txt; proxychains -q curl -k --head "${URL}/${FUZZ}${EXT}" >> curl.txt; done; done
grep -b1 " 200 " curl.txt

ffuf

ffuf -x socks5://127.0.0.1:8082 -u $URL/FUZZ -w $WL -e .php,.txt,.bak,.old,.aspx,.asp > ffuf.txt