Documentation ¶
Overview ¶
Package eap (EAP Authenticator) provides interface to supported & registered EAP Authenticator Providers
Package eap (EAP Authenticator) provides interface to supported & registered EAP Authenticator Providers
Package eap (EAP Authenticator) provides interface to supported & registered EAP Authenticator Providers
Index ¶
- Constants
- func CreateSessionId() string
- func EncodeMsMppeKey(salt, key, authenticatorKey, sharedSecret []byte) []byte
- func NewAttribute(typ AttrType, data []byte) attribute
- func NewAttributeScanner(eapData Packet) (*attributeScanner, error)
- func NewDuplicateDetector(bitLen uint) *duplicateDetector
- func NewRawAttribute(data []byte) attribute
- func XorBytes(a, b []byte) []byte
- type AttrType
- type Attribute
- type Packet
- func (eap Packet) Append(a Attribute) (Packet, error)
- func (p Packet) Code() uint8
- func (p Packet) Failure() Packet
- func (p Packet) Identifier() uint8
- func (p Packet) IsSuccess() bool
- func (p Packet) Len() int
- func (p Packet) Truncate() Packet
- func (p Packet) Type() uint8
- func (p Packet) TypeData() []byte
- func (p Packet) TypeDataUnsafe() []byte
- func (p Packet) Validate() error
Constants ¶
const ( // EAP Message Payload Offsets EapMsgCode int = iota EapMsgIdentifier EapMsgLenHigh EapMsgLenLow EapMsgMethodType EapMsgData EapReserved1 EapReserved2 EapFirstAttribute EapFirstAttributeLen )
const ( // EapSubtype - pseudonym for EapMsgData EapSubtype = EapMsgData EapHeaderLen = EapMsgMethodType // EapMaxLen maximum possible length of EAP Packet EapMaxLen uint = 1<<16 - 1 UndefinedCode = 0 RequestCode = 1 ResponseCode = 2 SuccessCode = 3 FailureCode = 4 )
const ( // EAP Related Consts MethodIdentity = uint8(protos.EapType_Identity) MethodNak = uint8(protos.EapType_Legacy_Nak) CodeResponse = uint8(protos.EapCode_Response) )
const BitsPerUint = 32
Variables ¶
This section is empty.
Functions ¶
func CreateSessionId ¶
func CreateSessionId() string
CreateSessionId creates & returns unique session ID string
func EncodeMsMppeKey ¶
EncodeMsMppeKey implements RFC 2048 encoding for MS-MPPE-Send-Key & MS-MPPE-Recv-Key radius keys, returns padded & encoded key. See: https://www.ietf.org/rfc/rfc2548.txt 2.4.2, 2.4.3
func NewAttribute ¶
NewAttribute creates and returns new attribute of given type (typ) & value the new attribute is padded with zeros to 4 byte boundary
func NewAttributeScanner ¶
func NewDuplicateDetector ¶
func NewDuplicateDetector(bitLen uint) *duplicateDetector
NewDuplicateDetector returns a new detector supporting bitLen possible combinations
func NewRawAttribute ¶
func NewRawAttribute(data []byte) attribute
NewRawAttribute 'casts' given slice to Attribute type without any validations
Types ¶
type Attribute ¶
type Attribute interface { Type() AttrType Value() []byte String() string Len() int AttrLen() uint8 Marshaled() []byte }
attribute EAP Method's attribute implementation attribute provides the following interface:
type Packet ¶
type Packet []byte
Packet represents EAP Packet
func NewPacket ¶
NewPacket creates an EAP Packet with initialized header and appends provided data if additionalCapacity is specified, NewPacket reserves extra additionalCapacity bytes capacity in the returned packet byte slice
func NewPreallocatedPacket ¶
NewPreallocatedPacket creates an EAP Packet from/in passed data slice & initializes its header
func (Packet) Append ¶
Append adds given Attribute to EAP Packet and amends the packet's header to reflect the new EAP packet size
func (Packet) Identifier ¶
Identifier returns EAP Message Identifier
func (Packet) TypeDataUnsafe ¶
TypeDataUnsafe - same as TypeData, but doesn't check the packet length
Directories ¶
Path | Synopsis |
---|---|
Package client (eap.client) provides interface to supported & registered EAP Authenticator Providers
|
Package client (eap.client) provides interface to supported & registered EAP Authenticator Providers |
Package main implements eap_router service
|
Package main implements eap_router service |
sample_eap_client
Package main implements sample eap_router service client
|
Package main implements sample eap_router service client |
aka
package aka implements EAP-AKA provider package aka implements EAP-AKA EAP Method Package handlers provided AKA Response handlers for supported AKA subtypes package servce implements EAP-AKA GRPC service
|
package aka implements EAP-AKA provider package aka implements EAP-AKA EAP Method Package handlers provided AKA Response handlers for supported AKA subtypes package servce implements EAP-AKA GRPC service |
aka/eap_aka
Package main implements Magma EAP AKA Service
|
Package main implements Magma EAP AKA Service |
aka/provider
package aka implements EAP-AKA provider Package aka implements EAP-AKA provider
|
package aka implements EAP-AKA provider Package aka implements EAP-AKA provider |
aka/servicers
package servcers implements EAP-AKA GRPC service package servcers implements EAP-AKA GRPC service package servicers implements EAP-AKA GRPC service
|
package servcers implements EAP-AKA GRPC service package servcers implements EAP-AKA GRPC service package servicers implements EAP-AKA GRPC service |
aka/servicers/handlers
Package handlers provided AKA Response handlers for supported AKA subtypes Package handlers provided AKA Response handlers for supported AKA subtypes Package handlers provided AKA Response handlers for supported AKA subtypes Package handlers provided AKA Response handlers for supported AKA subtypes
|
Package handlers provided AKA Response handlers for supported AKA subtypes Package handlers provided AKA Response handlers for supported AKA subtypes Package handlers provided AKA Response handlers for supported AKA subtypes Package handlers provided AKA Response handlers for supported AKA subtypes |
registry
Package registry defines API to register and fing EAP providers Package registry defines API to register and fing EAP providers
|
Package registry defines API to register and fing EAP providers Package registry defines API to register and fing EAP providers |
Package test provides common definitions and function for eap related tests Package test provides common definitions and function for eap related tests Package test provides common definitions and function for eap related tests
|
Package test provides common definitions and function for eap related tests Package test provides common definitions and function for eap related tests Package test provides common definitions and function for eap related tests |