Configuracao SQUID [RESOLVIDO]

1. Configuracao SQUID [RESOLVIDO]

Marcos Vinicius
marcosvinicius12

(usa Ubuntu)

Enviado em 13/04/2012 - 11:33h

Galera estou com um problema em meu squid. fiz ele autenticado , porem nao solicita usuario e senha

segue configuracao


http_port 3128
visible_hostname fwfracel
error_directory /usr/share/squid3/errors/Portuguese/

# Cache da internet ##
cache_mem 128 MB
maximum_object_size 5120 KB
minimum_object_size 0 KB
maximum_object_size_in_memory 200 KB
cache_swap_low 90
cache_swap_high 95
cache_dir ufs /var/cache/squid3 5120 16 256
cache_access_log /var/log/squid3/access.log
refresh_pattern ^ftp: 1440 20% 10080
refresh_pattern ^gopher: 1440 0% 1440
refresh_pattern . 0 35% 4320




#Configuracao recomendada:
#libera o proxy para todas as redes
#acl all src 0.0.0.0/0.0.0.0
acl manager proto cache_object
acl localhost src 127.0.0.1/32

########################################################

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
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 Safe_ports port 910 # swat
acl purge method PURGE
acl CONNECT method CONNECT

# Only allow cachemgr access from localhost

http_access allow manager localhost
http_access deny manager
http_access allow purge localhost
http_access deny purge
http_access deny !Safe_ports

# Deny CONNECT to other than SSL ports

http_access deny CONNECT !SSL_ports

#We recommend you to use at least the following line.

hierarchy_stoplist cgi-bin ?


# Executa so bloqueios de sites do squidGuard

#redirect_program /usr/sbin/squidGuard



redirect_children 5
redirector_bypass on
###############################################################################
# ACLS
###############################################################################
acl rede_local src 192.168.254.0/24
#Extencoes de arquivos de download
acl extencoes url_regex -i "/etc/squid3/arquivos/arquivos.lst"
#sites liberados
acl liberados dstdom_regex "/etc/squid3/liberados/sites_liberados.lst"
#Sites bloqueados
acl bloqueados dstdom_regex "/etc/squid3/bloqueados/bloqueados.lst"
#
acl horario time 00:01-23:59

##############################################################################
#Autenticacao de usuario
auth_param basic program /usr/lib/squid3/ncsa_auth etc/squid3/squid_passwd
auth_param basic realm Servidor Proxy - Digite o Usuario e a Senha:
auth_param basic credentialsttl 1 hours
acl autenticados proxy_auth REQUIRED

http_access allow liberados
http_access deny extencoes
http_access deny horario
http_access allow autenticados

#Libera Site para determinado IP
#acl ip_maquina src 192.168.254.10/32
#acl sites_liberados_maquina dstdom_regex -i "/etc/squid3/liberados/sites_liberados_maquina.lst"
#http_access allow ip_maquina sites_liberados_maquina
http_access allow localhost
http_access allow rede_local
http_access deny all


se alguem poder me ajudar desde ja agradeco



  


2. MELHOR RESPOSTA

Phillip Vieira
phrich

(usa Slackware)

Enviado em 19/04/2012 - 17:53h

###############################################################################
# ACLS
###############################################################################
acl rede_local src 192.168.254.0/24
#Autenticacao de usuario
auth_param basic program /usr/lib/squid3/ncsa_auth etc/squid3/squid_passwd
auth_param basic realm Servidor Proxy - Digite o Usuario e a Senha:
auth_param basic credentialsttl 1 hours



### ATENÇÃO: O QUE ESTIVER ABAIXO DESTA LINHA SERÁ SOLICITADO AUTENTICAÇÃO O QUE ESTIVER ACIMA PASSARÁ DIRETO
acl autenticados proxy_auth REQUIRED ###

#Extencoes de arquivos de download
acl extencoes url_regex -i "/etc/squid3/arquivos/arquivos.lst"
#sites liberados
acl liberados dstdom_regex "/etc/squid3/liberados/sites_liberados.lst"
#Sites bloqueados
acl bloqueados dstdom_regex "/etc/squid3/bloqueados/bloqueados.lst"
#
acl horario time 00:01-23:59

##############################################################################

http_access allow liberados
http_access deny extencoes
http_access deny horario
http_access allow autenticados

#Libera Site para determinado IP
#acl ip_maquina src 192.168.254.10/32
#acl sites_liberados_maquina dstdom_regex -i "/etc/squid3/liberados/sites_liberados_maquina.lst"
#http_access allow ip_maquina sites_liberados_maquina
http_access allow localhost
http_access allow rede_local
http_access deny all

3. Re: Configuracao SQUID [RESOLVIDO]

Phillip Vieira
phrich

(usa Slackware)

Enviado em 19/04/2012 - 17:48h

Uma pergunta meio boba, mas...

Vc configurou o proxy nos navegadores?


4. Re: Configuracao SQUID [RESOLVIDO]

Phillip Vieira
phrich

(usa Slackware)

Enviado em 19/04/2012 - 17:51h

Outra, as linhas:

#Autenticacao de usuario
auth_param basic program /usr/lib/squid3/ncsa_auth etc/squid3/squid_passwd
auth_param basic realm Servidor Proxy - Digite o Usuario e a Senha:
auth_param basic credentialsttl 1 hours
acl autenticados proxy_auth REQUIRED


Devem estar acima de qualquer acl de bloqueio ou liberação, caso contrário não irão pedir usuário e senha.


5. Re: Configuracao SQUID [RESOLVIDO]

Marcos Vinicius
marcosvinicius12

(usa Ubuntu)

Enviado em 20/04/2012 - 07:41h

Blz, deu certo aqui, acho que o navegador tava bugado...

mas da mesma forma obrigado.






Patrocínio

Site hospedado pelo provedor RedeHost.
Linux banner

Destaques

Artigos

Dicas

Tópicos

Top 10 do mês

Scripts