andrehit
Goto Top

Probleme Freeradius PEAP MSCHAPv2 und Active Directory mit XP Client im WLAN

Hallo,

ich habe den Freeradiusserver 1.1.3 auf einem Fedora Core 6 mit YUM installiert.
Ich muss dazu sagen, dass ich noch nicht so viel Erfahrung mit Linux und Freeradius habe.

Der Radiusserver soll folgende Aufgabe haben:
Authentifizierung der W-Lan Clients (Windows Xp & 2000) mit PEAP und Domänendaten

Grundlage für meine Konfiguration bildet das AD-Tutorial von www.freeradius.org
http://wiki.freeradius.org/FreeRADIUS_Active_Directory_Integration_HOWT ...

Für die Athentifizierung mit den Domänendaten wird der Befehl "ntlm_auth" von Winbind verwendet.
Dafür haben ich den Sambaserver installiert und den Rechner in die Domäne gebracht.
Anschließend habe ich getestet ob der Befehl funktioniert.
ntlm_auth --request-nt-key --domain=DOMÄNE --username=MEINUSERNAME
Der Befehl war erfolgreich.

Für PEAP benötigt man eine CA und ein Serverzertifikat.
Die CA und das Zertifikat habe ich nach einer Anleitung auf http://www.schrankmonster.de/PermaLink,guid,9c689944-a7ee-4952-9b1f-300 ... erstellt

Das hat soweit auch ganz gut geklappt.

Anschließend habe ich die radiusd.conf, eap.conf und clients.conf bearbeitet.
An der "radiusd.conf" habe ich nur zwei Sachen geändert:
In der Sektion "Microsoft CHAP authentication"
authtype = MS-CHAPwith_ntdomain_hack = yes
Anschließend habe ich noch Änderungen an der "eap.conf" vorgenommen.
default_eap_type = peap tls { private_key_password = passwort private_key_file = ${raddbdir}/myCA/radius-req.pem certificate_file = ${raddbdir}/myCA/radius-cert.pem CA_file = ${raddbdir}/myCA/cacert.pem dh_file = ${raddbdir}/myCA/dh1024.pem random_file = ${raddbdir}/myCA/random fragment_size = 1024 } peap{ default_eap_type = mschapv2 }
In die "clients.conf" habe ich anschließen meinen Accesspoint eingetragen.

client xxx.xxx.xxx.xxx { secret=passwort shortname=xxx.xxx.xxx.xxx nastype=other}

Danach habe ich den Radius-Server auf dem Accesspoint eingetragen

- Ip-Adresse
- Port 1812 & Accounting-Port 1813
- Key

Zum Schluss muss nur noch der Client konfiguriert werden:
Also Rechtsklick auf Netzwerkverbindung --> Drahtlosnetzwerke --> Eigenschaften

Dort wähle ich bei Authentifizierung als EAP-Typ "Geschütztes EAP (PEAP)" aus und klicke auf Eigenschaften.
Nun wähle ich als Authentifizierungsmethode "Sicheres Kennwort (EAP-MSCHAP v2)" aus und wähle Konfigurieren.
Ich wähle aus, dass er beim Herstellen der Verbindung die Windows-Anmeldedaten verwenden soll (Benutzername, Kennwort & Domäne).
Vorher habe ich noch das Zertifikat der CA installiert und zu der Liste der Vertrauenswürdigen Stammzertifizierungsstellen hinzugefügt.

Nun sollte es funktionieren, tut es aber nicht.
Ich habe auch schon den Hotfix für WinXP SP2 für EAP installiert, leider auch ohne Erfolg.


