Versions in this module Expand all Collapse all v1 v1.0.0 Oct 19, 2020 Changes in this version + const AnonymityKeyBytes + const AutnBytes + const ConfidentialityKeyBytes + const ExpectedAmfBytes + const ExpectedAutsBytes + const ExpectedKeyBytes + const ExpectedOpBytes + const ExpectedOpcBytes + const ExpectedPlmnBytes + const IntegrityKeyBytes + const KasmeBytes + const MaxSqn + const RandChallengeBytes + const XresBytes + func F1(key, sqn, rand, opc, amf []byte) ([]byte, []byte, error) + func F2F5(key, rand, opc []byte) ([]byte, []byte, error) + func F3(key, rand, opc []byte) ([]byte, error) + func F4(key, rand, opc []byte) ([]byte, error) + func F5Star(key, rand, opc []byte) ([]byte, error) + func GenerateAutn(sqn, ak, macA, amf []byte) []byte + func GenerateKasme(ck, ik, plmn, sqn, ak []byte) ([]byte, error) + func GenerateOpc(key, op []byte) ([ExpectedOpcBytes]byte, error) + func Rotate(arr []byte, k int) []byte + func ValidateGenerateEutranVectorInputs(key []byte, opc []byte, sqn uint64, plmn []byte) error + func ValidateGenerateResyncInputs(auts, key, opc, rand []byte) error + func ValidateGenerateSIPAuthVectorInputs(key []byte, opc []byte, sqn uint64) error + func ValidateGenerateSIPAuthVectorWithRandInputs(rand []byte, key []byte, opc []byte, sqn uint64) error + type Cipher struct + func NewCipher(amf []byte) (*Cipher, error) + func NewMockCipher(amf []byte, rand []byte) (*Cipher, error) + func (c *Cipher) SetRng(newRng io.Reader) + func (milenage *Cipher) GenerateEutranVector(key, opc []byte, sqn uint64, plmn []byte) (*EutranVector, error) + func (milenage *Cipher) GenerateEutranVectorWithRand(key, opc, rand []byte, sqn uint64, plmn []byte) (*EutranVector, error) + func (milenage *Cipher) GenerateResync(auts, key, opc, rand []byte) (uint64, [8]byte, error) + func (milenage *Cipher) GenerateSIPAuthVector(key []byte, opc []byte, sqn uint64) (*SIPAuthVector, error) + func (milenage *Cipher) GenerateSIPAuthVectorWithRand(rand []byte, key []byte, opc []byte, sqn uint64) (*SIPAuthVector, error) + func (milenage *Cipher) GenerateUtranVector(key, opc []byte, sqn uint64) (*UtranVector, error) + func (milenage *Cipher) GenerateUtranVectorWithRand(key, opc, rand []byte, sqn uint64) (*UtranVector, error) + type EutranVector struct + Autn [AutnBytes]byte + Kasme [KasmeBytes]byte + Rand [RandChallengeBytes]byte + Xres [XresBytes]byte + type SIPAuthVector struct + AnonymityKey [AnonymityKeyBytes]byte + Autn [AutnBytes]byte + ConfidentialityKey [ConfidentialityKeyBytes]byte + IntegrityKey [IntegrityKeyBytes]byte + Rand [RandChallengeBytes]byte + Xres [XresBytes]byte + type UtranVector struct + Autn [AutnBytes]byte + ConfidentialityKey [ConfidentialityKeyBytes]byte + IntegrityKey [IntegrityKeyBytes]byte + Rand [RandChallengeBytes]byte + Xres [XresBytes]byte