18
4
I have Internet Sharing set up on my Mac OS 10.9.5 machine, sharing my Ethernet connection to any devices connected to the created Wi-Fi hotspot. I'm looking for a way to force all that traffic through a proxy server so I can monitor the traffic using Charles.
I had assumed that, since Charles automatically sets up proxy settings (above) on the outgoing Ethernet connection that all the Wi-Fi traffic would already be proxied, but I was wrong. It seems Internet Sharing creates a new bridge (named "bridge100" at the moment) that does not run through the same network service even though the packets go out the same network interface.
I can see all the traffic generated by my machine in Charles, just not the traffic from other machines. Is there a way to set up the routing so my proxy settings for the Ethernet are also applied to the bridge? If not, is there any way to route the bridge's traffic to the same proxy?
On Linux, a so-called “Transparent Proxy” can be realized with
– Daniel B – 2014-10-12T09:28:40.647iptables
, like this. I’m not familiar with OS X’ firewall, but this is basically what you’ll have to replicate.