policy { prefer_kerberos{ if( User-Password ){ update control { Auth-Type:=Kerberos } } else { #update control { # Auth-Type:=MS-CHAP #} mschap } } swt_vpn_policy{ if( Called-Station-Id == "vpn1" && LDAP-Group == "vpn-staff" ){ update control { Pool-Name:="vpn_staff" Auth-Type:=MS-CHAP } } elsif( Called-Station-Id == "vpn2" && LDAP-Group == "vpn-others" ){ update control { Pool-Name:="vpn_others" Auth-Type:=MS-CHAP } } #elsif( Called-Station-Id == "c0-91-34-c3-44-00" && ( LDAP-Group == "swtswitch01-staff" || LDAP-Group == "swtswitch01-others" ) ){ # prefer_kerberos #} } swt_policy{ ################################################################################################################ # # STAFF Logins # ################################################################################################################ if( ( outer.request:Called-Station-Id == "02-6F-83-3A-AD-B8:staff.1.swt.wiai.uni-bamberg.de" || Called-Station-Id == "02-6F-83-3A-AD-B8:staff.1.swt.wiai.uni-bamberg.de" ) && LDAP-Group == "ap_llab-staff" ){ prefer_kerberos } elsif( ( outer.request:Called-Station-Id == "0013100adbcf" || Called-Station-Id == "0013100adbcf" ) && LDAP-Group=="ap_llab-staff" ){ prefer_kerberos } elsif( ( outer.request:Called-Station-Id == "02-6F-83-3A-B5-E8:staff.2.swt.wiai.uni-bamberg.de" || Called-Station-Id == "02-6F-83-3A-B5-E8:staff.2.swt.wiai.uni-bamberg.de" ) && LDAP-Group == "ap_slab-staff" ){ prefer_kerberos } ################################################################################################################ # # OTHERS Logins # ################################################################################################################ elsif( outer.request:Called-Station-Id == "02-6F-83-3A-AD-B9:others.1.swt.wiai.uni-bamberg.de" || Called-Station-Id == "02-6F-83-3A-AD-B9:others.1.swt.wiai.uni-bamberg.de" ){ prefer_kerberos } elsif( outer.request:Called-Station-Id == "02-6F-83-3A-B5-E9:others.2.swt.wiai.uni-bamberg.de" || Called-Station-Id == "02-6F-83-3A-B5-E9:others.2.swt.wiai.uni-bamberg.de" ){ prefer_kerberos } ################################################################################################################ # # Wired 802.1X Logins (OTHERS/STAFF) # ################################################################################################################ elsif( ( outer.request:Called-Station-Id == "c0-91-34-c3-44-00" || Called-Station-Id == "c0-91-34-c3-44-00" ) && ( LDAP-Group == "swtswitch01-staff" || LDAP-Group == "swtswitch01-others" ) ){ prefer_kerberos } ################################################################################################################ # # reject everybody else # ################################################################################################################ else{ reject } } ################################################################################################################ # # VLAN Assignment should be done in the post-auth group (of default or inner-tunnel) # ################################################################################################################ assign_vlan_policy{ if( ( outer.request:Called-Station-Id == "c0-91-34-c3-44-00" || Called-Station-Id == "c0-91-34-c3-44-00" ) ){ if( LDAP-Group == "swtswitch01-staff" ){ update reply { Tunnel-Private-Group-Id:0 := "2048" Tunnel-Medium-Type:0 := IEEE-802 Tunnel-Type:0 := VLAN } } elsif( LDAP-Group == "swtswitch01-others" ){ update reply { Tunnel-Private-Group-Id:0 := "2049" Tunnel-Medium-Type:0 := IEEE-802 Tunnel-Type:0 := VLAN } } } } }