diff --git a/scapy/layers/eap.py b/scapy/layers/eap.py
index 5609f61700d3d986d994ea13718e800eea5e2379..87cf50ddd2dff553213d8d03639fc7f2c5ead1eb 100644
--- a/scapy/layers/eap.py
+++ b/scapy/layers/eap.py
@@ -10,12 +10,15 @@ Classes related to the EAP protocol.
 from __future__ import absolute_import
 from __future__ import print_function
 
+import struct
+
 from scapy.fields import BitField, ByteField, XByteField, ByteEnumField,\
 ShortField, IntField, XIntField, ByteEnumField, StrLenField, XStrField,\
 XStrLenField, XStrFixedLenField, LenField, FieldLenField, PacketField,\
 PacketListField, ConditionalField, PadField
 from scapy.packet import Packet, bind_layers
 from scapy.layers.l2 import SourceMACField, Ether, CookedLinux, GRE, SNAP
+from scapy.config import conf
 
 
 #