eap

package
v0.0.0-...-05317bf Latest Latest
Warning

This package is not in the latest version of its module.

Go to latest
Published: Nov 21, 2015 License: MIT, MIT Imports: 4 Imported by: 0

Documentation

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

This section is empty.

Types

type Code

type Code uint8
const (
	CodeRequest  Code = 1
	CodeResponse Code = 2
	CodeSuccess  Code = 3
	CodeFailure  Code = 4
)

func (Code) String

func (c Code) String() string

type IdentityPacket

type IdentityPacket struct {
	PacketHeader
	Identity string
}

func (*IdentityPacket) Encode

func (p *IdentityPacket) Encode() []byte

func (*IdentityPacket) String

func (p *IdentityPacket) String() string

type LegacyNakPacket

type LegacyNakPacket struct {
	PacketHeader
	DesiredAuthType Type
}

func (*LegacyNakPacket) Encode

func (p *LegacyNakPacket) Encode() []byte

func (*LegacyNakPacket) String

func (p *LegacyNakPacket) String() string

type MSCHAPV2Packet

type MSCHAPV2Packet struct {
	PacketHeader
	MSCHAPV2 MSCHAPV2.Packet
}

func (*MSCHAPV2Packet) Encode

func (p *MSCHAPV2Packet) Encode() []byte

func (*MSCHAPV2Packet) String

func (p *MSCHAPV2Packet) String() string

type Packet

type Packet interface {
	Header() *PacketHeader
	String() string
	Encode() []byte
}

func Decode

func Decode(b []byte) (p Packet, err error)

type PacketHeader

type PacketHeader struct {
	Code       Code
	Identifier uint8
	Type       Type //success and failure do not have any type
}

func (*PacketHeader) Header

func (h *PacketHeader) Header() *PacketHeader

func (*PacketHeader) String

func (h *PacketHeader) String() string

type SimplePacket

type SimplePacket struct {
	PacketHeader
}

only put code identifier

func (*SimplePacket) Encode

func (p *SimplePacket) Encode() (b []byte)

func (*SimplePacket) String

func (p *SimplePacket) String() string

type Type

type Type uint8
const (
	TypeIdentity         Type = 1
	TypeNotification     Type = 2
	TypeLegacyNak        Type = 3 //Response only
	TypeMd5Challenge     Type = 4
	TypeOneTimePassword  Type = 5 //otp
	TypeGenericTokenCard Type = 6 //gtc
	TypeMSCHAPV2         Type = 26
	TypeExpandedTypes    Type = 254
	TypeExperimentalUse  Type = 255
)

func (Type) String

func (c Type) String() string

Jump to

Keyboard shortcuts

? : This menu
/ : Search site
f or F : Jump to
y or Y : Canonical URL