# ------------- tproxy -------------
#$RC_SQUID status | grep pid &>/dev/null && {
# echo "Enabling transparent proxy...."
# INT_IP=$(ifconfig | grep $INT_IF -A 1 \
# | awk '/inet/ {print $2}' | sed -e s/addr\://)
# if [ -z "$INT_IP" ]; then
# echo
# echo "$(basename $0): there is no IP found on $INT_IF."
# echo " Please make sure $INT_IF is setup properly."
# echo
# exit 3
# fi
# iptables -t nat -A PREROUTING -d $INT_IP -i $INT_IF \
# -p tcp -m tcp --dport 80 -j ACCEPT
# iptables -t nat -A PREROUTING -i $INT_IF -p tcp -m tcp \
# --dport 80 -j REDIRECT --to-ports 3128
#}
沒有留言:
張貼留言