# Using PEAP on wired LAN

## fatboyjim

All,

My university LAN uses PEAP to authenticate users before it will give an IP address / allow connection to the network

To get this to work in Windows is fairly simple:

Enabled 802.1x authentication for the network

Choose Protected EAP (PEAP) as the EAP type.

Uncheck "Authenticate as a computer when available"

Tick - Validate server certificate

Untick "connect to these servers"

Trusted Root Certification Authorities: Just tick "Equifax Secure Global eBusiness CA-1"

Authentication method: Secured password (EAP-MSCHAP v2)

Disable fast reconnect.

Then when I plug in my network cable I see a bubble asking me to click it, and then enter my Username and Password for the network. I am then assigned an IP address and am connected successfully to the network. Windows remembers my credentials so next time I plug in the network cable I am connected straightaway.

Unfortunately I have no idea whatsoever how to get this to work in Linux as I've always just had a simple DHCP setup.

Any help much appreciated,

Cheers

Jim

----------

## fatboyjim

Bump (original post updated)

----------

## fatboyjim

Config file:

```

logfile = /var/log/xsupplicant.log

network_list = all

default {

eap_peap {

  root_cert = /etc/root.pem

  chunk_size = 1398

  random_file = /dev/urandom

  session_resume = yes

  allow_types = eap_mschapv2

  eap_mschapv2 {

     username = "---------"

     password = "---------"

  }

}

}

```

Any glaring errors there?

After kicking it off (xsupplicant -d A -f -i eth0) I get this output..

