separate eap logic into protocol

Signed-off-by: Jens Langhammer <jens@goauthentik.io>
This commit is contained in:
Jens Langhammer
2025-05-21 00:53:18 +02:00
parent 19bb77638a
commit 1575b96262
10 changed files with 185 additions and 89 deletions

View File

@ -9,6 +9,7 @@ import (
type context struct {
req *radius.Request
state interface{}
typeState map[protocol.Type]any
log *log.Entry
settings interface{}
endStatus protocol.Status
@ -23,6 +24,10 @@ func (ctx context) ProtocolSettings() interface{} {
return ctx.settings
}
func (ctx *context) StateForProtocol(p protocol.Type) interface{} {
return ctx.typeState[p]
}
func (ctx *context) GetProtocolState() interface{} {
return ctx.state
}