I wanted to see how many combinations of websites and browsers are still vulnerable to a tls stripping attack (like, by implementing HSTS or disabling cleartext HTTP altogether). To do it I wanted to see it firsthand by using the sslstrip tool, but I was unable to get it working (by following the instructions on the project page itself): the ARP spoofing apparently is working fine, since the target pc cannot browse anymore, but sslstrip doesn't receive anything.
I tried to listen with a TCP socket on the port redirected by iptables, but I received nothing, so I excluded also iptables, and now I'm just trying to receive connections directly on the port used by the victim client. I tried by both enabling and disabling ip forwarding (with /proc/sys/net/ipv4/ip_forward
), and using wifi or ethernet as the interface from the attacking host, but nothing changes:
This is the command I'm using from the attacking host (address 192.168.1.33
hostname macbook
, a Linux 3.11 box):
sudo arpspoof -i eth0 -t 192.168.1.31 192.168.1.1
(192.168.1.1
is the gateway) and then
sudo socat TCP4-LISTEN:80 STDOUT
on the victim host (192.168.1.31
):
socat - TCP4:192.168.1.1:80
I can open the connection, but if I try anything, I don't receive anything on the attacking host (pointing socat
to the attacker's ip address obviously works)
traceroute shows that apparently the ARP spoofing is successful:
> traceroute 192.168.1.1
traceroute to 192.168.1.1 (192.168.1.1), 30 hops max, 60 byte packets
1 macbook.local (192.168.1.30) 2.719ms 5.932ms *
2 * * *
3 * * *
4 * * *
5 * * *
[snip]
28 * * *
29 * * *
30 * * *
arp -n
output from the victim host
Address HWtype HWaddress Flags Mask Iface
192.168.1.33 ether 00:1d:4f:fc:af:fc C wlan0
192.168.1.1 ether 00:1d:4f:fc:af:fc C wlan0