- 论坛徽章:
- 0
|
在freebsd4.11下用squid2.6-13配置透明代理
ipfw
stone# ipfw show
00050 12625 3051719 divert 8668 ip from any to any via fxp0
00100 90 34028 allow ip from any to any via lo0
00200 0 0 deny ip from any to 127.0.0.0/8
00300 0 0 deny ip from 127.0.0.0/8 to any
65000 18526 5235617 allow ip from any to any
65535 0 0 allow ip from any to any
squid.conf
http_port 3128 transparent
acl all src 0.0.0.0/0.0.0.0
acl manager proto cache_object
#acl localhost src 127.0.0.1/255.255.255.255
acl localhost src 0.0.0.0/0.0.0.0
#acl to_localhost dst 127.0.0.0/8
acl to_localhost dst 0.0.0.0/0.0.0.0
acl SSL_ports port 443 563
acl Safe_ports port 80 # http
acl Safe_ports port 21 # ftp
acl Safe_ports port 443 563 # https, snews
acl Safe_ports port 70 # gopher
acl Safe_ports port 210 # wais
acl Safe_ports port 1025-65535 # unregistered ports
acl Safe_ports port 280 # http-mgmt
acl Safe_ports port 488 # gss-http
acl Safe_ports port 591 # filemaker
acl Safe_ports port 777 # multiling http
acl CONNECT method CONNECT
http_access allow all
http_access allow manager localhost
acl OverConnLimit maxconn 30
squid.conf配置在linux下可以正常使用,配置到bsd后,不启动squid时,nat也能正常访问,dns解析也都正常,启用squid后,ipfw端口不重订向到3128,而是通过ie设置代理可以正常访问,但是如果启用透明代理,并将端口重新定向到3128后,页面提示access denied.
请各位帮帮忙,解决一下。 |
|