I have two interfaces: - A physical WLAN interface with 802.1x auth (en0) - A virtual TUN interface with VPN (invisible in Network Settings) (utun1)
I have mobiles (both rooted Android and jailbroken iOS) that I want to intercept their HTTP/S traffic, over Bluetooth.
My first thought was to do Internet Sharing from WiFi to Bluetooth, OS X did not like this, as the WiFi has 802.1x auth.
Then I turned on Bluetooth Tethering without any connection on the Android, connected to it from the Mac (en3) and added the Mac as default route with
ip route add default via <mac ip>. Then on the Mac I did:
sysctl -w net.inet.ip.forwarding=1
echo "nat on utun1 from en3:network to any -> (utun1)" >> /etc/pf.conf
pfctl -F all
pfctl -ef /etc/pf.conf
I got no errors but the mobile device is not able to connect to the internet. It pings the mac, the route is fine, but the NAT does not work.
How can I share the VPN connection over Bluetooth PAN to the mobile devices? Should I try a different approach? Am I doing something wrong?