Two Transparent proxy
1. detect If squid is installed
2. no installation, install with yum
3. automatically run squid service at the 3,5 level
4. Modify squid Master profile /etc/squid/squid.conf
5 Add iptables rule to redirect Internal http request to 3128 Port
A. starting the iptables service
#/etc/init.d/iptables Start
B. clearing existing iptables filter table rules
# iptables-f
C. Save iptables settings
#/etc/init.d/iptables Save
D. View Nat table Settings
# iptables-t Nat-l-N
E. adding a rule to the Nat table
# iptables-t Nat-i prerouting-i eth0-s 192.168.1.0/24-p tcp--dport 80-j REDIRECT--to-port 3128
F. saving
G. setting up iptables Boot
# chkconfig Iptables on
6 Modifying the client IP address
Set the default gateway to the intranet IP address of the squid server .
7 in the browser, cancel the proxy settings
8 Testing
Transparent agent of squid agent