```
Using default config path!

[STATE] Reinit state machine

[STATE] [backend_sm] REQUEST -> INITIALIZE

[STATE] [backend_sm] INITIALIZE -> IDLE

[STATE] [backend_sm] UNKNOWN -> INITIALIZE

[STATE] [backend_sm] INITIALIZE -> IDLE

[INT] Initializing socket for interface eth0..

[INT] Allmulti mode is already enabled on this device!

[INT] Interface eth0 is NOT wireless!

[INT] Interface initialized!

[CONFIG] Working from config file /etc/xsupplicant.conf.

No configuration information for network "(null)" found.  Using default.

Couldn't build config for network (null)!

[INT] Opened socket descriptor #5

[INT] Interface eth0 is NOT wireless!

[STATE] Changing from DISCONNECTED to CONNECTING.

[CONFIG] Invalid network configuration data! (txStart:1080)

[CONFIG] Depending on the specific network clause, this may not be anything to worry about!

[ALL] Clock tick! authWhile=29 heldWhile=59 startWhen=29 curState=CONNECTING

[ALL] Clock tick! authWhile=28 heldWhile=58 startWhen=28 curState=CONNECTING

[ALL] Clock tick! authWhile=27 heldWhile=57 startWhen=27 curState=CONNECTING

[ALL] Clock tick! authWhile=26 heldWhile=56 startWhen=26 curState=CONNECTING

[ALL] Clock tick! authWhile=25 heldWhile=55 startWhen=25 curState=CONNECTING

[ALL] Clock tick! authWhile=24 heldWhile=54 startWhen=24 curState=CONNECTING

[ALL] Clock tick! authWhile=23 heldWhile=53 startWhen=23 curState=CONNECTING

[ALL] Clock tick! authWhile=22 heldWhile=52 startWhen=22 curState=CONNECTING

[ALL] Clock tick! authWhile=21 heldWhile=51 startWhen=21 curState=CONNECTING

[ALL] Clock tick! authWhile=20 heldWhile=50 startWhen=20 curState=CONNECTING

[ALL] Clock tick! authWhile=19 heldWhile=49 startWhen=19 curState=CONNECTING

[ALL] Clock tick! authWhile=18 heldWhile=48 startWhen=18 curState=CONNECTING

[ALL] Clock tick! authWhile=17 heldWhile=47 startWhen=17 curState=CONNECTING

[ALL] Clock tick! authWhile=16 heldWhile=46 startWhen=16 curState=CONNECTING

[ALL] Clock tick! authWhile=15 heldWhile=45 startWhen=15 curState=CONNECTING

[ALL] Got Frame : 

01 80 C2 00 00 03 00 0A - 57 C1 59 70 88 8E 01 00 ........W.Yp....

00 04 04 00 00 04 00 00 - 00 00 00 00 00 00 00 00 ................

00 00 00 00 00 00 00 00 - 00 00 00 00 00 00 00 00 ................

        ............

No available network configuration information!

[ALL] Got Frame : 

01 80 C2 00 00 03 00 0A - 57 C1 59 70 88 8E 01 00 ........W.Yp....

00 0F 01 01 00 0F 01 55 - 73 65 72 20 6E 61 6D 65 .......User.name

3A 00 00 00 00 00 00 00 - 00 00 00 00 00 00 00 00 :...............

        ............

No available network configuration information!

[ALL] Clock tick! authWhile=14 heldWhile=44 startWhen=14 curState=CONNECTING

[ALL] Clock tick! authWhile=13 heldWhile=43 startWhen=13 curState=CONNECTING

[ALL] Clock tick! authWhile=12 heldWhile=42 startWhen=12 curState=CONNECTING

[ALL] Clock tick! authWhile=11 heldWhile=41 startWhen=11 curState=CONNECTING

[ALL] Clock tick! authWhile=10 heldWhile=40 startWhen=10 curState=CONNECTING

[ALL] Clock tick! authWhile=9 heldWhile=39 startWhen=9 curState=CONNECTING

[ALL] Clock tick! authWhile=8 heldWhile=38 startWhen=8 curState=CONNECTING

[ALL] Clock tick! authWhile=7 heldWhile=37 startWhen=7 curState=CONNECTING

[ALL] Clock tick! authWhile=6 heldWhile=36 startWhen=6 curState=CONNECTING

[ALL] Clock tick! authWhile=5 heldWhile=35 startWhen=5 curState=CONNECTING

[ALL] Clock tick! authWhile=4 heldWhile=34 startWhen=4 curState=CONNECTING

[ALL] Clock tick! authWhile=3 heldWhile=33 startWhen=3 curState=CONNECTING

[ALL] Clock tick! authWhile=2 heldWhile=32 startWhen=2 curState=CONNECTING

[ALL] Clock tick! authWhile=1 heldWhile=31 startWhen=1 curState=CONNECTING

[ALL] Clock tick! authWhile=0 heldWhile=30 startWhen=0 curState=CONNECTING

[STATE] Changing from CONNECTING to CONNECTING.

[CONFIG] Invalid network configuration data! (txStart:1080)

[CONFIG] Depending on the specific network clause, this may not be anything to worry about!

[ALL] Clock tick! authWhile=0 heldWhile=29 startWhen=29 curState=CONNECTING

[ALL] Clock tick! authWhile=0 heldWhile=28 startWhen=28 curState=CONNECTING

[ALL] Clock tick! authWhile=0 heldWhile=27 startWhen=27 curState=CONNECTING

[ALL] Clock tick! authWhile=0 heldWhile=26 startWhen=26 curState=CONNECTING

[ALL] Clock tick! authWhile=0 heldWhile=25 startWhen=25 curState=CONNECTING

[ALL] Clock tick! authWhile=0 heldWhile=24 startWhen=24 curState=CONNECTING

[ALL] Clock tick! authWhile=0 heldWhile=23 startWhen=23 curState=CONNECTING

[ALL] Clock tick! authWhile=0 heldWhile=22 startWhen=22 curState=CONNECTING

[ALL] Clock tick! authWhile=0 heldWhile=21 startWhen=21 curState=CONNECTING

[ALL] Clock tick! authWhile=0 heldWhile=20 startWhen=20 curState=CONNECTING

[ALL] Clock tick! authWhile=0 heldWhile=19 startWhen=19 curState=CONNECTING

[ALL] Clock tick! authWhile=0 heldWhile=18 startWhen=18 curState=CONNECTING

[ALL] Clock tick! authWhile=0 heldWhile=17 startWhen=17 curState=CONNECTING

[ALL] Clock tick! authWhile=0 heldWhile=16 startWhen=16 curState=CONNECTING

```

Then, guessing this will go on ad infinitum.. I kill it with CTRL+C (but yes, in the past, I have left it for longer)

```

[ALL] Shutting down IPC socket!

[INT] Closing socket descriptor #5

[ALL] Doing statemachine cleanup!

Invalid network data!  (backend_sm_deinit:727)

[INT] Sending Logoff for int eth0!

No network information available.  Not sending a logoff!

[ALL] Cleaning up interface eth0...

[INT] Called event_core_cleanup()!

[INT] Called cardif_linux_rtnetlink_cleanup()!

```

So it seems I am receiving some packets from the server... But getting nowhere

The certificate file I am using I grabbed off the web, named "equifax-secure-ebusiness-ca-1.pem" (it seemed like the right file), but even removing this setting seems to make no difference.

I'm sure it's simple I just need a push in the right direction

Thanks very much

Jim

----------

