Gentoo Forums
Gentoo Forums
Gentoo Forums
Quick Search: in
Squid con autenticazione: non mi accetta le pass?
View unanswered posts
View posts from last 24 hours
View posts from last 7 days

 
Reply to topic    Gentoo Forums Forum Index Forum italiano (Italian)
View previous topic :: View next topic  
Author Message
Theobsidian
n00b
n00b


Joined: 17 Aug 2004
Posts: 1

PostPosted: Tue Aug 17, 2004 2:13 pm    Post subject: Squid con autenticazione: non mi accetta le pass? Reply with quote

Salve a tutti,
sto cercando di installare Squid con autenticazione in base allo username e la password, ho seguito questo how-to:
http://www.siliconvalleyccie.com/linux-adv/squid.htm
nella sezione:
Code:

Password Authentication Using NCSA

Squid can be configured to prompt users for a username and password. Squid comes with a program called "ncsa_auth" that will read any NCSA compliant encrypted password file. The "htpasswd" program that comes installed with Apache can be used to create your passwords. Here is how it's done:

 
Create The Password File

[root@bigboy tmp]# touch /etc/squid/squid_passwd

[root@bigboy tmp]# chmod o+r /etc/squid/squid_passwd

 
Add Users To The Password File

Use the htpasswd program to add users to the password file. In this case we add a username called "www". You can add users at anytime without having to restart Squid.

 

[root@bigboy tmp]# htpasswd /etc/squid/squid_passwd www

New password:

Re-type new password:

Adding password for user www

[root@bigboy tmp]#

 
Locate Your ncsa_auth File

>        First you need to locate were ncsa_auth is located with the locate command.

 

[root@silent RPMS]# locate ncsa_auth

/usr/lib/squid/ncsa_auth

[root@silent RPMS]#

 
Edit squid.conf

>        You need to define the authentication program, which is in this case ncsa_auth.

>        The next step is to create an "http_access" entry that allows traffic that matches a special access control list (ACL) entry we'll call "ncsa_users".

>        The next step create the ACL named "ncsa_users" with the REQUIRED keyword that forces Squid to use the NCSA auth_param method we defined.

 

Simple User Authentication Example

 

#

# Add this to the auth_param section of squid.conf

#

auth_param basic program /usr/lib/squid/ncsa_auth /etc/squid/squid_passwd

 

#

# Add this to the bottom of the ACL section of squid.conf

#

acl ncsa_users proxy_auth REQUIRED

 

#

# Add this at the top of the http_access section of squid.conf

#

http_access allow ncsa_users



Ho seguito alla lettera, ma quando vado a loggarmi, il browser mi chiede continuamente username e password; i log di squid dicono:

1092749924.428 877 151.37.77.164 TCP_DENIED/407 1768 GET http://www.google.it/ antares NONE/- text/html

dove lo username appunto è "antares"
Mi sapete aiutare?
Back to top
View user's profile Send private message
ema
Guru
Guru


Joined: 27 Aug 2003
Posts: 380

PostPosted: Thu Aug 19, 2004 10:06 am    Post subject: Reply with quote

devi ovviamente aggiungere l'utente antares alla lista utenti squid col comando htpasswd, come ad esempio hai aggiunto l'user www (che non e' necessario!!)
dopodiche dovrebbe funzionare
_________________
D Per fare il SysAdmin e' necessario conoscere Unix/Linux e disprezzare Windows?
R Se ti interessa lavorare in ambiente Unix/Linux dovrai averne un minimo di conoscenza, quando acquisisci tale conoscenza la seconda parte arriva da sola.
Back to top
View user's profile Send private message
Display posts from previous:   
Reply to topic    Gentoo Forums Forum Index Forum italiano (Italian) All times are GMT
Page 1 of 1

 
Jump to:  
You cannot post new topics in this forum
You cannot reply to topics in this forum
You cannot edit your posts in this forum
You cannot delete your posts in this forum
You cannot vote in polls in this forum