Mein Radiusserver macht folgende Ausgaben, wenn ich ihn mit dem Befehl "radiusd -A -X"
[root@I0001005 ~]# radiusd -A -XStarting - reading configuration files ...reread_config: reading radiusd.confConfig: including file: /etc/raddb/proxy.confConfig: including file: /etc/raddb/clients.confConfig: including file: /etc/raddb/snmp.confConfig: including file: /etc/raddb/eap.conf main: prefix = "/usr" main: localstatedir = "/var" main: logdir = "/var/log/radius" main: libdir = "/usr/lib" main: radacctdir = "/var/log/radius/radacct" main: hostname_lookups = no main: snmp = no main: max_request_time = 30 main: cleanup_delay = 5 main: max_requests = 1024 main: delete_blocked_requests = 0 main: port = 0 main: allow_core_dumps = no main: log_stripped_names = no main: log_file = "/var/log/radius/radius.log" main: log_auth = no main: log_auth_badpass = no main: log_auth_goodpass = no main: pidfile = "/var/run/radiusd/radiusd.pid" main: user = "radiusd" main: group = "radiusd" main: usercollide = no main: lower_user = "no" main: lower_pass = "no" main: nospace_user = "no" main: nospace_pass = "no" main: checkrad = "/usr/sbin/checkrad" main: proxy_requests = yes proxy: retry_delay = 5 proxy: retry_count = 3 proxy: synchronous = no proxy: default_fallback = yes proxy: dead_time = 120 proxy: post_proxy_authorize = no proxy: wake_all_if_all_dead = no security: max_attributes = 200 security: reject_delay = 1 security: status_server = no main: debug_level = 0read_config_files: reading dictionaryread_config_files: reading naslistUsing deprecated naslist file. Support for this will go away soon.read_config_files: reading clientsread_config_files: reading realmsradiusd: entering modules setupModule: Library search path is /usr/libModule: Loaded exec exec: wait = yes exec: program = "(null)" exec: input_pairs = "request" exec: output_pairs = "(null)" exec: packet_type = "(null)"rlm_exec: Wait=yes but no output defined. Did you mean output=none?Module: Instantiated exec (exec) Module: Loaded expr Module: Instantiated expr (expr) Module: Loaded PAP pap: encryption_scheme = "crypt"Module: Instantiated pap (pap) Module: Loaded CHAP Module: Instantiated chap (chap) Module: Loaded MS-CHAP mschap: use_mppe = yes mschap: require_encryption = no mschap: require_strong = no mschap: with_ntdomain_hack = yes mschap: passwd = "(null)" mschap: ntlm_auth = "/usr/bin/ntlm_auth --request-nt-key --domain=%{mschap:NT-Domain} --username=%{mschap:User-Name} --challenge=%{mschap:Challengeface-surprise0} --nt-response=%{mschap:NT-Responseface-surprise0}"Module: Instantiated mschap (mschap) Module: Loaded System unix: cache = no unix: passwd = "(null)" unix: shadow = "/etc/shadow" unix: group = "(null)" unix: radwtmp = "/var/log/radius/radwtmp" unix: usegroup = no unix: cache_reload = 600Module: Instantiated unix (unix) Module: Loaded eap eap: default_eap_type = "peap" eap: timer_expire = 60 eap: ignore_unknown_eap_types = no eap: cisco_accounting_username_bug = norlm_eap: Loaded and initialized type md5rlm_eap: Loaded and initialized type leap gtc: challenge = "Password: " gtc: auth_type = "PAP"rlm_eap: Loaded and initialized type gtc tls: rsa_key_exchange = no tls: dh_key_exchange = yes tls: rsa_key_length = 512 tls: dh_key_length = 512 tls: verify_depth = 0 tls: CA_path = "(null)" tls: pem_file_type = yes tls: private_key_file = "/etc/raddb/myCA/radius-req.pem" tls: certificate_file = "/etc/raddb/myCA/radius-cert.pem" tls: CA_file = "/etc/raddb/myCA/cacert.pem" tls: private_key_password = "hannit810105" tls: dh_file = "/etc/raddb/myCA/dh1024.pem" tls: random_file = "/etc/raddb/myCA/random" tls: fragment_size = 1024 tls: include_length = yes tls: check_crl = no tls: check_cert_cn = "(null)" tls: cipher_list = "(null)" tls: check_cert_issuer = "(null)"rlm_eap_tls: Loading the certificate file as a chainrlm_eap: Loaded and initialized type tls peap: default_eap_type = "mschapv2" peap: copy_request_to_tunnel = no peap: use_tunneled_reply = no peap: proxy_tunneled_request_as_eap = yesrlm_eap: Loaded and initialized type peap mschapv2: with_ntdomain_hack = norlm_eap: Loaded and initialized type mschapv2Module: Instantiated eap (eap) Module: Loaded preprocess preprocess: huntgroups = "/etc/raddb/huntgroups" preprocess: hints = "/etc/raddb/hints" preprocess: with_ascend_hack = no preprocess: ascend_channels_per_line = 23 preprocess: with_ntdomain_hack = no preprocess: with_specialix_jetstream_hack = no preprocess: with_cisco_vsa_hack = no preprocess: with_alvarion_vsa_hack = noModule: Instantiated preprocess (preprocess) Module: Loaded realm realm: format = "suffix" realm: delimiter = "@" realm: ignore_default = no realm: ignore_null = noModule: Instantiated realm (suffix) Module: Loaded files files: usersfile = "/etc/raddb/users" files: acctusersfile = "/etc/raddb/acct_users" files: preproxy_usersfile = "/etc/raddb/preproxy_users" files: compat = "no"Module: Instantiated files (files) Module: Loaded Acct-Unique-Session-Id acct_unique: key = "User-Name, Acct-Session-Id, NAS-IP-Address, Client-IP-Address, NAS-Port"Module: Instantiated acct_unique (acct_unique) Module: Loaded detail detail: detailfile = "/var/log/radius/radacct/%{Client-IP-Address}/detail-%Y%m%d" detail: detailperm = 384 detail: dirperm = 493 detail: locking = noModule: Instantiated detail (detail) Module: Loaded radutmp radutmp: filename = "/var/log/radius/radutmp" radutmp: username = "%{User-Name}" radutmp: case_sensitive = yes radutmp: check_with_nas = yes radutmp: perm = 384 radutmp: callerid = yesModule: Instantiated radutmp (radutmp) Listening on authentication *:1812Listening on accounting *:1813Ready to process requests.


