Unterschiede

Hier werden die Unterschiede zwischen zwei Versionen angezeigt.

Link zu dieser Vergleichsansicht

Beide Seiten der vorigen Revision Vorhergehende Überarbeitung
Nächste Überarbeitung
Vorhergehende Überarbeitung
centos:squid:auth [14.11.2011 13:29. ] – [Konfigurationstest am Client] djangocentos:squid:auth [20.04.2018 10:35. ] (aktuell) – Externe Bearbeitung 127.0.0.1
Zeile 1: Zeile 1:
 +====== Userauthentifizierung am Squid-Proxy-Servers ======
 +{{:centos:squid-logo.png|Squid Proxy Logo}}
 +
 +In diesem Kapitel werden wir uns eingehender mit der Benutzerathentifizierung bei bei unserem [[http://www.squid-cache.org/|Squid-Proxy-Server]] unter [[http://wiki.centos.org/Manuals/ReleaseNotes/CentOS6.0|CentOS 6.x]] beschäftigen.
 +
 +===== Authentifizierung mit NCSA-AUTH =====
 +In unserem Netzwerk soll sich jeder Benutzer an jedem Rechner anmelden und so eine Verbindung zum Internet aufbauen können. Hierzu  aktivieren wir die **//NCSA-style Username und Passwort Authentifizierung//**. 
 +<WRAP round important>Bei Bedarf kann somit auch später im Fehlerfall nach geprüft werden, ob bestimmte Seiten von einem Nutzer wiederholt angesprochen wurden. <WRAP round alert>Hierzu ist auf jeden Fall anzuraten, vorab mit den Nutzern eine Vereinbarung zu treffen, wie mit die Handhabung mit diesen Logfiles erfolgen soll, wer wann darauf Zugriff bekommen soll und wann diese wieder gelöscht werden müssen.</WRAP>
 +</WRAP>
 +==== Überprüfung des Authentification-Helper ====
 +Zu erst überprüfen wir, ob der entsprechende Authentification-Helper vorhanden und installiert ist.
 +   # rpm -ql squid | grep ncsa_auth
 +
 +   /usr/lib64/squid/ncsa_auth
 +   /usr/share/man/man8/ncsa_auth.8.gz
 +
 +==== Generierung des Passwortfiles ====
 +Die Generierung des bnötigten Passwort-Files werden wir mit Hilfe des Programmes **htpasswd** aus dem RPM-Paket **httpd-tools** vornehmen.
 +
 +Für den Fall, dass das betrffende RPM-Paket im System noch nicht installiert wurde, werden wir dies eben dieses mit Hilfe von **yum** nachholen.
 +   # yum install httpd-tools -y
 +
 +Anschließend legen wir uns ein entsprechendes Passwortfile (mit dem User bigchief) an:
 +   # htpasswd -c /etc/squid/passwd bigchief
 +
 +   New password: 
 +   Re-type new password: 
 +   Adding password for user bigchief
 +
 +Die Option **-c** verwenden wir, da das File noch nicht existiert und wir eine entsprechende Datei anlegen wollen. Alle weiteren User werden dann mit Hilfe des folgenden Befehls an die Datei angefügt.
 +   # htpasswd /etc/squid/passwd django
 +
 +   New password: 
 +   Re-type new password: 
 +   Adding password for user django
 +
 +In der Datei //**/etc/squid/passwd**// befinden sich nun zwei Einträge für die beiden Nutzer mit ihren zugehörigen verschlüsselten Passwörtern.
 +   # cat /etc/squid/passwd
 +
 +   bigchief:dLuUSr1crTPjtq1pQA
 +   django:9VqG33k1rE72HUPCLc
 +
 +==== Konfiguration /etc/squid/squid.conf ====
 +Unsere zentrale Konfigurationsdatei ergänzen wir dann entsprechend für unsere NCSA-Benutzerauthentifizierung.
 +   # vim /etc/squid/squid.conf
 +<file bash /etc/squid/squid.conf>
 +# Django : 2011-11-14 NCSA-Benutzerauthentifizierung
 +auth_param basic program /usr/lib64/squid/ncsa_auth /etc/squid/ncsa_passwd
 +auth_param basic children 4
 +auth_param basic utf8 on
 +auth_param basic realm Bitte geben Sie Ihren Benutzernamen und Passwort fuer die Internetberechtigung ein!
 +auth_param basic credentialsttl 60 minutes
 +auth_param basic casesensitive off
 +
 +#
 +# Recommended minimum configuration:
 +#
 +acl manager proto cache_object
 +acl localhost src 127.0.0.1/32
 +# Django : 2011-11-14 IPv6 deaktiviert
 +# acl localhost src ::1/128
 +acl to_localhost dst 127.0.0.0/8 0.0.0.0/32
 +# Django : 2011-11-14 IPv6 deaktiviert
 +# acl to_localhost dst ::1/128
 +
 +# Example rule allowing access from your local networks.
 +# Adapt to list your (internal) IP networks from where browsing
 +# should be allowed
 +# Django : 2011-11-14 Definition des/der eigenen Netzwerke
 +# acl localnet src 10.0.0.0/  # RFC1918 possible internal network
 +# acl localnet src 172.16.0.0/12        # RFC1918 possible internal network
 +# acl localnet src 192.168.0.0/16       # RFC1918 possible internal network
 +# acl localnet src fc00::/  # RFC 4193 local private network range
 +# acl localnet src fe80::/10  # RFC 4291 link-local (directly plugged) machines
 +acl localnet src 10.0.0.0/24
 +acl localnet src 10.0.10.0/26
 +
 +# Django : 2011-11-14 NCSA-Benutzerauthentifizierung
 +acl ncsa_users proxy_auth REQUIRED
 +
 +acl SSL_ports port 443
 +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 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
 +
 +#
 +# Recommended minimum Access Permission configuration:
 +#
 +# Only allow cachemgr access from localhost
 +http_access allow manager localhost
 +http_access deny manager
 +
 +# Deny requests to certain unsafe ports
 +http_access deny !Safe_ports
 +
 +# Deny CONNECT to other than secure SSL ports
 +http_access deny CONNECT !SSL_ports
 +
 +# We strongly recommend the following be uncommented to protect innocent
 +# web applications running on the proxy server who think the only
 +# one who can access services on "localhost" is a local user
 +#http_access deny to_localhost
 +
 +#
 +# INSERT YOUR OWN RULE(S) HERE TO ALLOW ACCESS FROM YOUR CLIENTS
 +#
 +
 +# Example rule allowing access from your local networks.
 +# Adapt localnet in the ACL section to list your (internal) IP networks
 +# from where browsing should be allowed
 +# Django : 2011-11-14 Zugriffsregeln für die NCSA-Benutzerauthentifizierung
 +# default: 
 +# http_access allow localnet
 +# http_access allow localhost
 +http_access allow localhost ncsa_users
 +http_access allow localnet ncsa_users
 +
 +# And finally deny all other access to this proxy
 +http_access deny all
 +
 +# Squid normally listens to port 3128
 +http_port 3128
 +
 +# We recommend you to use at least the following line.
 +hierarchy_stoplist cgi-bin ?
 +
 +# Uncomment and adjust the following to add a disk cache directory.
 +#cache_dir ufs /var/spool/squid 100 16 256
 +# Django 2011-11-14 : Squid Cache aktiviert
 +cache_dir ufs /var/spool/squid 64 16 128
 +
 +# Leave coredumps in the first cache dir
 +coredump_dir /var/spool/squid
 +
 +# Add any of your own refresh_pattern entries above these.
 +refresh_pattern ^ftp:           1440    20%     10080
 +refresh_pattern ^gopher:        1440    0%      1440
 +refresh_pattern -i (/cgi-bin/|\?) 0     0%      0
 +refresh_pattern .                     20%     4320
 +
 +# Django : 2011-11-14 Definition des Squid-Logformates
 +logformat squid  %tl.%03tu %6tr %>a %un %Ss/%03>Hs %<st %rm %ru %Sh/%<A %mt
 +</file>
 +Anschließend starten wir unseren Proxy-Server einmal durch.
 +   # service squid restart
 +
 +   Stopping squid: 2011/11/14 14:16:29
 +   ................                                            OK  ]
 +   Starting squid: .                                          [  OK  ]
 +
 +==== Konfigurationstest am Client ====
 +Rufen wir nun an einem der Clients eine Seite im Internet auf, werden wir nach dem Benutzernamen und dem zugehörigen Passwort gefragt.
 +
 +{{ :centos:squid:squid_ncsa_auth.png?300 |Bildschirmhardcopy: Benutzerabfrage beim Zugriff auf eine webseite im Internet}}
 +
 +Im Accesslog unseres Squid-Proxyservers wird dieser Zugriff nun entsprechend protokolliert.
 +   # less /var/log/squid/access.log
 +<code> 14/Nov/2011:14:24:36 +0100.807      1 10.0.0.20 - TCP_DENIED/407 4109 GET http://forum.piratenpartei.de/ NONE/- text/html
 + 14/Nov/2011:14:24:45 +0100.971    871 10.0.0.20 bigchief TCP_MISS/200 10384 GET http://forum.piratenpartei.de/ DIRECT/178.19.71.20 text/html
 + 14/Nov/2011:14:24:46 +0100.097    629 10.0.0.20 bigchief TCP_MISS/200 626 GET http://forum.piratenpartei.de/styles/prosilver/theme/normal.css DIRECT/178.19.71.20 text/css
 + 14/Nov/2011:14:24:46 +0100.128    660 10.0.0.20 bigchief TCP_MISS/200 909 GET http://forum.piratenpartei.de/styles/prosilver/theme/images/icon_home.gif DIRECT/178.19.71.20 image/gif
 + 14/Nov/2011:14:24:46 +0100.144    674 10.0.0.20 bigchief TCP_MISS/200 1312 GET http://forum.piratenpartei.de/styles/prosilver/theme/images/icon_text-html.png DIRECT/178.19.71.20 image/png
 + 14/Nov/2011:14:24:46 +0100.367    921 10.0.0.20 bigchief TCP_MISS/200 3658 GET http://forum.piratenpartei.de/styles/prosilver/template/styleswitcher.js DIRECT/178.19.71.20 application/javascript
 + 14/Nov/2011:14:24:46 +0100.384    921 10.0.0.20 bigchief TCP_MISS/200 9580 GET http://forum.piratenpartei.de/styles/prosilver/template/forum_fn.js DIRECT/178.19.71.20 application/javascript
 + 14/Nov/2011:14:24:46 +0100.432    967 10.0.0.20 bigchief TCP_MISS/200 3825 GET http://forum.piratenpartei.de/styles/prosilver/theme/print.css DIRECT/178.19.71.20 text/css
 + 14/Nov/2011:14:24:46 +0100.448    980 10.0.0.20 bigchief TCP_MISS/200 5094 GET http://forum.piratenpartei.de/styles/prosilver/imageset/site_logo.png DIRECT/178.19.71.20 image/png
 + 14/Nov/2011:14:24:46 +0100.741    365 10.0.0.20 bigchief TCP_MISS/200 790 GET http://forum.piratenpartei.de/styles/prosilver/imageset/icon_topic_latest.gif DIRECT/178.19.71.20 image/gif
 + 14/Nov/2011:14:24:47 +0100.579   2111 10.0.0.20 bigchief TCP_MISS/200 70560 GET http://forum.piratenpartei.de/style.php? DIRECT/178.19.71.20 text/css
 + 14/Nov/2011:14:24:47 +0100.780    176 10.0.0.20 bigchief TCP_MISS/200 1295 GET http://forum.piratenpartei.de/styles/prosilver/theme/images/bg_header.gif DIRECT/178.19.71.20 image/gif
 +...
 +</code>
 +
 +===== Authentifizierung mit LDAP-AUTH (anonymous bind) =====
 +Im Gegensatz zum vorigen Beispiel machen wir es uns doch wesentlich leichter, wenn wir die Benutzerauthentifizierung gegen unseren zentralen LDAP-Servewr laufen lassen. Die Anwender müssen sich nicht noch eine Zugangskennung extra merken. Und auf Seiten der Administration haben wir es auch noch einfacherer uns sicherer, dsa keine gesonderte Passwortdatei gepflegt werden muss.
 +
 +==== anonymous bind ====
 +Im folgenden Beispiel befassen wir uns kurz mit der Möglichkeit, [[centos:ldap:annonbind|anonyme Anfragen]] an den zentralen LDAP-Server zu stellen.
 +
 +Die Konfigurationsdatei unseres Squid-servers passen wir nun wie folgt an.
 +   # vim /etc/squid/squid.conf
 +<file bash /etc/squid/squid.conf>
 +# Django : 2011-11-14 LDAP-Benutzerauthentifizierung
 +auth_param basic program /usr/lib64/squid/squid_ldap_auth -b "ou=People,dc=nausch,dc=org" -f "uid=%s" -h ldap.dmz.nausch.org
 +auth_param basic children 4
 +auth_param basic utf8 on
 +auth_param basic realm Bitte geben Sie Ihren Benutzernamen und Passwort fuer die Internetberechtigung ein!
 +auth_param basic credentialsttl 60 minutes
 +auth_param basic casesensitive off
 +
 +#
 +# Recommended minimum configuration:
 +#
 +acl manager proto cache_object
 +acl localhost src 127.0.0.1/32
 +# Django : 2011-11-14 IPv6 deaktiviert
 +# acl localhost src ::1/128
 +acl to_localhost dst 127.0.0.0/8 0.0.0.0/32
 +# Django : 2011-11-14 IPv6 deaktiviert
 +# acl to_localhost dst ::1/128
 +
 +# Example rule allowing access from your local networks.
 +# Adapt to list your (internal) IP networks from where browsing
 +# should be allowed
 +# Django : 2011-11-14 Definition des/der eigenen Netzwerke
 +# acl localnet src 10.0.0.0/  # RFC1918 possible internal network
 +# acl localnet src 172.16.0.0/12        # RFC1918 possible internal network
 +# acl localnet src 192.168.0.0/16       # RFC1918 possible internal network
 +# acl localnet src fc00::/  # RFC 4193 local private network range
 +# acl localnet src fe80::/10  # RFC 4291 link-local (directly plugged) machines
 +acl localnet src 10.0.0.0/24
 +acl localnet src 10.0.10.0/26
 +
 +# Django : 2011-11-14 LDAP-Benutzerauthentifizierung
 +acl ldap_auth proxy_auth REQUIRED
 +
 +acl SSL_ports port 443
 +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 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
 +
 +#
 +# Recommended minimum Access Permission configuration:
 +#
 +# Only allow cachemgr access from localhost
 +http_access allow manager localhost
 +http_access deny manager
 +
 +# Deny requests to certain unsafe ports
 +http_access deny !Safe_ports
 +
 +# Deny CONNECT to other than secure SSL ports
 +http_access deny CONNECT !SSL_ports
 +
 +# We strongly recommend the following be uncommented to protect innocent
 +# web applications running on the proxy server who think the only
 +# one who can access services on "localhost" is a local user
 +#http_access deny to_localhost
 +
 +#
 +# INSERT YOUR OWN RULE(S) HERE TO ALLOW ACCESS FROM YOUR CLIENTS
 +#
 +
 +# Example rule allowing access from your local networks.
 +# Adapt localnet in the ACL section to list your (internal) IP networks
 +# from where browsing should be allowed
 +# Django : 2011-11-14 Zugriffsregeln für die LDAP-Benutzerauthentifizierung
 +# default: 
 +# http_access allow localnet
 +# http_access allow localhost
 +http_access allow localhost ldap_auth
 +http_access allow localnet ldap_auth
 +
 +# And finally deny all other access to this proxy
 +http_access deny all
 +
 +# Squid normally listens to port 3128
 +http_port 3128
 +
 +# We recommend you to use at least the following line.
 +hierarchy_stoplist cgi-bin ?
 +
 +# Uncomment and adjust the following to add a disk cache directory.
 +#cache_dir ufs /var/spool/squid 100 16 256
 +# Django 2011-11-14 : Squid Cache aktiviert
 +cache_dir ufs /var/spool/squid 64 16 128
 +
 +# Leave coredumps in the first cache dir
 +coredump_dir /var/spool/squid
 +
 +# Add any of your own refresh_pattern entries above these.
 +refresh_pattern ^ftp:           1440    20%     10080
 +refresh_pattern ^gopher:        1440    0%      1440
 +refresh_pattern -i (/cgi-bin/|\?) 0     0%      0
 +refresh_pattern .                     20%     4320
 +
 +# Django : 2011-11-14 Definition des Squid-Logformates
 +logformat squid  %tl.%03tu %6tr %>a %un %Ss/%03>Hs %<st %rm %ru %Sh/%<A %mt
 +</file>
 +   # service squid restart
 +
 +   Stopping squid: 2011/11/14 14:50:31
 +   ................                                            OK  ]
 +   Starting squid: .                                          [  OK  ]
 +
 +==== Bind mit technischem User ====
 +Im folgenden Beispiel befassen wir uns nun mit der Zugriffsmöglichkeit unter Zuhilfenahme eines technischen Benutzers, mit Hilfe dessen die [[centos:ldap:tecbind|Anfragen]] an den zentralen LDAP-Server gestellt werden.
 +
 +Die Konfigurationsdatei unseres Squid-Servers passen wir nun wie folgt an.
 +   # vim /etc/squid/squid.conf
 +<file bash /etc/squid/squid.conf>
 +# Django : 2011-11-14 LDAP-Benutzerauthentifizierung
 +auth_param basic program /usr/lib64/squid/squid_ldap_auth -b "ou=People,dc=nausch,dc=org" -f "uid=%s" -h ldap.dmz.nausch.org -D "cn=Technischeruser,dc=nausch,dc=org" -W "/etc/squid/ldap_passwd"
 +auth_param basic children 4
 +auth_param basic utf8 on
 +auth_param basic realm Bitte geben Sie Ihren Benutzernamen und Passwort fuer die Internetberechtigung ein!
 +auth_param basic credentialsttl 60 minutes
 +auth_param basic casesensitive off
 +
 +#
 +# Recommended minimum configuration:
 +#
 +acl manager proto cache_object
 +acl localhost src 127.0.0.1/32
 +# Django : 2011-11-14 IPv6 deaktiviert
 +# acl localhost src ::1/128
 +acl to_localhost dst 127.0.0.0/8 0.0.0.0/32
 +# Django : 2011-11-14 IPv6 deaktiviert
 +# acl to_localhost dst ::1/128
 +
 +# Example rule allowing access from your local networks.
 +# Adapt to list your (internal) IP networks from where browsing
 +# should be allowed
 +# Django : 2011-11-14 Definition des/der eigenen Netzwerke
 +# acl localnet src 10.0.0.0/  # RFC1918 possible internal network
 +# acl localnet src 172.16.0.0/12        # RFC1918 possible internal network
 +# acl localnet src 192.168.0.0/16       # RFC1918 possible internal network
 +# acl localnet src fc00::/  # RFC 4193 local private network range
 +# acl localnet src fe80::/10  # RFC 4291 link-local (directly plugged) machines
 +acl localnet src 10.0.0.0/24
 +acl localnet src 10.0.10.0/26
 +
 +# Django : 2011-11-14 LDAP-Benutzerauthentifizierung
 +acl ldap_auth proxy_auth REQUIRED
 +
 +acl SSL_ports port 443
 +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 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
 +
 +#
 +# Recommended minimum Access Permission configuration:
 +#
 +# Only allow cachemgr access from localhost
 +http_access allow manager localhost
 +http_access deny manager
 +
 +# Deny requests to certain unsafe ports
 +http_access deny !Safe_ports
 +
 +# Deny CONNECT to other than secure SSL ports
 +http_access deny CONNECT !SSL_ports
 +
 +# We strongly recommend the following be uncommented to protect innocent
 +# web applications running on the proxy server who think the only
 +# one who can access services on "localhost" is a local user
 +#http_access deny to_localhost
 +
 +#
 +# INSERT YOUR OWN RULE(S) HERE TO ALLOW ACCESS FROM YOUR CLIENTS
 +#
 +
 +# Example rule allowing access from your local networks.
 +# Adapt localnet in the ACL section to list your (internal) IP networks
 +# from where browsing should be allowed
 +# Django : 2011-11-14 Zugriffsregeln für die LDAP-Benutzerauthentifizierung
 +# default: 
 +# http_access allow localnet
 +# http_access allow localhost
 +http_access allow localhost ldap_auth
 +http_access allow localnet ldap_auth
 +
 +# And finally deny all other access to this proxy
 +http_access deny all
 +
 +# Squid normally listens to port 3128
 +http_port 3128
 +
 +# We recommend you to use at least the following line.
 +hierarchy_stoplist cgi-bin ?
 +
 +# Uncomment and adjust the following to add a disk cache directory.
 +#cache_dir ufs /var/spool/squid 100 16 256
 +# Django 2011-11-14 : Squid Cache aktiviert
 +cache_dir ufs /var/spool/squid 64 16 128
 +
 +# Leave coredumps in the first cache dir
 +coredump_dir /var/spool/squid
 +
 +# Add any of your own refresh_pattern entries above these.
 +refresh_pattern ^ftp:           1440    20%     10080
 +refresh_pattern ^gopher:        1440    0%      1440
 +refresh_pattern -i (/cgi-bin/|\?) 0     0%      0
 +refresh_pattern .                     20%     4320
 +
 +# Django : 2011-11-14 Definition des Squid-Logformates
 +logformat squid  %tl.%03tu %6tr %>a %un %Ss/%03>Hs %<st %rm %ru %Sh/%<A %mt
 +</file>
 +Das Passwort des technischen Users legen wir dabei in der Datei **ldap_passwd** ab.
 +   # echo "supergeheim" > /etc/squid/ldap_passwd
 +Anschließend passen wir noch die Dateirechte und die Benutzer- und Gruppen-rechte an.
 +   # chmod 640 /etc/squid/ldap_passwd
 +
 +   # chown root:squid /etc/squid/ldap_passwd
 +
 +Zum Aktivieren unserer Konfigurationsänderungen starten wir nun einmal unseren Squid-Proxyserver durch.
 +   # service squid restart
 +
 +==== Konfigurationstest am Server ====
 +Mit Hilfe des Programms **/squid_ldap_auth** können wir uns vergewissern, ob der Authentification-Helper vorhanden und funktionsfähig ist.
 +   # /usr/lib64/squid/squid_ldap_auth -d -b "ou=People,dc=nausch,dc=org" -f "uid=%s" -h ldap.dmz.nausch.org -D "cn=Technischeruser,dc=nausch,dc=org" -W "/etc/squid/ldap_passwd"
 +Anschließende geben wir folgende Werte ein: **User-Name** [Leerzeichen] **Passwort** also z.B. 
 +**django Django-ist-der-volle_Geek!**
 +   django Django-ist-der-volle_Geek!
 +   user filter 'uid=django', searchbase 'ou=People,dc=nausch,dc=org'
 +   attempting to authenticate user 'uid=django,ou=People,dc=nausch,dc=org'
 +
 +Im LDAP-Logfile wird der erfolgreiche Test entsprechend quittiert:
 +   # tail -f /var/log/ldap.log
 +<code bash>
 +Nov 14 18:26:33 vml000030 slapd[27311]: conn=806 fd=16 ACCEPT from IP=10.0.0.40:45075 (IP=0.0.0.0:389)
 +Nov 14 18:26:33 vml000030 slapd[27311]: conn=806 op=0 BIND dn="cn=Technischeruser,dc=nausch,dc=org" method=128
 +Nov 14 18:26:33 vml000030 slapd[27311]: conn=806 op=0 BIND dn="cn=Technischeruser,dc=nausch,dc=org" mech=SIMPLE ssf=0
 +Nov 14 18:26:33 vml000030 slapd[27311]: conn=806 op=0 RESULT tag=97 err=0 text=
 +Nov 14 18:26:33 vml000030 slapd[27311]: conn=806 op=1 SRCH base="ou=People,dc=nausch,dc=org" scope=2 deref=0 filter="(uid=django)"
 +Nov 14 18:26:33 vml000030 slapd[27311]: conn=806 op=1 SRCH attr=1.1
 +Nov 14 18:26:33 vml000030 slapd[27311]: conn=806 op=1 SEARCH RESULT tag=101 err=0 nentries=1 text=
 +Nov 14 18:26:33 vml000030 slapd[27311]: conn=806 op=2 BIND anonymous mech=implicit ssf=0
 +Nov 14 18:26:33 vml000030 slapd[27311]: conn=806 op=2 BIND dn="uid=django,ou=People,dc=nausch,dc=org" method=128
 +Nov 14 18:26:33 vml000030 slapd[27311]: conn=806 op=2 BIND dn="uid=django,ou=People,dc=nausch,dc=org" mech=SIMPLE ssf=0
 +Nov 14 18:26:33 vml000030 slapd[27311]: conn=806 op=2 RESULT tag=97 err=0 text=
 +Nov 14 18:26:33 vml000030 slapd[27311]: conn=806 op=3 UNBIND
 +Nov 14 18:26:33 vml000030 slapd[27311]: conn=806 fd=16 closed
 +</code>
 +==== Konfigurationstest am Client ====
 +Rufen wir nun an einem der Clients eine Seite im Internet auf, werden wir nach dem Benutzernamen und dem zugehörigen Passwort gefragt.
 +
 +{{ :centos:squid:squid_ncsa_auth.png?300 |Bildschirmhardcopy: Benutzerabfrage beim Zugriff auf eine webseite im Internet}}
 +
 +Im Accesslog unseres Squid-Proxyservers wird dieser Zugriff nun entsprechend protokolliert.
 +   # less /var/log/squid/access.log
 +<code> 
 + 14/Nov/2011:18:35:51 +0100.771      1 10.0.0.20 - TCP_DENIED/407 4325 GET http://web.piratenpartei.de/ NONE/- text/html
 + 14/Nov/2011:18:36:10 +0100.891   1470 10.0.0.20 django TCP_REFRESH_MODIFIED/200 7845 GET http://web.piratenpartei.de/ DIRECT/178.19.71.251 text/html
 + 14/Nov/2011:18:36:10 +0100.929     37 10.0.0.20 django TCP_REFRESH_UNMODIFIED/304 490 GET http://web.piratenpartei.de/modules/aggregator/aggregator.css? DIRECT/178.19.71.251 -
 + 14/Nov/2011:18:36:10 +0100.962     64 10.0.0.20 django TCP_REFRESH_UNMODIFIED/304 490 GET http://web.piratenpartei.de/modules/node/node.css? DIRECT/178.19.71.251 -
 + 14/Nov/2011:18:36:10 +0100.978     79 10.0.0.20 django TCP_REFRESH_UNMODIFIED/304 490 GET http://web.piratenpartei.de/modules/system/defaults.css? DIRECT/178.19.71.251 -
 + 14/Nov/2011:18:36:11 +0100.007    108 10.0.0.20 django TCP_REFRESH_UNMODIFIED/304 491 GET http://web.piratenpartei.de/modules/system/system.css? DIRECT/178.19.71.251 -
 + 14/Nov/2011:18:36:11 +0100.022    123 10.0.0.20 django TCP_REFRESH_UNMODIFIED/304 490 GET http://web.piratenpartei.de/modules/system/system-menus.css? DIRECT/178.19.71.251 -
 + 14/Nov/2011:18:36:11 +0100.038    140 10.0.0.20 django TCP_REFRESH_UNMODIFIED/304 490 GET http://web.piratenpartei.de/modules/user/user.css? DIRECT/178.19.71.251 -
 + 14/Nov/2011:18:36:11 +0100.051    152 10.0.0.20 django TCP_REFRESH_UNMODIFIED/304 491 GET http://web.piratenpartei.de/themes/garland/style.css? DIRECT/178.19.71.251 -
 + 14/Nov/2011:18:36:11 +0100.065    156 10.0.0.20 django TCP_REFRESH_UNMODIFIED/304 490 GET http://web.piratenpartei.de/themes/garland/print.css? DIRECT/178.19.71.251 -
 + 14/Nov/2011:18:36:11 +0100.078    147 10.0.0.20 django TCP_MISS/200 13295 GET http://web.piratenpartei.de/sites/default/files/9.png DIRECT/178.19.71.251 image/png
 +</code>
 +====== Links ======
 +  * **[[centos:squid_dansg_6|Zurück zum Kapitel >>Proxyserver Squid mit Web-Contentfilter Dansguardian und Virenfilter ClamAV unter CentOS 6.x<<]]**
 +  * **[[wiki:start|Zurück zu >>Projekte und Themenkapitel<<]]**
 +  * **[[http://dokuwiki.nausch.org/doku.php/|Zurück zur Startseite]]**
 +