=====IEEE 802.1x===== ====Radius==== **raddb/radiusd.conf** Проверьте раскомментирован ли mschap в секции "MODULES" mschap { authtype = MS-CHAP use_mppe = yes require_encryption = yes require_strong = yes } authorize { preprocess pre_auth mschap eap files } authenticate { # # MSCHAP authentication. Auth-Type MS-CHAP { mschap } # # Allow EAP authentication. eap } Оповещать о неавторизированных пользователях. post-auth { Post-Auth-Type REJECT { post_auth } } Нужно создать функции для преавторизации и поставторизации exec pre_auth { wait = yes program = "/usr/abills/libexec/rauth.pl pre_auth" input_pairs = request output_pairs = config } exec post_auth { wait = yes program = "/usr/abills/libexec/rauth.pl post_auth" input_pairs = request output_pairs = config } Файл **raddb/eap.conf** eap { default_eap_type = md5 timer_expire = 60 ignore_unknown_eap_types = no cisco_accounting_username_bug = no # Supported EAP-types md5 { } leap { } gtc { #challenge = "Password: " auth_type = PAP } tls { private_key_password = whatever private_key_file = /usr/abills/Certs/eap/cert-srv.pem certificate_file = /usr/abills/Certs/eap/cert-srv.pem CA_file = /usr/abills/Certs/eap/root.pem dh_file = /usr/abills/Certs/eap/dh random_file = /usr/abills/Certs/eap/random fragment_size = 1024 include_length = yes } peap { default_eap_type = mschapv2 } mschapv2 { } } (**В данном примере используются сертификаты поставляемые вместе с FreeRadius желательно заменить их на реальные**) \\ В **raddb/clients.conf** внесите Ваш сервер доступа client 192.168.0.16 { secret = radiussecret shortname = testnet } **raddb/users**\\ DEFAULT Auth-Type = Accept Exec-Program-Wait = "/usr/abills/libexec/rauth.pl" **raddb/acct_users** DEFAULT Acct-Status-Type == Start Exec-Program = "/usr/abills/libexec/racct.pl" DEFAULT Acct-Status-Type == Alive Exec-Program = "/usr/abills/libexec/racct.pl" DEFAULT Acct-Status-Type == Stop Exec-Program = "/usr/abills/libexec/racct.pl" =====NAS===== ====Cisco 3550, 2950==== ! aaa new-model aaa authentication dot1x default group radius ! ! dot1x system-auth-control ! Настраиваем параметры доступа к RADIUS серверу: ! radius-server host 10.0.0.1 auth-port 1812 acct-port 1813 radius-server key testkey ! Настройка порта ! interface FastEthernet0/1 switchport mode access no ip address dot1x port-control auto ! Настройка гостевого VLAN для пользователей не прошедших авторизацию но EAP.\\ Пользователя перкидывает в гостевой VLAN поле 3 безуспешних периодов аторизации или если авторизация непрошла на протяжении 15 секунд. Switch(config-if)# dot1x timeout quiet-period 3 Switch(config-if)# dot1x timeout tx-period 15 Switch(config-if)# dot1x guest-vlan 2 Switch(config-if)# dot1x reauthentication Switch(config-if)# dot1x auth-fail vlan 2 ===Abills=== ** / System configuration/ NAS/ ** ^ Type: | Other | ^ RADIUS Parameters (,) | Tunnel-Medium-Type=IEEE-802,\\ Tunnel-Private-Group-Id=20,\\ Tunnel-Type=VLAN | ==== D-link 30xx ==== **DES-3018 Firmware: Build 3.00.034**\\ [[http://www.dlink.ru/ru/faq/62/238.html|Guest VLAN]] Настройка с возможностью занесения пользователя в определённый VLAN * Две VLAN: guest_vlan и full_vlan * Guest VLAN VID=10 * Порты 1-12 добавлены в Guest VLAN * Добавить порт в обе VLAN **D-Link** config vlan default delete 1-18 create vlan v20 tag 20 config vlan v20 add tag 17 config ipif System ipaddress 10.254.254.4/24 vlan v20 create vlan v10 tag 10 config vlan v10 add untagged 1-12 # Включите 802.1x и Guest VLAN # enable 802.1x create 802.1x guest_vlan v10 config 802.1x guest_vlan ports 1-12 state enable # Сделайте коммутатор посредником в процессе 802.1x # config 802.1x capability ports 1-12 authenticator config radius add 1 10.254.254.1 key radsec default create iproute default 10.254.254.1 Просмотреть состояние порта show 802.1x auth_configuration ports 1 ===AbillS=== ^Type: | Other | ^RADIUS Parameters (,) | Tunnel-Medium-Type=IEEE-802,\\ Tunnel-Private-Group-Id=20,\\ Tunnel-Type=VLAN | ===Radius Parameters=== После успешной авторизации RADIUS выдаёт следующие пары:\\ Access-Accept - авторизация прошла успешно. Sending Access-Accept of id 4 to 10.1.90.6 port 8021 EAP-Message = 0x03030004 Message-Authenticator = 0x00000000000000000000000000000000 User-Name = "test" Session-Timeout = 1412650 Tunnel-Type:0 = VLAN Tunnel-Medium-Type:0 = IEEE-802 Tunnel-Private-Group-Id:0 = "20" Акаунтинг Start от D-link rad_recv: Accounting-Request packet from host 10.1.90.6:8022, id=5, length=103 Acct-Session-Id = "000000000001" Acct-Status-Type = Start Acct-Authentic = RADIUS Acct-Delay-Time = 0 NAS-Port = 2 Calling-Station-Id = "00-13-77-34-5F-A8" Service-Type = Framed-User NAS-IP-Address = 10.1.90.6 NAS-Identifier = "D-Link" User-Name = "test" Sending Accounting-Response of id 5 to 10.1.90.6 port 8022 ==== Edge-Core ES3510 ==== Console(config)#radius-server key radsecret Console(config)#radius-server 1 host 192.168.34.2 #Accounting Console(config)#aaa group server radius tps-radius Console(config)#server 1 Console(config)#aaa accounting dot1x tps start-stop group radius Console(config)#aaa accounting update periodic 5 Console(config)#interface ethernet 1/2 Console(config-if)#accounting dot1x tps #show 802.1x Console#show dot1x #enable 802.1x Console(config)#dot1x system-auth-control #Auth add port 1 Console(config)#interface ethernet 1/1 Console(config-if)#dot1x port-control auto Console(config-if)#dot1x re-authentication Console(config-if)#dot1x max-req 5 Console(config-if)#dot1x timeout quiet-period 30 Console(config-if)#dot1x timeout re-authperiod 1800 Console(config-if)#dot1x timeout tx-period 40 Console(config-if)#dot1x intrusion-action guest-vlan Console(config-if)#exit Console(config)#exit Console#show dot1x =====Клиентская настройка===== ====Windows Client==== {{http://abills.asmodeus.com.ua/img/Win_XP_802_1x.gif}} ====Links==== * [[http://www.ieee802.org/1/pages/802.1x.html]] - 802.1X - Port Based Network Access Control * [[http://www.ietf.org/rfc/rfc3579.txt|RFC3579]] - RADIUS (Remote Authentication Dial In User Service) Support For Extensible Authentication Protocol (EAP) * [[http://www.ietf.org/rfc/rfc2284.txt|RFC2284]] - Extensible Authentication Protocol (EAP) * [[http://ru.wikipedia.org/wiki/IEEE_802.1X]] * [[http://www.citforum.ru/nets/articles/authentication/]] * [[http://xgu.ru/wiki/802.1X_RADIUS#.D0.9D.D0.B0.D1.81.D1.82.D1.80.D0.BE.D0.B9.D0.BA.D0.B0_.D0.BA.D0.BE.D0.BC.D0.BC.D1.83.D1.82.D0.B0.D1.82.D0.BE.D1.80.D0.B0_HP_ProCurve_.D0.B4.D0.BB.D1.8F_.D1.80.D0.B0.D0.B1.D0.BE.D1.82.D1.8B_.D0.B0.D1.83.D1.82.D0.B5.D0.BD.D1.82.D0.B8.D1.84.D0.B8.D0.BA.D0.B0.D1.82.D0.BE.D1.80.D0.BE.D0.BC|802.1X и RADIUS]] Hits: ~~STATS:entries~~