removido
(usa Nenhuma)
Enviado em 01/03/2011 - 13:27h
Boa tarde galera,
Instalei um proxy squid no Ubuntu Server 10.04 para substituir um Aberium que tem auqi na impresa. Fiz algumas configurações, mas queria deixar aqui meu squid.conf para que possam analisar e quem sabe me ajudar em algumas coisas. Está faltando duas coisas para que eu coloque esse proxy para rodar e tirar o aberium.
1ª Que ele possa dar acesso a determinados logins(usuários). Não sei se é possível bloquiar ou liberar por usuário.
2ª Bloquiar que pessoas usem meu proxy externamente pelo ip fixo.
Bom, abaixo postarei o squid.conf:
#########################################################
##### Arquivo de configuração Web/Proxy Squid #####
##### Criador: Igor Dias Carvalho #####
##### Data: 28/02/2011 #####
#########################################################
acl all src all
acl QUERY urlpath_regex cgi-bin \?
auth_param basic program /usr/bin/ncsa_auth /etc/squid/passwd
auth_param basic children 1
auth_param basic realm Web Proxy MN/DAT - Digite seu usuário e senha.
auth_param basic credentialsttl 2 hour
auth_param basic casesensitive on
dns_nameservers 200.153.0.196
acl password proxy_auth REQUIRED
acl bloqueados url_regex -i "/etc/squid/bloqueados/block.txt"
acl BLOCKTALK url_regex -i mail.google.com/mail/channel/bind
http_access deny BLOCKTALK
acl HOST_MSN src 192.168.1.40/255.255.255.255
acl Negar_MSN dstdomain "/etc/squid/msn.txt"
acl Negar_MSN2 url_regex "/etc/squid/msn2.txt"
acl msn url_regex -i /gateway/gateway.dll
http_access allow HOST_MSN
http_access deny Negar_MSN
http_access deny Negar_MSN2
http_access deny msn
acl manager proto cache_object
acl localhost src 127.0.0.1/32
acl to_localhost dst 127.0.0.0/8
acl localnet src 10.0.0.0/8 # RFC1918 possible internal network
acl localnet src 172.16.0.0/12 # RFC1918 possible internal network
acl localnet src 192.168.0.0/24 # RFC1918 possible internal network
acl SSL_ports port 443 # https
acl SSL_ports port 563 # snews
acl SSL_ports port 873 # rsync
acl porta_SMTP port 25 # SMTP
acl porta_POP port 110 # POP
acl Safe_ports port 80 # http
acl Safe_ports port 21 # ftp
acl Safe_ports port 443 # https
acl Safe_ports port 70 # gopher
acl Safe_ports port 210 # wais
acl Safe_ports port 1025-65535 # unregistered ports
acl Safe_ports port 10000 # webmin
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 Safe_ports port 631 # cups
acl Safe_ports port 873 # rsync
acl Safe_ports port 901 # SWAT
acl purge method PURGE
no_cache deny QUERY password
acl CONNECT method CONNECT
http_access deny bloqueados
http_access allow password !bloqueados
http_access allow manager localhost
http_access deny manager
http_access allow purge localhost
http_access deny purge
http_access allow Safe_ports
http_access deny CONNECT !SSL_ports
http_access allow localhost
http_access deny all !password !SSL_ports
icp_access allow localnet
icp_access deny all !password !SSL_ports
http_port 3128
hierarchy_stoplist cgi-bin ?
access_log /var/log/squid/access.log squid
refresh_pattern ^ftp: 1440 20% 10080
refresh_pattern ^gopher: 1440 0% 1440
refresh_pattern -i (/cgi-bin/|\?) 0 0% 0
refresh_pattern (Release|Package(.gz)*)$ 0 20% 2880
refresh_pattern . 0 20% 4320
# visible_hostname RPMNEWS01
acl shoutcast rep_header X-HTTP09-First-Line ^ICY\s[0-9]
upgrade_http0.9 deny shoutcast
acl apache rep_header Server ^Apache
broken_vary_encoding allow apache
extension_methods REPORT MERGE MKACTIVITY CHECKOUT
hosts_file /etc/hosts
coredump_dir /var/spool/squid
deny_info http://***.***.***.***/erro.html
cache deny all
minimum_object_size 0 KB
cache_swap_low 90
cache_swap_high 95
dns_testnames 200.153.0.68
memory_pools off
memory_pools_limit 1000 KB
http_access deny all
Fico grato com a ajuda de todos.
Abraços!