Transparant proxying with Nginx

Using transparant proxying, you can intercept traffic and route this through other processes. The other processes are still aware of the original client address of the request.

This patch implements TPROXY socket binding to Nginx.

Configuration of nginx.conf:

Now you can enable routing the traffic through the nginx ports using iptables:

iptables -t nat -A PREROUTING -p TCP --dport 80 -j REDIRECT --to-port 3128  
iptables -t nat -A PREROUTING -p TCP --dport 443 -j REDIRECT --to-port 3129