Documentation
¶
Overview ¶
Copyright 2024 Ella Networks
Index ¶
- Constants
- func AttachSourceUeTargetUe(sourceUe, targetUe *RanUe) error
- func CompareUserLocation(loc1 models.UserLocation, loc2 models.UserLocation) bool
- func DetachSourceUeTargetUe(ranUe *RanUe)
- func GetServedGuamiList(ctx context.Context) []models.Guami
- func GetSupportTaiList(ctx context.Context) []models.Tai
- func InTaiList(servedTai models.Tai, taiList []models.Tai) bool
- func IsSubscriberRegistered(imsi string) bool
- func TacInAreas(targetTac string, areas []models.Area) bool
- type AMFContext
- func (context *AMFContext) AddAmfUeToUePool(ue *AmfUe, supi string)
- func (context *AMFContext) AllocateAmfUeNgapID() (int64, error)
- func (context *AMFContext) AllocateGutiToUe(ctx ctxt.Context, ue *AmfUe)
- func (context *AMFContext) AllocateRegistrationArea(ctx ctxt.Context, ue *AmfUe, anType models.AccessType)
- func (context *AMFContext) AmfRanFindByConn(conn net.Conn) (*AmfRan, bool)
- func (context *AMFContext) AmfRanFindByGnbID(gnbID string) (*AmfRan, bool)
- func (context *AMFContext) AmfRanFindByRanID(ranNodeID models.GlobalRanNodeID) (*AmfRan, bool)
- func (context *AMFContext) AmfUeFindByGuti(guti string) (ue *AmfUe, ok bool)
- func (context *AMFContext) AmfUeFindByGutiLocal(guti string) (ue *AmfUe, ok bool)
- func (context *AMFContext) AmfUeFindByPolicyAssociationID(polAssoID string) (ue *AmfUe, ok bool)
- func (context *AMFContext) AmfUeFindBySuci(suci string) (ue *AmfUe, ok bool)
- func (context *AMFContext) AmfUeFindBySupi(supi string) (ue *AmfUe, ok bool)
- func (context *AMFContext) AmfUeFindBySupiLocal(supi string) (ue *AmfUe, ok bool)
- func (context *AMFContext) AmfUeFindByUeContextID(ueContextID string) (*AmfUe, bool)
- func (context *AMFContext) DeleteAmfRan(conn net.Conn)
- func (context *AMFContext) Get5gsNwFeatSuppEmc() uint8
- func (context *AMFContext) Get5gsNwFeatSuppEmcN3() uint8
- func (context *AMFContext) Get5gsNwFeatSuppEmf() uint8
- func (context *AMFContext) Get5gsNwFeatSuppEnable() bool
- func (context *AMFContext) Get5gsNwFeatSuppImsVoPS() uint8
- func (context *AMFContext) Get5gsNwFeatSuppIwkN26() uint8
- func (context *AMFContext) Get5gsNwFeatSuppMcsi() uint8
- func (context *AMFContext) Get5gsNwFeatSuppMpsi() uint8
- func (context *AMFContext) GetIPv4Uri() string
- func (context *AMFContext) InPlmnSupport(ctx ctxt.Context, snssai models.Snssai) bool
- func (context *AMFContext) ListAmfRan() []AmfRan
- func (context *AMFContext) NewAmfRan(conn net.Conn) *AmfRan
- func (context *AMFContext) NewAmfUe(ctx ctxt.Context, supi string) *AmfUe
- func (context *AMFContext) RanUeFindByAmfUeNgapID(amfUeNgapID int64) *RanUe
- func (context *AMFContext) RanUeFindByAmfUeNgapIDLocal(amfUeNgapID int64) *RanUe
- func (context *AMFContext) ReAllocateGutiToUe(ctx ctxt.Context, ue *AmfUe)
- func (context *AMFContext) TmsiAllocate() int32
- type AmfRan
- func (ran *AmfRan) NewRanUe(ranUeNgapID int64) (*RanUe, error)
- func (ran *AmfRan) RanUeFindByRanUeNgapID(ranUeNgapID int64) *RanUe
- func (ran *AmfRan) RanUeFindByRanUeNgapIDLocal(ranUeNgapID int64) *RanUe
- func (ran *AmfRan) Remove()
- func (ran *AmfRan) RemoveAllUeInRan()
- func (ran *AmfRan) SetRanID(ranNodeID *ngapType.GlobalRANNodeID)
- type AmfUe
- func (ue *AmfUe) AttachRanUe(ranUe *RanUe)
- func (ue *AmfUe) ClearRegistrationData()
- func (ue *AmfUe) ClearRegistrationRequestData(accessType models.AccessType)
- func (ue *AmfUe) CmConnect(anType models.AccessType) bool
- func (ue *AmfUe) CmIdle(anType models.AccessType) bool
- func (ue *AmfUe) CopyDataFromUeContextModel(ueContext models.UeContext)
- func (ue *AmfUe) DerivateAlgKey()
- func (ue *AmfUe) DerivateAnKey(anType models.AccessType)
- func (ue *AmfUe) DerivateKamf()
- func (ue *AmfUe) DerivateNH(syncInput []byte)
- func (ue *AmfUe) DetachRanUe(anType models.AccessType)
- func (ue *AmfUe) GetAnType() models.AccessType
- func (ue *AmfUe) GetNsiInformationFromSnssai(anType models.AccessType, snssai models.Snssai) *models.NsiInformation
- func (ue *AmfUe) GetOnGoing(anType models.AccessType) OnGoingProcedureWithPrio
- func (ue *AmfUe) HasWildCardSubscribedDNN() bool
- func (ue *AmfUe) InAllowedNssai(targetSNssai models.Snssai, anType models.AccessType) bool
- func (ue *AmfUe) InSubscribedNssai(targetSNssai *models.Snssai) bool
- func (ue *AmfUe) Remove()
- func (ue *AmfUe) RemoveAmPolicyAssociation()
- func (ue *AmfUe) SecurityContextIsValid() bool
- func (ue *AmfUe) SelectSecurityAlg(intOrder, encOrder []uint8)
- func (ue *AmfUe) SetOnGoing(anType models.AccessType, onGoing *OnGoingProcedureWithPrio)
- func (ue *AmfUe) SmContextFindByPDUSessionID(pduSessionID int32) (*SmContext, bool)
- func (ue *AmfUe) StoreSmContext(pduSessionID int32, smContext *SmContext)
- func (ue *AmfUe) TaiListInRegistrationArea(taiList []models.Tai, accessType models.AccessType) bool
- func (ue *AmfUe) UpdateNH()
- func (ue *AmfUe) UpdateSecurityContext(anType models.AccessType)
- type CauseAll
- type InfoOnRecommendedCellsAndRanNodesForPaging
- type InterfaceMsg
- type InterfaceType
- type LADN
- type N1N2Message
- type NGRANCGI
- type NasMsg
- type NetworkFeatureSupport5GS
- type NetworkName
- type NgapMsg
- type OnGoingProcedure
- type OnGoingProcedureWithPrio
- type PlmnSupportItem
- type RanUe
- type RecommendRanNode
- type RecommendedCell
- type RelAction
- type Security
- type SecurityAlgorithm
- type SmContext
- func (c *SmContext) AccessType() models.AccessType
- func (c *SmContext) DeleteULNASTransport()
- func (c *SmContext) Dnn() string
- func (c *SmContext) HSmfID() string
- func (c *SmContext) IsPduSessionActive() bool
- func (c *SmContext) NsInstance() string
- func (c *SmContext) PduSessionID() int32
- func (c *SmContext) PduSessionIDDuplicated() bool
- func (c *SmContext) SetAccessType(accessType models.AccessType)
- func (c *SmContext) SetDnn(dnn string)
- func (c *SmContext) SetDuplicatedPduSessionID(duplicated bool)
- func (c *SmContext) SetHSmfID(hsmfID string)
- func (c *SmContext) SetNsInstance(nsInstanceID string)
- func (c *SmContext) SetPduSessionID(id int32)
- func (c *SmContext) SetPduSessionInActive(s bool)
- func (c *SmContext) SetPlmnID(plmnID models.PlmnID)
- func (c *SmContext) SetSmContextRef(ref string)
- func (c *SmContext) SetSnssai(snssai models.Snssai)
- func (c *SmContext) SetUserLocation(userLocation models.UserLocation)
- func (c *SmContext) SetVSmfID(vsmfID string)
- func (c *SmContext) SmContextRef() string
- func (c *SmContext) Snssai() models.Snssai
- func (c *SmContext) StoreULNASTransport(msg *nasMessage.ULNASTransport)
- func (c *SmContext) ULNASTransport() *nasMessage.ULNASTransport
- func (c *SmContext) UserLocation() models.UserLocation
- func (c *SmContext) VSmfID() string
- type SupportedTAI
- type Timer
- type TimerValue
- type UERadioCapabilityForPaging
Constants ¶
const ( MaxNumOfTAI int = 16 MaxNumOfBroadcastPLMNs int = 12 MaxNumOfSlice int = 1024 MaxValueOfAmfUeNgapID int64 = 1099511627775 MaxNumOfServedGuamiList int = 256 MaxNumOfPDUSessions int = 256 MaxNumOfAOI int = 64 )
const ( RanPresentGNbID = 1 RanPresentNgeNbID = 2 RanPresentN3IwfID = 3 )
const ( NgRanCgiPresentNRCGI int32 = 0 NgRanCgiPresentEUTRACGI int32 = 1 )
const ( RecommendRanNodePresentRanNode int32 = 0 RecommendRanNodePresentTAI int32 = 1 )
const ( Deregistered fsm.StateType = "Deregistered" DeregistrationInitiated fsm.StateType = "DeregistrationInitiated" Authentication fsm.StateType = "Authentication" SecurityMode fsm.StateType = "SecurityMode" ContextSetup fsm.StateType = "ContextSetup" Registered fsm.StateType = "Registered" )
GMM state for UE
const (
RanUeNgapIDUnspecified int64 = 0xffffffff
)
const (
TimeT3513 time.Duration = 6 * time.Second
)
timers defined in TS 24.501 table 10.2.2
Variables ¶
This section is empty.
Functions ¶
func AttachSourceUeTargetUe ¶
func CompareUserLocation ¶
func CompareUserLocation(loc1 models.UserLocation, loc2 models.UserLocation) bool
func DetachSourceUeTargetUe ¶
func DetachSourceUeTargetUe(ranUe *RanUe)
func IsSubscriberRegistered ¶ added in v0.1.0
Types ¶
type AMFContext ¶
type AMFContext struct { DBInstance *db.Database UePool sync.Map // map[supi]*AmfUe RanUePool sync.Map // map[AmfUeNgapID]*RanUe AmfRanPool sync.Map // map[net.Conn]*AmfRan LadnPool map[string]*LADN // dnn as key RelativeCapacity int64 NfID string Name string URIScheme models.URIScheme NgapPort int NetworkFeatureSupport5GS *NetworkFeatureSupport5GS SecurityAlgorithm SecurityAlgorithm NetworkName NetworkName T3502Value int // unit is second T3512Value int // unit is second Non3gppDeregistrationTimerValue int // unit is second T3513Cfg TimerValue T3522Cfg TimerValue T3550Cfg TimerValue T3560Cfg TimerValue T3565Cfg TimerValue }
func (*AMFContext) AddAmfUeToUePool ¶
func (context *AMFContext) AddAmfUeToUePool(ue *AmfUe, supi string)
func (*AMFContext) AllocateAmfUeNgapID ¶
func (context *AMFContext) AllocateAmfUeNgapID() (int64, error)
func (*AMFContext) AllocateGutiToUe ¶
func (context *AMFContext) AllocateGutiToUe(ctx ctxt.Context, ue *AmfUe)
func (*AMFContext) AllocateRegistrationArea ¶
func (context *AMFContext) AllocateRegistrationArea(ctx ctxt.Context, ue *AmfUe, anType models.AccessType)
func (*AMFContext) AmfRanFindByConn ¶
func (context *AMFContext) AmfRanFindByConn(conn net.Conn) (*AmfRan, bool)
use net.Conn to find RAN context, return *AmfRan and ok bit
func (*AMFContext) AmfRanFindByGnbID ¶ added in v0.0.12
func (context *AMFContext) AmfRanFindByGnbID(gnbID string) (*AmfRan, bool)
func (*AMFContext) AmfRanFindByRanID ¶
func (context *AMFContext) AmfRanFindByRanID(ranNodeID models.GlobalRanNodeID) (*AmfRan, bool)
use ranNodeID to find RAN context, return *AmfRan and ok bit
func (*AMFContext) AmfUeFindByGuti ¶
func (context *AMFContext) AmfUeFindByGuti(guti string) (ue *AmfUe, ok bool)
func (*AMFContext) AmfUeFindByGutiLocal ¶
func (context *AMFContext) AmfUeFindByGutiLocal(guti string) (ue *AmfUe, ok bool)
func (*AMFContext) AmfUeFindByPolicyAssociationID ¶
func (context *AMFContext) AmfUeFindByPolicyAssociationID(polAssoID string) (ue *AmfUe, ok bool)
func (*AMFContext) AmfUeFindBySuci ¶
func (context *AMFContext) AmfUeFindBySuci(suci string) (ue *AmfUe, ok bool)
func (*AMFContext) AmfUeFindBySupi ¶
func (context *AMFContext) AmfUeFindBySupi(supi string) (ue *AmfUe, ok bool)
func (*AMFContext) AmfUeFindBySupiLocal ¶
func (context *AMFContext) AmfUeFindBySupiLocal(supi string) (ue *AmfUe, ok bool)
func (*AMFContext) AmfUeFindByUeContextID ¶
func (context *AMFContext) AmfUeFindByUeContextID(ueContextID string) (*AmfUe, bool)
func (*AMFContext) DeleteAmfRan ¶
func (context *AMFContext) DeleteAmfRan(conn net.Conn)
func (*AMFContext) Get5gsNwFeatSuppEmc ¶
func (context *AMFContext) Get5gsNwFeatSuppEmc() uint8
func (*AMFContext) Get5gsNwFeatSuppEmcN3 ¶
func (context *AMFContext) Get5gsNwFeatSuppEmcN3() uint8
func (*AMFContext) Get5gsNwFeatSuppEmf ¶
func (context *AMFContext) Get5gsNwFeatSuppEmf() uint8
func (*AMFContext) Get5gsNwFeatSuppEnable ¶
func (context *AMFContext) Get5gsNwFeatSuppEnable() bool
func (*AMFContext) Get5gsNwFeatSuppImsVoPS ¶
func (context *AMFContext) Get5gsNwFeatSuppImsVoPS() uint8
func (*AMFContext) Get5gsNwFeatSuppIwkN26 ¶
func (context *AMFContext) Get5gsNwFeatSuppIwkN26() uint8
func (*AMFContext) Get5gsNwFeatSuppMcsi ¶
func (context *AMFContext) Get5gsNwFeatSuppMcsi() uint8
func (*AMFContext) Get5gsNwFeatSuppMpsi ¶
func (context *AMFContext) Get5gsNwFeatSuppMpsi() uint8
func (*AMFContext) GetIPv4Uri ¶
func (context *AMFContext) GetIPv4Uri() string
func (*AMFContext) InPlmnSupport ¶ added in v0.0.12
func (*AMFContext) ListAmfRan ¶ added in v0.0.5
func (context *AMFContext) ListAmfRan() []AmfRan
func (*AMFContext) NewAmfUe ¶
func (context *AMFContext) NewAmfUe(ctx ctxt.Context, supi string) *AmfUe
func (*AMFContext) RanUeFindByAmfUeNgapID ¶
func (context *AMFContext) RanUeFindByAmfUeNgapID(amfUeNgapID int64) *RanUe
func (*AMFContext) RanUeFindByAmfUeNgapIDLocal ¶
func (context *AMFContext) RanUeFindByAmfUeNgapIDLocal(amfUeNgapID int64) *RanUe
func (*AMFContext) ReAllocateGutiToUe ¶
func (context *AMFContext) ReAllocateGutiToUe(ctx ctxt.Context, ue *AmfUe)
func (*AMFContext) TmsiAllocate ¶
func (context *AMFContext) TmsiAllocate() int32
type AmfRan ¶
type AmfRan struct { RanPresent int RanID *models.GlobalRanNodeID Name string AnType models.AccessType GnbIP string GnbID string // RanID in string format, i.e.,mcc:mnc:gnbid Conn net.Conn SupportedTAList []SupportedTAI RanUeList []*RanUe // RanUeNgapID as key Log *zap.Logger }
func (*AmfRan) RanUeFindByRanUeNgapID ¶
func (*AmfRan) RanUeFindByRanUeNgapIDLocal ¶
func (*AmfRan) RemoveAllUeInRan ¶
func (ran *AmfRan) RemoveAllUeInRan()
func (*AmfRan) SetRanID ¶ added in v0.0.12
func (ran *AmfRan) SetRanID(ranNodeID *ngapType.GlobalRANNodeID)
type AmfUe ¶
type AmfUe struct { // Mutex sync.Mutex `json:"mutex,omitempty" yaml:"mutex" bson:"mutex,omitempty"` Mutex sync.Mutex `json:"-"` /* the AMF which serving this AmfUe now */ ServingAMF *AMFContext `json:"servingAMF,omitempty"` // never nil /* Gmm State */ State map[models.AccessType]*fsm.State `json:"-"` /* Registration procedure related context */ RegistrationType5GS uint8 `json:"registrationType5GS,omitempty"` IdentityTypeUsedForRegistration uint8 `json:"identityTypeUsedForRegistration,omitempty"` RegistrationRequest *nasMessage.RegistrationRequest `json:"registrationRequest,omitempty"` ServingAmfChanged bool `json:"servingAmfChanged,omitempty"` DeregistrationTargetAccessType uint8 `json:"deregistrationTargetAccessType,omitempty"` // only used when deregistration procedure is initialized by the network RegistrationAcceptForNon3GPPAccess []byte `json:"registrationAcceptForNon3GPPAccess,omitempty"` RetransmissionOfInitialNASMsg bool `json:"retransmissionOfInitialNASMsg,omitempty"` /* Used for AMF relocation */ TargetAmfURI string `json:"targetAmfUri,omitempty"` /* Ue Identity*/ PlmnID models.PlmnID `json:"plmnID,omitempty"` Suci string `json:"suci,omitempty"` Supi string `json:"supi,omitempty"` // UnauthenticatedSupi bool `json:"unauthenticatedSupi,omitempty"` Gpsi string `json:"gpsi,omitempty"` Pei string `json:"pei,omitempty"` Tmsi int32 `json:"tmsi,omitempty"` // 5G-Tmsi Guti string `json:"guti,omitempty"` GroupID string `json:"groupID,omitempty"` EBI int32 `json:"ebi,omitempty"` /* Ue Identity*/ /* User Location*/ RatType models.RatType `json:"ratType,omitempty"` Location models.UserLocation `json:"location,omitempty"` Tai models.Tai `json:"tai,omitempty"` LocationChanged bool `json:"locationChanged,omitempty"` LastVisitedRegisteredTai models.Tai `json:"lastVisitedRegisteredTai,omitempty"` TimeZone string `json:"timezone,omitempty"` /* context about udm */ // UdmId string `json:"udmId,omitempty"` SubscriptionDataValid bool `json:"subscriptionDataValid,omitempty"` SmfSelectionData *models.SmfSelectionSubscriptionData `json:"smfSelectionData,omitempty"` UeContextInSmfData *models.UeContextInSmfData `json:"ueContextInSmfData,omitempty"` TraceData *models.TraceData `json:"traceData,omitempty"` SubscribedNssai []models.SubscribedSnssai `json:"subscribeNssai,omitempty"` AccessAndMobilitySubscriptionData *models.AccessAndMobilitySubscriptionData `json:"accessAndMobilitySubscriptionData,omitempty"` RoutingIndicator string `json:"routingIndicator,omitempty"` AuthenticationCtx *models.UeAuthenticationCtx `json:"authenticationCtx,omitempty"` AuthFailureCauseSynchFailureTimes int `json:"authFailureCauseSynchFailureTimes,omitempty"` ABBA []uint8 `json:"abba,omitempty"` Kseaf string `json:"kseaf,omitempty"` Kamf string `json:"kamf,omitempty"` /* context about PCF */ PolicyAssociationID string `json:"policyAssociationId,omitempty"` AmPolicyAssociation *models.PolicyAssociation `json:"amPolicyAssociation,omitempty"` RequestTriggerLocationChange bool `json:"requestTriggerLocationChange,omitempty"` // true if AmPolicyAssociation.Trigger contains RequestTriggerLocCh ConfigurationUpdateMessage []byte `json:"configurationUpdateMessage,omitempty"` /* N1N2Message */ N1N2MessageIDGenerator *idgenerator.IDGenerator `json:"n1n2MessageIDGenerator,omitempty"` N1N2Message *N1N2Message `json:"-"` N1N2MessageSubscribeIDGenerator *idgenerator.IDGenerator `json:"n1n2MessageSubscribeIDGenerator,omitempty"` /* Pdu Sesseion context */ SmContextList sync.Map `json:"-"` // map[int32]*SmContext, pdu session id as key /* Related Context*/ //RanUe map[models.AccessType]*RanUe `json:"ranUe,omitempty" yaml:"ranUe" bson:"ranUe,omitempty"` RanUe map[models.AccessType]*RanUe `json:"ranUe,omitempty"` /* other */ OnGoing map[models.AccessType]*OnGoingProcedureWithPrio `json:"onGoing,omitempty"` UeRadioCapability string `json:"ueRadioCapability,omitempty"` // OCTET string Capability5GMM nasType.Capability5GMM `json:"capability5GMM,omitempty"` ConfigurationUpdateIndication nasType.ConfigurationUpdateIndication `json:"configurationUpdateIndication,omitempty"` /* context related to Paging */ UeRadioCapabilityForPaging *UERadioCapabilityForPaging `json:"ueRadioCapabilityForPaging,omitempty"` InfoOnRecommendedCellsAndRanNodesForPaging *InfoOnRecommendedCellsAndRanNodesForPaging `json:"infoOnRecommendedCellsAndRanNodesForPaging,omitempty"` UESpecificDRX uint8 `json:"ueSpecificDRX,omitempty"` /* Security Context */ SecurityContextAvailable bool `json:"securityContextAvailable,omitempty"` UESecurityCapability nasType.UESecurityCapability `json:"ueSecurityCapability,omitempty"` // for security command NgKsi models.NgKsi `json:"ngKsi,omitempty"` MacFailed bool `json:"macFailed,omitempty"` // set to true if the integrity check of current NAS message is failed KnasInt [16]uint8 `json:"knasInt,omitempty"` // 16 byte KnasEnc [16]uint8 `json:"knasEnc,omitempty"` // 16 byte Kgnb []uint8 `json:"kgnb,omitempty"` // 32 byte Kn3iwf []uint8 `json:"kn3iwf,omitempty"` // 32 byte NH []uint8 `json:"nh,omitempty"` // 32 byte NCC uint8 `json:"ncc,omitempty"` // 0..7 // ULCount security.Count `json:"ulCount,omitempty" yaml:"ulCount" bson:"ulCount,omitempty"` // DLCount security.Count `json:"dlCount,omitempty" yaml:"dlCount" bson:"dlCount,omitempty"` ULCount security.Count `json:"-"` DLCount security.Count `json:"-"` CipheringAlg uint8 `json:"cipheringAlg,omitempty"` IntegrityAlg uint8 `json:"integrityAlg,omitempty"` /* Registration Area */ RegistrationArea map[models.AccessType][]models.Tai `json:"registrationArea,omitempty"` LadnInfo []LADN `json:"ladnInfo,omitempty"` /* Network Slicing related context and Nssf */ NetworkSliceInfo *models.AuthorizedNetworkSliceInfo `json:"networkSliceInfo,omitempty"` AllowedNssai map[models.AccessType][]models.AllowedSnssai `json:"allowedNssai,omitempty"` NetworkSlicingSubscriptionChanged bool `json:"networkSlicingSubscriptionChanged,omitempty"` /* T3513(Paging) */ T3513 *Timer `json:"t3513Value,omitempty"` // for paging /* T3565(Notification) */ T3565 *Timer `json:"t3565Value,omitempty"` // for NAS Notification /* T3560 (for authentication request/security mode command retransmission) */ T3560 *Timer `json:"t3560Value,omitempty"` /* T3550 (for registration accept retransmission) */ T3550 *Timer `json:"t3550Value,omitempty"` /* T3522 (for deregistration request) */ T3522 *Timer `json:"t3522Value,omitempty"` /* Ue Context Release Cause */ ReleaseCause map[models.AccessType]*CauseAll `json:"releaseCause,omitempty"` /* T3502 (Assigned by AMF, and used by UE to initialize registration procedure) */ T3502Value int `json:"t3502Value,omitempty"` // Second T3512Value int `json:"t3512Value,omitempty"` // default 54 min Non3gppDeregistrationTimerValue int `json:"non3gppDeregistrationTimerValue,omitempty"` // default 54 min // AmfInstanceName and Ip AmfInstanceName string `json:"amfInstanceName,omitempty"` AmfInstanceIP string `json:"amfInstanceIp,omitempty"` NASLog *zap.Logger `json:"-"` GmmLog *zap.Logger `json:"-"` TxLog *zap.Logger `json:"-"` ProducerLog *zap.Logger `json:"-"` }
func (*AmfUe) AttachRanUe ¶
func (*AmfUe) ClearRegistrationData ¶
func (ue *AmfUe) ClearRegistrationData()
this method called when we are reusing the same uecontext during the registration procedure
func (*AmfUe) ClearRegistrationRequestData ¶
func (ue *AmfUe) ClearRegistrationRequestData(accessType models.AccessType)
this is clearing the transient data of registration request, this is called entrypoint of Deregistration and Registration state
func (*AmfUe) CopyDataFromUeContextModel ¶
func (*AmfUe) DerivateAlgKey ¶
func (ue *AmfUe) DerivateAlgKey()
Algorithm key Derivation function defined in TS 33.501 Annex A.9
func (*AmfUe) DerivateAnKey ¶
func (ue *AmfUe) DerivateAnKey(anType models.AccessType)
Access Network key Derivation function defined in TS 33.501 Annex A.9
func (*AmfUe) DerivateKamf ¶
func (ue *AmfUe) DerivateKamf()
Kamf Derivation function defined in TS 33.501 Annex A.7
func (*AmfUe) DerivateNH ¶
NH Derivation function defined in TS 33.501 Annex A.10
func (*AmfUe) DetachRanUe ¶
func (ue *AmfUe) DetachRanUe(anType models.AccessType)
func (*AmfUe) GetAnType ¶
func (ue *AmfUe) GetAnType() models.AccessType
func (*AmfUe) GetNsiInformationFromSnssai ¶
func (ue *AmfUe) GetNsiInformationFromSnssai(anType models.AccessType, snssai models.Snssai) *models.NsiInformation
func (*AmfUe) GetOnGoing ¶
func (ue *AmfUe) GetOnGoing(anType models.AccessType) OnGoingProcedureWithPrio
func (*AmfUe) HasWildCardSubscribedDNN ¶
func (*AmfUe) InAllowedNssai ¶
func (*AmfUe) InSubscribedNssai ¶
func (*AmfUe) RemoveAmPolicyAssociation ¶
func (ue *AmfUe) RemoveAmPolicyAssociation()
func (*AmfUe) SecurityContextIsValid ¶
func (*AmfUe) SelectSecurityAlg ¶
func (*AmfUe) SetOnGoing ¶
func (ue *AmfUe) SetOnGoing(anType models.AccessType, onGoing *OnGoingProcedureWithPrio)
func (*AmfUe) SmContextFindByPDUSessionID ¶
func (*AmfUe) StoreSmContext ¶
func (*AmfUe) TaiListInRegistrationArea ¶
func (*AmfUe) UpdateSecurityContext ¶
func (ue *AmfUe) UpdateSecurityContext(anType models.AccessType)
type InfoOnRecommendedCellsAndRanNodesForPaging ¶
type InfoOnRecommendedCellsAndRanNodesForPaging struct { RecommendedCells []RecommendedCell // RecommendedCellsForPaging RecommendedRanNodes []RecommendRanNode // RecommendedRanNodesForPaging }
TS 38.413 9.3.1.100
type InterfaceMsg ¶
type InterfaceMsg interface{}
type InterfaceType ¶
type InterfaceType uint8
const ( NgapMessage InterfaceType = iota SbiMessage NasMessage )
type N1N2Message ¶
type N1N2Message struct { Request models.N1N2MessageTransferRequest Status models.N1N2MessageTransferCause }
type NetworkName ¶
type OnGoingProcedure ¶
type OnGoingProcedure string
const ( OnGoingProcedureNothing OnGoingProcedure = "Nothing" OnGoingProcedurePaging OnGoingProcedure = "Paging" OnGoingProcedureN2Handover OnGoingProcedure = "N2Handover" OnGoingProcedureRegistration OnGoingProcedure = "Registration" OnGoingProcedureAbort OnGoingProcedure = "Abort" )
type OnGoingProcedureWithPrio ¶
type OnGoingProcedureWithPrio struct { Procedure OnGoingProcedure Ppi int32 // Paging priority }
type PlmnSupportItem ¶
func GetSupportedPlmn ¶ added in v0.0.12
func GetSupportedPlmn(ctx context.Context) *PlmnSupportItem
type RanUe ¶
type RanUe struct { RanUeNgapID int64 AmfUeNgapID int64 HandOverType ngapType.HandoverType SuccessPduSessionID []int32 SourceUe *RanUe TargetUe *RanUe Tai models.Tai Location models.UserLocation SupportVoPS bool SupportedFeatures string LastActTime *time.Time AmfUe *AmfUe Ran *AmfRan RoutingID string Trsr string /* Trace Recording Session Reference */ ReleaseAction RelAction OldAmfName string InitialUEMessage []byte RRCEstablishmentCause string // Received from initial ue message; pattern: ^[0-9a-fA-F]+$ UeContextRequest bool SentInitialContextSetupRequest bool RecvdInitialContextSetupResponse bool /*Received Initial context setup response or not */ Log *zap.Logger }
func (*RanUe) DetachAmfUe ¶
func (ranUe *RanUe) DetachAmfUe()
func (*RanUe) SwitchToRan ¶
func (*RanUe) UpdateLocation ¶
func (ranUe *RanUe) UpdateLocation(ctx context.Context, userLocationInformation *ngapType.UserLocationInformation)
type RecommendRanNode ¶
type RecommendRanNode struct { Present int32 GlobalRanNodeID *models.GlobalRanNodeID Tai *models.Tai }
TS 38.413 9.3.1.101
type RecommendedCell ¶
TS 38.413 9.3.1.71
type SecurityAlgorithm ¶
type SmContext ¶
type SmContext struct { Mu *sync.RWMutex // protect the following fields PduSessionIDVal int32 SmContextRefVal string SnssaiVal models.Snssai DnnVal string AccessTypeVal models.AccessType NsInstanceVal string UserLocationVal models.UserLocation PlmnIDVal models.PlmnID SmfIDVal string HSmfIDVal string VSmfIDVal string PduSessionInactiveVal bool UlNASTransportVal *nasMessage.ULNASTransport DuplicatedVal bool }
func NewSmContext ¶
func (*SmContext) AccessType ¶
func (c *SmContext) AccessType() models.AccessType
func (*SmContext) DeleteULNASTransport ¶
func (c *SmContext) DeleteULNASTransport()
func (*SmContext) IsPduSessionActive ¶
func (*SmContext) NsInstance ¶
func (*SmContext) PduSessionID ¶
func (*SmContext) PduSessionIDDuplicated ¶
func (*SmContext) SetAccessType ¶
func (c *SmContext) SetAccessType(accessType models.AccessType)
func (*SmContext) SetDuplicatedPduSessionID ¶
func (*SmContext) SetNsInstance ¶
func (*SmContext) SetPduSessionID ¶
func (*SmContext) SetPduSessionInActive ¶
func (*SmContext) SetSmContextRef ¶
func (*SmContext) SetUserLocation ¶
func (c *SmContext) SetUserLocation(userLocation models.UserLocation)
func (*SmContext) SmContextRef ¶
func (*SmContext) StoreULNASTransport ¶
func (c *SmContext) StoreULNASTransport(msg *nasMessage.ULNASTransport)
func (*SmContext) ULNASTransport ¶
func (c *SmContext) ULNASTransport() *nasMessage.ULNASTransport
func (*SmContext) UserLocation ¶
func (c *SmContext) UserLocation() models.UserLocation
type SupportedTAI ¶
func NewSupportedTAI ¶
func NewSupportedTAI() (tai SupportedTAI)
func NewSupportedTAIList ¶
func NewSupportedTAIList() []SupportedTAI
type Timer ¶
type Timer struct {
// contains filtered or unexported fields
}
Timer can be used for retransmission, it will manage retry times automatically
func NewTimer ¶
func NewTimer(d time.Duration, maxRetryTimes int32, expiredFunc func(expireTimes int32), cancelFunc func()) *Timer
NewTimer will return a Timer struct and create a goroutine. Then it calls expiredFunc every time interval d until the user call Stop(). the number of expire event is be recorded when the timer is active. When the number of expire event is > maxRetryTimes, then the timer will call cancelFunc and turns off itself. Whether expiredFunc pass a parameter expireTimes to tell the user that the current expireTimes.
func (*Timer) ExpireTimes ¶
ExpireTimes return the current expire times of the timer
func (*Timer) MaxRetryTimes ¶
MaxRetryTimes return the max retry times of the timer