magubuntu
(usa Ubuntu)
Enviado em 17/12/2013 - 20:39h
Ok, segue:
#Definindo porta
http_port 3128
#Mostra nome da maquina
visible_hostname Firewall-1
cache_mem 256 MB
cache_swap_low 90
cache_swap_high 95
cache_dir aufs /var/spool/squid3 5000 16 256
maximum_object_size 4096 KB
minimum_object_size 0 KB
maximum_object_size_in_memory 512 KB
access_log /var/log/squid3/access.log squid
cache_log /var/log/squid3/cache.log
cache_store_log /var/log/squid3/store.log
mime_table /usr/share/squid3/mime.conf
refresh_pattern ^ftp: 1440 20% 10080
refresh_pattern ^gopher: 1440 0% 1440
refresh_pattern (cgi-bin|\?) 0 0% 0
refresh_pattern . 0 20% 4320
quick_abort_max 16 KB
quick_abort_pct 95
quick_abort_min 16 KB
request_header_max_size 20 KB
reply_header_max_size 20 KB
request_body_max_size 0 KB
#Faz referencia a todos os enderecos
acl all src
acl manager proto cache_object
acl localhost src 127.0.0.1
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 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 901 # swat
acl Safe_ports port 1025-65535 # portas altas
acl purge method PURGE
acl CONNECT method CONNECT
#LIBERA NET PELO MAC
acl libera_mac arp "/etc/squid3/libera_mac"
http_access allow manager localhost
http_access deny manager
http_access allow purge localhost
http_access deny purge
http_access deny !safe_ports
#Declarando a rede local
acl redelocal src 10.1.4.0/24
http_access allow libera_mac
http_access allow localhost
http_access deny redelocal
########### CONTROLE DE BANDA ###########
# === Libera e restringe a banda para alguns ips
acl ipsliberados src "/etc/squid3/ipsliberados"
acl ipsrestritos src "/etc/squid3/ipsrestritos"
# Significa que teremos dois controles de banda
delay_pools 2
# Primeiro controle de banda
delay_class 1 2
# -1/-1 significa que nao teremos limites para a delay pool 1
delay_parameters 1 -1/-1 -1/-1
delay_access 1 allow ipsliberados
# Segundo controle de banda
delay_class 2 2
# Limita a banda para +- 128 kbytes
delay_parameters 2 128000/128000 128000/128000
delay_access 2 allow ipsrestritos
#Bloqueia o que nao tiver liberado acima
http_access deny all
error_directory /usr/share/squid3/errors/pt-br/