Bei einem Request sieht die Ausgabe wie folgt aus:
rad_recv: Access-Request packet from host xxx.xxx.xxx.xxx:3736, id=211, length=165 NAS-IP-Address = xxx.xxx.xxx.xxx NAS-Port-Type = Wireless-802.11 NAS-Port = 1 Framed-MTU = 1400 User-Name = "DOMAIN\\Username" Calling-Station-Id = "000e35cfceba" Called-Station-Id = "0011886a9db0" NAS-Identifier = "RoamAbout AP" EAP-Message = 0x0201001f01524547494f4e48414e4e4f5645525c41547a7363686965746572 Message-Authenticator = 0x73307dc6cc96573a63f7fcaa499ca2fd Processing the authorize section of radiusd.confmodcall: entering group authorize for request 0 modcall[authorize]: module "preprocess" returns ok for request 0 modcall[authorize]: module "chap" returns noop for request 0 modcall[authorize]: module "mschap" returns noop for request 0 rlm_realm: No '@' in User-Name = "DOMAIN\username", looking up realm NULL rlm_realm: No such realm "NULL" modcall[authorize]: module "suffix" returns noop for request 0 rlm_eap: EAP packet type response id 1 length 31 rlm_eap: No EAP Start, assuming it's an on-going EAP conversation modcall[authorize]: module "eap" returns updated for request 0 users: Matched entry DEFAULT at line 152 modcall[authorize]: module "files" returns ok for request 0modcall: leaving group authorize (returns updated) for request 0 rad_check_password: Found Auth-Type EAPauth: type "EAP" Processing the authenticate section of radiusd.confmodcall: entering group authenticate for request 0 rlm_eap: EAP Identity rlm_eap: processing type tls rlm_eap_tls: Initiate rlm_eap_tls: Start returned 1 modcall[authenticate]: module "eap" returns handled for request 0modcall: leaving group authenticate (returns handled) for request 0Sending Access-Challenge of id 211 to xxx.xxx.xxx.xxx port 3736 EAP-Message = 0x010200061920 Message-Authenticator = 0x00000000000000000000000000000000 State = 0xfe888cb902ed4c878b80616f439ad092Finished request 0
Hat irgendjemand von euch eine Ahnung warum das nicht funktioniert?

Vielen Dank im Vorraus

Andre

Content-Key: 52931

Url: https://administrator.de/contentid/52931

Printed on: April 25, 2024 at 20:04 o'clock

Member: DerSchorsch
DerSchorsch Mar 01, 2007 at 11:58:04 (UTC)
Goto Top
Hallo,

Mit Freeradius kann ich dir zwar nicht helfen, aber...

Eigentlich brauchst du den auch gar nicht. Windows liefert selber einen Radius mit, der für solche Zwecke ganz gut funktioniert.
Hier hast du eine Anleitung für deine beschriebene Anforderung:
http://www.microsoft.com/germany/technet/datenbank/articles/900010.mspx


Gruß
Schorsch


P.S.
nein, ich habe nichts gegen Linux
Member: AndreHIT
AndreHIT Mar 01, 2007 at 12:30:05 (UTC)
Goto Top
Hallo Schorsch,

danke für dein Kommentar, ich werde mir die Anleitung mal anssehen.
Nur das Problem hierbei ist, dass es sich bei dem Projekt um mein Abschlussprojekt der Ausbildung handelt und ich im Antrag Freeradius explizit ausgewählt habe.
Wenn ich das mit Freeradius nicht auf die Reihe bekomme, dann werde ich auf Microsoft umschwenken, aber Freeradius wäre mir schon lieber, wegen Lizenzen etc.

Viele Grüße

Andre
Member: DerSchorsch
DerSchorsch Mar 01, 2007 at 16:17:02 (UTC)
Goto Top
Hallo Andre,

das mit dem Abschlussprojekt ist etwas blöd. Wenn du da einfach auf ein anderes Produkt umschwenkst, kann so ein Prüfer schon mal giftig werden. Da musst du schon genau begründen, warum du von deinem Projektantrag abweichst.


Lizenzmässig gibt es aber auch mit der Microsoft-Lösung keine Probleme, der Radius ist beim Server-Betriebssystem schon dabei und benötigt keine weiteren Lizenzen.

Gruß
Schorsch
Member: AndreHIT
AndreHIT Mar 03, 2007 at 13:54:58 (UTC)
Goto Top
Ich habe den Fehler gefunden, es lag an Dateirechten vom Cache vom Samba Server.