aboutsummaryrefslogtreecommitdiffstats
path: root/src/include/ipxe/eapol.h
diff options
context:
space:
mode:
authorMichael Brown <mcb30@ipxe.org>2023-09-15 16:10:07 +0100
committerMichael Brown <mcb30@ipxe.org>2023-09-18 12:07:28 +0100
commit56cc61a168820c7cbbe23418388129ec11699a8c (patch)
tree270bd1ea47e8e3235595e99500927803d5e29a2d /src/include/ipxe/eapol.h
parentcac3a584dc8acea1522669f1ed16e0979fb92252 (diff)
downloadipxe-56cc61a168820c7cbbe23418388129ec11699a8c.tar.gz
[eap] Define a supplicant model for EAP and EAPoL
Extend the EAP model to include a record of whether or not EAP authentication has completed (successfully or otherwise), and to provide a method for transmitting EAP responses. Signed-off-by: Michael Brown <mcb30@ipxe.org>
Diffstat (limited to 'src/include/ipxe/eapol.h')
-rw-r--r--src/include/ipxe/eapol.h13
1 files changed, 10 insertions, 3 deletions
diff --git a/src/include/ipxe/eapol.h b/src/include/ipxe/eapol.h
index 952d6c752..f6009a2ff 100644
--- a/src/include/ipxe/eapol.h
+++ b/src/include/ipxe/eapol.h
@@ -12,6 +12,7 @@ FILE_LICENCE ( GPL2_OR_LATER_OR_UBDL );
#include <stdint.h>
#include <ipxe/netdevice.h>
#include <ipxe/tables.h>
+#include <ipxe/eap.h>
/** EAPoL header */
struct eapol_header {
@@ -32,6 +33,12 @@ struct eapol_header {
/** EAPoL key */
#define EAPOL_TYPE_KEY 5
+/** An EAPoL supplicant */
+struct eapol_supplicant {
+ /** EAP supplicant */
+ struct eap_supplicant eap;
+};
+
/** An EAPoL handler */
struct eapol_handler {
/** Type */
@@ -39,15 +46,15 @@ struct eapol_handler {
/**
* Process received packet
*
+ * @v supplicant EAPoL supplicant
* @v iobuf I/O buffer
- * @v netdev Network device
* @v ll_source Link-layer source address
* @ret rc Return status code
*
* This method takes ownership of the I/O buffer.
*/
- int ( * rx ) ( struct io_buffer *iobuf, struct net_device *netdev,
- const void *ll_source );
+ int ( * rx ) ( struct eapol_supplicant *supplicant,
+ struct io_buffer *iobuf, const void *ll_source );
};
/** EAPoL handler table */