2020-05-25 16:15:22 +00:00
|
|
|
/*
|
|
|
|
* Copyright (C) 2019,2020 by Sukchan Lee <acetcom@gmail.com>
|
|
|
|
*
|
|
|
|
* This file is part of Open5GS.
|
|
|
|
*
|
|
|
|
* This program is free software: you can redistribute it and/or modify
|
|
|
|
* it under the terms of the GNU Affero General Public License as published by
|
|
|
|
* the Free Software Foundation, either version 3 of the License, or
|
|
|
|
* (at your option) any later version.
|
|
|
|
*
|
|
|
|
* This program is distributed in the hope that it will be useful,
|
|
|
|
* but WITHOUT ANY WARRANTY; without even the implied warranty of
|
|
|
|
* MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
|
|
|
|
* GNU General Public License for more details.
|
|
|
|
*
|
|
|
|
* You should have received a copy of the GNU General Public License
|
|
|
|
* along with this program. If not, see <https://www.gnu.org/licenses/>.
|
|
|
|
*/
|
|
|
|
|
|
|
|
#ifndef AMF_CONTEXT_H
|
|
|
|
#define AMF_CONTEXT_H
|
|
|
|
|
|
|
|
#include "ogs-app.h"
|
|
|
|
#include "ogs-sbi.h"
|
|
|
|
#include "ogs-sctp.h"
|
|
|
|
#include "ogs-ngap.h"
|
|
|
|
#include "ogs-nas-5gs.h"
|
|
|
|
|
|
|
|
#include "amf-sm.h"
|
|
|
|
#include "timer.h"
|
|
|
|
|
|
|
|
#ifdef __cplusplus
|
|
|
|
extern "C" {
|
|
|
|
#endif
|
|
|
|
|
|
|
|
#define MAX_NUM_OF_SERVED_GUAMI 8
|
|
|
|
|
|
|
|
extern int __amf_log_domain;
|
2020-06-04 18:12:05 +00:00
|
|
|
extern int __gmm_log_domain;
|
2020-05-25 16:15:22 +00:00
|
|
|
|
|
|
|
#undef OGS_LOG_DOMAIN
|
|
|
|
#define OGS_LOG_DOMAIN __amf_log_domain
|
|
|
|
|
2020-06-04 18:12:05 +00:00
|
|
|
typedef struct ran_ue_s ran_ue_t;
|
|
|
|
typedef struct amf_ue_s amf_ue_t;
|
|
|
|
|
2020-05-25 16:15:22 +00:00
|
|
|
typedef uint32_t amf_m_tmsi_t;
|
2020-06-17 05:22:28 +00:00
|
|
|
|
2020-05-25 16:15:22 +00:00
|
|
|
typedef struct amf_context_s {
|
|
|
|
OpenAPI_nf_type_e nf_type;
|
|
|
|
|
2020-06-04 18:12:05 +00:00
|
|
|
/* Served GUAMI */
|
2020-05-25 16:15:22 +00:00
|
|
|
uint8_t num_of_served_guami;
|
2020-07-09 05:38:09 +00:00
|
|
|
ogs_guami_t served_guami[MAX_NUM_OF_SERVED_GUAMI];
|
2020-05-25 16:15:22 +00:00
|
|
|
|
|
|
|
/* Served TAI */
|
|
|
|
uint8_t num_of_served_tai;
|
|
|
|
struct {
|
|
|
|
ogs_5gs_tai0_list_t list0;
|
|
|
|
ogs_5gs_tai2_list_t list2;
|
|
|
|
} served_tai[OGS_MAX_NUM_OF_SERVED_TAI];
|
|
|
|
|
|
|
|
/* PLMN Support */
|
|
|
|
uint8_t num_of_plmn_support;
|
|
|
|
struct {
|
|
|
|
ogs_plmn_id_t plmn_id;
|
|
|
|
int num_of_s_nssai;
|
2021-03-08 12:25:09 +00:00
|
|
|
ogs_s_nssai_t s_nssai[OGS_MAX_NUM_OF_SLICE];
|
2020-05-25 16:15:22 +00:00
|
|
|
} plmn_support[OGS_MAX_NUM_OF_PLMN];
|
|
|
|
|
|
|
|
/* defined in 'nas_ies.h'
|
|
|
|
* #define NAS_SECURITY_ALGORITHMS_EIA0 0
|
|
|
|
* #define NAS_SECURITY_ALGORITHMS_128_EEA1 1
|
|
|
|
* #define NAS_SECURITY_ALGORITHMS_128_EEA2 2
|
|
|
|
* #define NAS_SECURITY_ALGORITHMS_128_EEA3 3 */
|
|
|
|
uint8_t num_of_ciphering_order;
|
|
|
|
uint8_t ciphering_order[OGS_MAX_NUM_OF_ALGORITHM];
|
|
|
|
/* defined in 'nas_ies.h'
|
|
|
|
* #define NAS_SECURITY_ALGORITHMS_EIA0 0
|
|
|
|
* #define NAS_SECURITY_ALGORITHMS_128_EIA1 1
|
|
|
|
* #define NAS_SECURITY_ALGORITHMS_128_EIA1 2
|
|
|
|
* #define NAS_SECURITY_ALGORITHMS_128_EIA3 3 */
|
|
|
|
uint8_t num_of_integrity_order;
|
|
|
|
uint8_t integrity_order[OGS_MAX_NUM_OF_ALGORITHM];
|
|
|
|
|
|
|
|
/* Network Name */
|
2020-06-04 18:12:05 +00:00
|
|
|
ogs_nas_network_name_t short_name; /* Network short name */
|
|
|
|
ogs_nas_network_name_t full_name; /* Network Full Name */
|
2020-05-25 16:15:22 +00:00
|
|
|
|
2020-05-25 16:34:05 +00:00
|
|
|
/* AMF Name */
|
|
|
|
const char *amf_name;
|
|
|
|
|
2020-05-25 16:15:22 +00:00
|
|
|
/* NGSetupResponse */
|
|
|
|
uint8_t relative_capacity;
|
|
|
|
|
2020-06-04 18:12:05 +00:00
|
|
|
/* Generator for unique identification */
|
|
|
|
uint64_t amf_ue_ngap_id; /* amf_ue_ngap_id generator */
|
|
|
|
|
|
|
|
ogs_list_t gnb_list; /* GNB NGAP Client List */
|
|
|
|
ogs_list_t amf_ue_list;
|
|
|
|
|
|
|
|
ogs_hash_t *gnb_addr_hash; /* hash table for GNB Address */
|
|
|
|
ogs_hash_t *gnb_id_hash; /* hash table for GNB-ID */
|
|
|
|
ogs_hash_t *guti_ue_hash; /* hash table (GUTI : AMF_UE) */
|
|
|
|
ogs_hash_t *suci_hash; /* hash table (SUCI) */
|
|
|
|
ogs_hash_t *supi_hash; /* hash table (SUPI) */
|
|
|
|
|
|
|
|
OGS_POOL(m_tmsi, amf_m_tmsi_t); /* M-TMSI Pool */
|
|
|
|
|
2020-05-25 16:15:22 +00:00
|
|
|
uint16_t ngap_port; /* Default NGAP Port */
|
|
|
|
|
|
|
|
ogs_list_t ngap_list; /* AMF NGAP IPv4 Server List */
|
|
|
|
ogs_list_t ngap_list6; /* AMF NGAP IPv6 Server List */
|
|
|
|
|
|
|
|
} amf_context_t;
|
|
|
|
|
|
|
|
typedef struct amf_gnb_s {
|
|
|
|
ogs_lnode_t lnode;
|
|
|
|
|
|
|
|
ogs_fsm_t sm; /* A state machine */
|
|
|
|
|
2020-06-04 18:12:05 +00:00
|
|
|
uint32_t gnb_id; /* gNB_ID received from gNB */
|
2020-11-11 18:21:32 +00:00
|
|
|
ogs_sctp_sock_t sctp; /* SCTP socket */
|
2020-05-25 16:15:22 +00:00
|
|
|
|
|
|
|
struct {
|
2020-06-04 18:12:05 +00:00
|
|
|
bool ng_setup_success; /* gNB NGAP Setup complete successfuly */
|
2020-05-25 16:15:22 +00:00
|
|
|
} state;
|
|
|
|
|
|
|
|
uint16_t max_num_of_ostreams;/* SCTP Max num of outbound streams */
|
|
|
|
uint16_t ostream_id; /* gnb_ostream_id generator */
|
|
|
|
|
|
|
|
uint8_t num_of_supported_ta_list;
|
2020-06-23 04:35:41 +00:00
|
|
|
struct {
|
|
|
|
ogs_uint24_t tac;
|
|
|
|
uint8_t num_of_bplmn_list;
|
|
|
|
struct {
|
|
|
|
ogs_plmn_id_t plmn_id;
|
|
|
|
uint8_t num_of_s_nssai;
|
2021-03-08 12:25:09 +00:00
|
|
|
ogs_s_nssai_t s_nssai[OGS_MAX_NUM_OF_SLICE];
|
2020-06-23 04:35:41 +00:00
|
|
|
} bplmn_list[OGS_MAX_NUM_OF_BPLMN];
|
|
|
|
} supported_ta_list[OGS_MAX_NUM_OF_TAI];
|
2020-05-25 16:15:22 +00:00
|
|
|
|
2020-12-11 19:03:20 +00:00
|
|
|
OpenAPI_rat_type_e rat_type;
|
|
|
|
|
2021-02-02 18:33:09 +00:00
|
|
|
ogs_pkbuf_t *ng_reset_ack; /* Reset message */
|
|
|
|
|
2020-06-04 18:12:05 +00:00
|
|
|
ogs_list_t ran_ue_list;
|
2020-05-25 16:15:22 +00:00
|
|
|
|
|
|
|
} amf_gnb_t;
|
|
|
|
|
2020-06-04 18:12:05 +00:00
|
|
|
struct ran_ue_s {
|
|
|
|
ogs_lnode_t lnode;
|
2020-08-30 03:27:54 +00:00
|
|
|
uint32_t index;
|
2020-06-04 18:12:05 +00:00
|
|
|
|
|
|
|
/* UE identity */
|
|
|
|
#define INVALID_UE_NGAP_ID 0xffffffff /* Initial value of ran_ue_ngap_id */
|
|
|
|
uint32_t ran_ue_ngap_id; /* eNB-UE-NGAP-ID received from eNB */
|
|
|
|
uint64_t amf_ue_ngap_id; /* AMF-UE-NGAP-ID received from AMF */
|
|
|
|
|
|
|
|
uint16_t gnb_ostream_id; /* SCTP output stream id for eNB */
|
|
|
|
|
2021-01-08 03:26:06 +00:00
|
|
|
/* UE context */
|
|
|
|
bool ue_context_requested;
|
|
|
|
bool initial_context_setup_request_sent;
|
|
|
|
|
2020-06-04 18:12:05 +00:00
|
|
|
/* Handover Info */
|
|
|
|
ran_ue_t *source_ue;
|
|
|
|
ran_ue_t *target_ue;
|
|
|
|
|
2021-03-08 12:25:09 +00:00
|
|
|
/* Use amf_ue->nr_tai, amf_ue->nr_cgi.
|
2020-06-26 02:44:28 +00:00
|
|
|
* Do not access ran_ue->saved.tai ran_ue->saved.nr_cgi.
|
2020-06-04 18:12:05 +00:00
|
|
|
*
|
2021-03-08 12:25:09 +00:00
|
|
|
* Save TAI and CGI. And then, this will copy 'amf_ue_t' context later */
|
2020-06-04 18:12:05 +00:00
|
|
|
struct {
|
2021-03-08 12:25:09 +00:00
|
|
|
ogs_5gs_tai_t nr_tai;
|
2020-06-26 02:44:28 +00:00
|
|
|
ogs_nr_cgi_t nr_cgi;
|
2020-06-04 18:12:05 +00:00
|
|
|
} saved;
|
|
|
|
|
2020-09-04 02:00:26 +00:00
|
|
|
/* NG Holding timer for removing this context */
|
|
|
|
ogs_timer_t *t_ng_holding;
|
|
|
|
|
2020-06-04 18:12:05 +00:00
|
|
|
/* Store by UE Context Release Command
|
|
|
|
* Retrieve by UE Context Release Complete */
|
|
|
|
#define NGAP_UE_CTX_REL_INVALID_ACTION 0
|
2020-06-22 03:07:14 +00:00
|
|
|
#define NGAP_UE_CTX_REL_NG_CONTEXT_REMOVE 1
|
|
|
|
#define NGAP_UE_CTX_REL_NG_REMOVE_AND_UNLINK 2
|
2020-06-04 18:12:05 +00:00
|
|
|
#define NGAP_UE_CTX_REL_UE_CONTEXT_REMOVE 3
|
2021-01-28 19:23:54 +00:00
|
|
|
#define NGAP_UE_CTX_REL_NG_HANDOVER_COMPLETE 4
|
2021-02-01 04:01:15 +00:00
|
|
|
#define NGAP_UE_CTX_REL_NG_HANDOVER_CANCEL 5
|
|
|
|
#define NGAP_UE_CTX_REL_NG_HANDOVER_FAILURE 6
|
2020-06-04 18:12:05 +00:00
|
|
|
uint8_t ue_ctx_rel_action;
|
|
|
|
|
2021-02-02 18:33:09 +00:00
|
|
|
bool part_of_ng_reset_requested;
|
|
|
|
|
2020-06-04 18:12:05 +00:00
|
|
|
/* Related Context */
|
|
|
|
amf_gnb_t *gnb;
|
|
|
|
amf_ue_t *amf_ue;
|
|
|
|
};
|
|
|
|
|
2020-06-17 05:22:28 +00:00
|
|
|
#define AMF_NF_INSTANCE_CLEAR(_cAUSE, _nFInstance) \
|
|
|
|
do { \
|
|
|
|
ogs_assert(_nFInstance); \
|
|
|
|
if ((_nFInstance)->reference_count == 1) { \
|
|
|
|
ogs_info("[%s] (%s) NF removed", (_nFInstance)->id, (_cAUSE)); \
|
|
|
|
amf_nf_fsm_fini((_nFInstance)); \
|
|
|
|
} else { \
|
|
|
|
/* There is an assocation with other context */ \
|
|
|
|
ogs_info("[%s:%d] (%s) NF suspended", \
|
|
|
|
_nFInstance->id, _nFInstance->reference_count, (_cAUSE)); \
|
|
|
|
OGS_FSM_TRAN(&_nFInstance->sm, amf_nf_state_de_registered); \
|
|
|
|
ogs_fsm_dispatch(&_nFInstance->sm, NULL); \
|
|
|
|
} \
|
|
|
|
ogs_sbi_nf_instance_remove(_nFInstance); \
|
|
|
|
} while(0)
|
|
|
|
|
2020-06-04 18:12:05 +00:00
|
|
|
struct amf_ue_s {
|
2020-06-17 05:22:28 +00:00
|
|
|
ogs_sbi_object_t sbi;
|
|
|
|
ogs_fsm_t sm;
|
2020-06-04 18:12:05 +00:00
|
|
|
|
|
|
|
struct {
|
2020-06-24 04:33:10 +00:00
|
|
|
uint8_t message_type; /* Type of last specific NAS message received */
|
2020-06-17 05:22:28 +00:00
|
|
|
int access_type; /* 3GPP or Non-3GPP */
|
|
|
|
|
2020-06-25 04:37:29 +00:00
|
|
|
/* InitialUEMessage or UplinkNASTrasnport */
|
|
|
|
NGAP_ProcedureCode_t ngapProcedureCode;
|
|
|
|
|
2020-06-04 18:12:05 +00:00
|
|
|
union {
|
2020-06-17 05:22:28 +00:00
|
|
|
struct {
|
|
|
|
ED3(uint8_t tsc:1;,
|
|
|
|
uint8_t ksi:3;,
|
2020-06-22 03:07:14 +00:00
|
|
|
uint8_t value:4;)
|
2020-06-17 05:22:28 +00:00
|
|
|
};
|
2020-06-04 18:12:05 +00:00
|
|
|
ogs_nas_5gs_registration_type_t registration;
|
2020-06-22 03:07:14 +00:00
|
|
|
ogs_nas_de_registration_type_t de_registration;
|
2020-06-17 05:22:28 +00:00
|
|
|
|
2020-06-04 18:12:05 +00:00
|
|
|
uint8_t data;
|
|
|
|
};
|
|
|
|
|
2020-06-25 04:37:29 +00:00
|
|
|
struct {
|
|
|
|
ED4(uint8_t uplink_data_status:1;,
|
|
|
|
uint8_t pdu_session_status:1;,
|
|
|
|
uint8_t allowed_pdu_session_status:1;,
|
|
|
|
uint8_t reserved:5;)
|
|
|
|
} present;
|
|
|
|
|
2020-06-17 05:22:28 +00:00
|
|
|
} __attribute__ ((packed)) nas;
|
2020-06-04 18:12:05 +00:00
|
|
|
|
2020-06-17 05:22:28 +00:00
|
|
|
/* UE identity */
|
2020-06-04 18:12:05 +00:00
|
|
|
#define AMF_UE_HAVE_SUCI(__aMF) \
|
|
|
|
((__aMF) && ((__aMF)->suci))
|
2020-06-17 05:22:28 +00:00
|
|
|
char *suci; /* TS33.501 : SUCI */
|
|
|
|
char *supi; /* TS33.501 : SUPI */
|
2020-06-22 03:07:14 +00:00
|
|
|
ogs_nas_5gs_mobile_identity_suci_t nas_mobile_identity_suci;
|
2020-06-04 18:12:05 +00:00
|
|
|
|
2020-06-17 05:22:28 +00:00
|
|
|
char *pei;
|
2020-06-27 04:46:06 +00:00
|
|
|
uint8_t masked_imeisv[OGS_MAX_IMEISV_LEN];
|
|
|
|
int masked_imeisv_len;
|
2020-06-04 18:12:05 +00:00
|
|
|
char imeisv_bcd[OGS_MAX_IMEISV_BCD_LEN+1];
|
|
|
|
ogs_nas_mobile_identity_imeisv_t nas_mobile_identity_imeisv;
|
|
|
|
|
2020-06-30 02:12:24 +00:00
|
|
|
int num_of_msisdn;
|
|
|
|
char *msisdn[OGS_MAX_NUM_OF_MSISDN];
|
|
|
|
|
2020-06-04 18:12:05 +00:00
|
|
|
amf_m_tmsi_t *m_tmsi;
|
|
|
|
ogs_nas_5gs_guti_t guti;
|
2021-03-09 05:28:07 +00:00
|
|
|
bool guti_present;
|
2020-06-04 18:12:05 +00:00
|
|
|
|
|
|
|
/* UE Info */
|
2020-07-09 05:38:09 +00:00
|
|
|
ogs_guami_t *guami;
|
2021-01-18 16:48:35 +00:00
|
|
|
uint16_t gnb_ostream_id;
|
2021-03-08 12:25:09 +00:00
|
|
|
ogs_5gs_tai_t nr_tai;
|
2020-06-26 02:44:28 +00:00
|
|
|
ogs_nr_cgi_t nr_cgi;
|
2020-07-09 05:38:09 +00:00
|
|
|
ogs_time_t ue_location_timestamp;
|
2020-06-04 18:12:05 +00:00
|
|
|
ogs_plmn_id_t last_visited_plmn_id;
|
2020-06-24 04:33:10 +00:00
|
|
|
ogs_nas_ue_usage_setting_t ue_usage_setting;
|
|
|
|
|
2021-03-08 12:25:09 +00:00
|
|
|
struct {
|
|
|
|
int num_of_s_nssai;
|
|
|
|
ogs_nas_s_nssai_ie_t s_nssai[OGS_MAX_NUM_OF_SLICE];
|
|
|
|
} requested_nssai, allowed_nssai;
|
|
|
|
|
|
|
|
struct {
|
|
|
|
int num_of_s_nssai;
|
|
|
|
ogs_nas_rejected_s_nssai_t s_nssai[OGS_MAX_NUM_OF_SLICE];
|
|
|
|
} rejected_nssai;
|
2020-06-04 18:12:05 +00:00
|
|
|
|
2020-12-11 19:03:20 +00:00
|
|
|
/* PCF sends the RESPONSE
|
|
|
|
* of [POST] /npcf-am-polocy-control/v1/policies */
|
|
|
|
char *policy_association_id;
|
|
|
|
|
2020-06-04 18:12:05 +00:00
|
|
|
/* 5GMM Capability */
|
|
|
|
struct {
|
|
|
|
bool lte_positioning_protocol_capability;
|
|
|
|
bool ho_attach;
|
|
|
|
bool s1_mode;
|
|
|
|
} gmm_capability;
|
|
|
|
|
|
|
|
#define SECURITY_CONTEXT_IS_VALID(__aMF) \
|
|
|
|
((__aMF) && \
|
|
|
|
((__aMF)->security_context_available == 1) && \
|
|
|
|
((__aMF)->mac_failed == 0) && \
|
|
|
|
((__aMF)->nas.ksi != OGS_NAS_KSI_NO_KEY_IS_AVAILABLE))
|
|
|
|
#define CLEAR_SECURITY_CONTEXT(__aMF) \
|
|
|
|
do { \
|
|
|
|
ogs_assert((__aMF)); \
|
|
|
|
(__aMF)->security_context_available = 0; \
|
|
|
|
(__aMF)->mac_failed = 0; \
|
2020-06-17 05:22:28 +00:00
|
|
|
(__aMF)->nas.tsc = 0; \
|
2020-06-04 18:12:05 +00:00
|
|
|
(__aMF)->nas.ksi = 0; \
|
|
|
|
} while(0)
|
|
|
|
int security_context_available;
|
|
|
|
int mac_failed;
|
|
|
|
|
|
|
|
/* Security Context */
|
|
|
|
ogs_nas_ue_security_capability_t ue_security_capability;
|
2020-06-23 04:35:41 +00:00
|
|
|
ogs_nas_ue_network_capability_t ue_network_capability;
|
2020-06-04 18:12:05 +00:00
|
|
|
char *confirmation_url_for_5g_aka;
|
|
|
|
uint8_t rand[OGS_RAND_LEN];
|
|
|
|
uint8_t autn[OGS_AUTN_LEN];
|
|
|
|
uint8_t xres_star[OGS_MAX_RES_LEN];
|
|
|
|
|
|
|
|
uint8_t abba[OGS_NAS_MAX_ABBA_LEN];
|
|
|
|
uint8_t abba_len;
|
|
|
|
|
|
|
|
uint8_t hxres_star[OGS_MAX_RES_LEN];
|
|
|
|
uint8_t kamf[OGS_SHA256_DIGEST_SIZE];
|
|
|
|
OpenAPI_auth_result_e auth_result;
|
|
|
|
|
|
|
|
uint8_t knas_int[OGS_SHA256_DIGEST_SIZE/2];
|
|
|
|
uint8_t knas_enc[OGS_SHA256_DIGEST_SIZE/2];
|
|
|
|
uint32_t dl_count;
|
|
|
|
union {
|
|
|
|
struct {
|
|
|
|
ED3(uint8_t spare;,
|
|
|
|
uint16_t overflow;,
|
|
|
|
uint8_t sqn;)
|
|
|
|
} __attribute__ ((packed));
|
|
|
|
uint32_t i32;
|
|
|
|
} ul_count;
|
|
|
|
uint8_t kgnb[OGS_SHA256_DIGEST_SIZE];
|
|
|
|
|
|
|
|
struct {
|
|
|
|
ED2(uint8_t nhcc_spare:5;,
|
|
|
|
uint8_t nhcc:3;) /* Next Hop Channing Counter */
|
|
|
|
};
|
|
|
|
uint8_t nh[OGS_SHA256_DIGEST_SIZE]; /* NH Security Key */
|
|
|
|
|
|
|
|
/* defined in 'lib/nas/common/types.h'
|
|
|
|
* #define OGS_NAS_SECURITY_ALGORITHMS_NEA0 0
|
|
|
|
* #define OGS_NAS_SECURITY_ALGORITHMS_128_NEA1 1
|
|
|
|
* #define OGS_NAS_SECURITY_ALGORITHMS_128_NEA2 2
|
|
|
|
* #define OGS_NAS_SECURITY_ALGORITHMS_128_NEA3 3 */
|
|
|
|
uint8_t selected_enc_algorithm;
|
|
|
|
/* defined in 'lib/nas/common/types.h'
|
|
|
|
* #define OGS_NAS_SECURITY_ALGORITHMS_NIA0 0
|
|
|
|
* #define OGS_NAS_SECURITY_ALGORITHMS_128_NIA1 1
|
|
|
|
* #define OGS_NAS_SECURITY_ALGORITHMS_128_NIA1 2
|
|
|
|
* #define OGS_NAS_SECURITY_ALGORITHMS_128_NIA3 3 */
|
|
|
|
uint8_t selected_int_algorithm;
|
|
|
|
|
2021-03-08 12:25:09 +00:00
|
|
|
/* SubscribedInfo */
|
|
|
|
ogs_bitrate_t ue_ambr;
|
|
|
|
int num_of_slice;
|
|
|
|
ogs_slice_data_t slice[OGS_MAX_NUM_OF_SLICE];
|
2020-06-17 05:22:28 +00:00
|
|
|
|
2021-01-01 02:07:08 +00:00
|
|
|
uint64_t am_policy_control_features; /* SBI Features */
|
|
|
|
|
2020-06-22 03:07:14 +00:00
|
|
|
#define CM_CONNECTED(__aMF) \
|
2020-10-29 02:59:27 +00:00
|
|
|
((__aMF) && ((__aMF)->ran_ue != NULL) && ran_ue_cycle((__aMF)->ran_ue))
|
2020-09-08 02:02:45 +00:00
|
|
|
#define CM_IDLE(__aMF) \
|
2020-10-29 02:59:27 +00:00
|
|
|
((__aMF) && \
|
|
|
|
(((__aMF)->ran_ue == NULL) || (ran_ue_cycle((__aMF)->ran_ue) == NULL)))
|
2020-06-22 03:07:14 +00:00
|
|
|
/* NG UE context */
|
2020-06-04 18:12:05 +00:00
|
|
|
ran_ue_t *ran_ue;
|
|
|
|
|
|
|
|
#define CLEAR_AMF_UE_ALL_TIMERS(__aMF) \
|
|
|
|
do { \
|
|
|
|
CLEAR_AMF_UE_TIMER((__aMF)->t3513); \
|
|
|
|
CLEAR_AMF_UE_TIMER((__aMF)->t3522); \
|
|
|
|
CLEAR_AMF_UE_TIMER((__aMF)->t3550); \
|
2020-06-17 05:22:28 +00:00
|
|
|
CLEAR_AMF_UE_TIMER((__aMF)->t3555); \
|
2020-06-04 18:12:05 +00:00
|
|
|
CLEAR_AMF_UE_TIMER((__aMF)->t3560); \
|
|
|
|
CLEAR_AMF_UE_TIMER((__aMF)->t3570); \
|
|
|
|
} while(0);
|
|
|
|
#define CLEAR_AMF_UE_TIMER(__aMF_UE_TIMER) \
|
|
|
|
do { \
|
|
|
|
ogs_timer_stop((__aMF_UE_TIMER).timer); \
|
|
|
|
if ((__aMF_UE_TIMER).pkbuf) { \
|
|
|
|
ogs_pkbuf_free((__aMF_UE_TIMER).pkbuf); \
|
|
|
|
(__aMF_UE_TIMER).pkbuf = NULL; \
|
|
|
|
} \
|
|
|
|
(__aMF_UE_TIMER).retry_count = 0; \
|
|
|
|
} while(0);
|
|
|
|
struct {
|
|
|
|
ogs_pkbuf_t *pkbuf;
|
|
|
|
ogs_timer_t *timer;
|
|
|
|
uint32_t retry_count;;
|
2020-06-17 05:22:28 +00:00
|
|
|
} t3513, t3522, t3550, t3555, t3560, t3570;
|
2020-06-04 18:12:05 +00:00
|
|
|
|
|
|
|
/* UE Radio Capability */
|
|
|
|
OCTET_STRING_t ueRadioCapability;
|
|
|
|
|
2021-02-17 17:19:20 +00:00
|
|
|
/* UEContextReleaseRequest or InitialContextSetupFailure */
|
|
|
|
struct {
|
|
|
|
NGAP_Cause_PR group;
|
|
|
|
long cause;
|
|
|
|
} deactivation;
|
|
|
|
|
2021-01-28 19:23:54 +00:00
|
|
|
/* Handover Info */
|
|
|
|
struct {
|
|
|
|
NGAP_HandoverType_t type;
|
|
|
|
OCTET_STRING_t container;
|
|
|
|
NGAP_Cause_PR group;
|
|
|
|
long cause;
|
|
|
|
} handover;
|
2020-06-04 18:12:05 +00:00
|
|
|
|
2020-06-22 03:07:14 +00:00
|
|
|
ogs_list_t sess_list;
|
2020-06-04 18:12:05 +00:00
|
|
|
};
|
|
|
|
|
|
|
|
typedef struct amf_sess_s {
|
2020-06-17 05:22:28 +00:00
|
|
|
ogs_sbi_object_t sbi;
|
|
|
|
|
|
|
|
uint8_t psi; /* PDU Session Identity */
|
|
|
|
uint8_t pti; /* Procedure Trasaction Identity */
|
2020-06-04 18:12:05 +00:00
|
|
|
|
2020-06-27 19:21:29 +00:00
|
|
|
#define SESSION_CONTEXT_IN_SMF(__sESS) \
|
|
|
|
((__sESS) && (__sESS)->sm_context_ref)
|
2020-07-29 02:35:43 +00:00
|
|
|
#define CLEAR_SM_CONTEXT_REF(__sESS) \
|
|
|
|
do { \
|
|
|
|
ogs_assert(__sESS); \
|
|
|
|
ogs_assert((__sESS)->sm_context_ref); \
|
|
|
|
ogs_free((__sESS)->sm_context_ref); \
|
|
|
|
(__sESS)->sm_context_ref = NULL; \
|
|
|
|
} while(0);
|
2020-06-17 05:22:28 +00:00
|
|
|
|
2020-08-03 03:22:41 +00:00
|
|
|
/* SMF sends the RESPONSE
|
|
|
|
* of [POST] /nsmf-pdusession/v1/sm-contexts */
|
|
|
|
char *sm_context_ref;
|
2020-06-22 03:07:14 +00:00
|
|
|
|
2020-08-03 03:22:41 +00:00
|
|
|
/* SMF sends the REQUEST
|
|
|
|
* of [POST] /namf-comm/v1/ue-contexts/{supi}/n1-n2-messages */
|
|
|
|
ogs_pkbuf_t *pdu_session_establishment_accept;
|
|
|
|
|
|
|
|
/*
|
|
|
|
* [AMF]
|
|
|
|
* 1. PDUSessionResourceReleaseResponse
|
|
|
|
* REQUEST [POST] /nsmf-pdusession/v1/sm-contexts/{smContextRef}/modify
|
|
|
|
* 2. PDU Session release complete
|
|
|
|
* REQUEST [POST] /nsmf-pdusession/v1/sm-contexts/{smContextRef}/modify
|
|
|
|
*
|
|
|
|
* [SMF]
|
|
|
|
* 1. RESPONSE /nsmf-pdusession/v1/sm-contexts/{smContextRef}/modify
|
|
|
|
* sess->n2_released = true;
|
|
|
|
*
|
|
|
|
* 2. RESPONSE /nsmf-pdusession/v1/sm-contexts/{smContextRef}/modify
|
|
|
|
* sess->n1_released = true;
|
|
|
|
*
|
|
|
|
* 3. NOTIFY /namf-callback/v1/{supi}/sm-context-status/{psi})
|
|
|
|
* sess->resource_status = OpenAPI_resource_status_RELEASED;
|
|
|
|
*
|
|
|
|
* if (sess->n1_released == true &&
|
|
|
|
* sess->n2_released == true &&
|
|
|
|
* sess->resource_status == OpenAPI_resource_status_RELEASED) {
|
|
|
|
*
|
|
|
|
* REMOVE_SESSION_CONTEXT()
|
|
|
|
* }
|
|
|
|
*/
|
2020-07-30 03:26:12 +00:00
|
|
|
OpenAPI_resource_status_e resource_status;
|
2020-08-03 03:22:41 +00:00
|
|
|
bool n1_released;
|
|
|
|
bool n2_released;
|
2020-06-22 03:07:14 +00:00
|
|
|
|
2021-01-04 04:29:01 +00:00
|
|
|
struct {
|
|
|
|
ogs_pkbuf_t *pdu_session_resource_setup_request;
|
|
|
|
ogs_pkbuf_t *path_switch_request_ack;
|
2021-01-28 19:23:54 +00:00
|
|
|
ogs_pkbuf_t *handover_request;
|
|
|
|
ogs_pkbuf_t *handover_command;
|
2021-01-04 04:29:01 +00:00
|
|
|
} transfer;
|
2021-01-18 16:48:35 +00:00
|
|
|
#define AMF_SESS_STORE_N2_TRANSFER(__sESS, __n2Type, __n2Buf) \
|
|
|
|
do { \
|
|
|
|
ogs_assert(__sESS); \
|
|
|
|
ogs_assert((__sESS)->amf_ue); \
|
|
|
|
if (sess->transfer.__n2Type) { \
|
|
|
|
ogs_warn("[%s:%d] N2 transfer message duplicated. Overwritten", \
|
|
|
|
((__sESS)->amf_ue)->supi, sess->psi); \
|
|
|
|
ogs_pkbuf_free(sess->transfer.__n2Type); \
|
|
|
|
} \
|
|
|
|
sess->transfer.__n2Type = __n2Buf; \
|
|
|
|
ogs_assert(sess->transfer.__n2Type); \
|
|
|
|
} while(0);
|
|
|
|
|
2021-01-28 19:23:54 +00:00
|
|
|
#define AMF_SESS_CLEAR_N2_TRANSFER(__sESS, __n2Type) \
|
|
|
|
do { \
|
|
|
|
if ((__sESS)->transfer.__n2Type) \
|
|
|
|
ogs_pkbuf_free((__sESS)->transfer.__n2Type); \
|
|
|
|
(__sESS)->transfer.__n2Type = NULL; \
|
|
|
|
} while(0);
|
|
|
|
|
2021-01-18 16:48:35 +00:00
|
|
|
#define AMF_UE_CLEAR_N2_TRANSFER(__aMF, __n2Type) \
|
|
|
|
do { \
|
|
|
|
amf_sess_t *sess = NULL; \
|
|
|
|
ogs_list_for_each(&((__aMF)->sess_list), sess) { \
|
2021-01-28 19:23:54 +00:00
|
|
|
AMF_SESS_CLEAR_N2_TRANSFER(sess, __n2Type) \
|
2021-01-18 16:48:35 +00:00
|
|
|
} \
|
|
|
|
} while(0);
|
|
|
|
|
|
|
|
struct {
|
|
|
|
/* Paging Ongoing */
|
|
|
|
bool ongoing;
|
|
|
|
/* Location in N1N2MessageTransferRspData */
|
|
|
|
char *location;
|
|
|
|
/* last Received n1-n2-trasfer-failure-notification-uri from SMF */
|
|
|
|
char *n1n2_failure_txf_notif_uri;
|
|
|
|
/* notification client */
|
|
|
|
ogs_sbi_client_t *client;
|
|
|
|
} paging;
|
|
|
|
#define AMF_SESS_STORE_PAGING_INFO(__sESS, __lOCATION, __uRI) \
|
|
|
|
do { \
|
|
|
|
ogs_assert(__sESS); \
|
|
|
|
ogs_assert(__lOCATION); \
|
|
|
|
ogs_assert(__uRI); \
|
|
|
|
AMF_SESS_CLEAR_PAGING_INFO(__sESS) \
|
|
|
|
(__sESS)->paging.ongoing = true; \
|
|
|
|
((__sESS)->paging.location) = ogs_strdup(__lOCATION); \
|
|
|
|
((__sESS)->paging.n1n2_failure_txf_notif_uri) = ogs_strdup(__uRI); \
|
|
|
|
} while(0);
|
|
|
|
#define AMF_SESS_CLEAR_PAGING_INFO(__sESS) \
|
|
|
|
do { \
|
|
|
|
if ((__sESS)->paging.ongoing == true) { \
|
|
|
|
ogs_assert((__sESS)->paging.location); \
|
|
|
|
ogs_free((__sESS)->paging.location); \
|
|
|
|
((__sESS)->paging.location) = NULL; \
|
|
|
|
ogs_assert((__sESS)->paging.n1n2_failure_txf_notif_uri); \
|
|
|
|
ogs_free((__sESS)->paging.n1n2_failure_txf_notif_uri); \
|
|
|
|
((__sESS)->paging.n1n2_failure_txf_notif_uri) = NULL; \
|
|
|
|
((__sESS)->paging.ongoing) = false; \
|
|
|
|
} \
|
|
|
|
} while(0);
|
|
|
|
#define AMF_UE_CLEAR_PAGING_INFO(__aMF) \
|
|
|
|
do { \
|
|
|
|
amf_sess_t *sess = NULL; \
|
|
|
|
ogs_list_for_each(&((__aMF)->sess_list), sess) { \
|
|
|
|
AMF_SESS_CLEAR_PAGING_INFO(sess); \
|
|
|
|
} \
|
|
|
|
} while(0);
|
2020-06-22 03:07:14 +00:00
|
|
|
|
2021-03-08 12:25:09 +00:00
|
|
|
struct {
|
|
|
|
char *nsi_id;
|
|
|
|
struct {
|
|
|
|
char *id;
|
|
|
|
ogs_sbi_client_t *client;
|
|
|
|
} nrf;
|
|
|
|
} nssf;
|
|
|
|
|
2020-06-17 05:22:28 +00:00
|
|
|
/* last payload for sending back to the UE */
|
|
|
|
uint8_t payload_container_type;
|
|
|
|
ogs_pkbuf_t *payload_container;
|
2020-06-04 18:12:05 +00:00
|
|
|
|
|
|
|
/* amf_bearer_first(sess) : Default Bearer Context */
|
|
|
|
ogs_list_t bearer_list;
|
|
|
|
|
|
|
|
/* Related Context */
|
|
|
|
amf_ue_t *amf_ue;
|
|
|
|
|
2021-03-08 12:25:09 +00:00
|
|
|
ogs_s_nssai_t s_nssai;
|
|
|
|
ogs_s_nssai_t mapped_hplmn;
|
|
|
|
char *dnn;
|
2020-06-04 18:12:05 +00:00
|
|
|
|
|
|
|
/* Save Protocol Configuration Options from UE */
|
|
|
|
struct {
|
|
|
|
uint8_t length;
|
|
|
|
uint8_t *buffer;
|
|
|
|
} ue_pco;
|
|
|
|
|
|
|
|
/* Save Protocol Configuration Options from PGW */
|
|
|
|
ogs_tlv_octet_t pgw_pco;
|
2021-01-18 16:48:35 +00:00
|
|
|
|
2020-06-04 18:12:05 +00:00
|
|
|
} amf_sess_t;
|
|
|
|
|
2020-05-25 16:15:22 +00:00
|
|
|
void amf_context_init(void);
|
|
|
|
void amf_context_final(void);
|
|
|
|
amf_context_t *amf_self(void);
|
|
|
|
|
|
|
|
int amf_context_parse_config(void);
|
|
|
|
|
|
|
|
amf_gnb_t *amf_gnb_add(ogs_sock_t *sock, ogs_sockaddr_t *addr);
|
2021-03-08 12:25:09 +00:00
|
|
|
void amf_gnb_remove(amf_gnb_t *gnb);
|
|
|
|
void amf_gnb_remove_all(void);
|
2020-05-25 16:15:22 +00:00
|
|
|
amf_gnb_t *amf_gnb_find_by_addr(ogs_sockaddr_t *addr);
|
|
|
|
amf_gnb_t *amf_gnb_find_by_gnb_id(uint32_t gnb_id);
|
|
|
|
int amf_gnb_set_gnb_id(amf_gnb_t *gnb, uint32_t gnb_id);
|
|
|
|
int amf_gnb_sock_type(ogs_sock_t *sock);
|
|
|
|
|
2020-06-04 18:12:05 +00:00
|
|
|
ran_ue_t *ran_ue_add(amf_gnb_t *gnb, uint32_t ran_ue_ngap_id);
|
|
|
|
void ran_ue_remove(ran_ue_t *ran_ue);
|
|
|
|
void ran_ue_switch_to_gnb(ran_ue_t *ran_ue, amf_gnb_t *new_gnb);
|
|
|
|
ran_ue_t *ran_ue_find_by_ran_ue_ngap_id(
|
|
|
|
amf_gnb_t *gnb, uint32_t ran_ue_ngap_id);
|
2020-08-30 03:27:54 +00:00
|
|
|
ran_ue_t *ran_ue_find(uint32_t index);
|
2020-06-04 18:12:05 +00:00
|
|
|
ran_ue_t *ran_ue_find_by_amf_ue_ngap_id(uint64_t amf_ue_ngap_id);
|
2020-10-29 02:59:27 +00:00
|
|
|
ran_ue_t *ran_ue_cycle(ran_ue_t *ran_ue);
|
2020-06-04 18:12:05 +00:00
|
|
|
|
2021-03-09 05:28:07 +00:00
|
|
|
void amf_ue_new_guti(amf_ue_t *amf_ue);
|
|
|
|
|
2020-06-04 18:12:05 +00:00
|
|
|
amf_ue_t *amf_ue_add(ran_ue_t *ran_ue);
|
|
|
|
void amf_ue_remove(amf_ue_t *amf_ue);
|
|
|
|
void amf_ue_remove_all(void);
|
|
|
|
|
2020-09-21 18:37:17 +00:00
|
|
|
void amf_ue_fsm_init(amf_ue_t *amf_ue);
|
|
|
|
void amf_ue_fsm_fini(amf_ue_t *amf_ue);
|
|
|
|
|
2020-06-04 18:12:05 +00:00
|
|
|
amf_ue_t *amf_ue_find_by_guti(ogs_nas_5gs_guti_t *nas_guti);
|
|
|
|
amf_ue_t *amf_ue_find_by_teid(uint32_t teid);
|
|
|
|
amf_ue_t *amf_ue_find_by_suci(char *suci);
|
|
|
|
amf_ue_t *amf_ue_find_by_supi(char *supi);
|
|
|
|
|
|
|
|
amf_ue_t *amf_ue_find_by_message(ogs_nas_5gs_message_t *message);
|
|
|
|
void amf_ue_set_suci(amf_ue_t *amf_ue,
|
|
|
|
ogs_nas_5gs_mobile_identity_t *mobile_identity);
|
|
|
|
void amf_ue_set_supi(amf_ue_t *amf_ue, char *supi);
|
|
|
|
|
2020-12-11 19:03:20 +00:00
|
|
|
OpenAPI_rat_type_e amf_ue_rat_type(amf_ue_t *amf_ue);
|
2020-06-04 18:12:05 +00:00
|
|
|
|
|
|
|
/*
|
|
|
|
* o RECV Initial UE-Message : S-TMSI
|
|
|
|
* o RECV Attach Request : IMSI, GUTI
|
|
|
|
* o RECV TAU Request : GUTI
|
|
|
|
* ### AMF_UE_ASSOCIATE_GNB_UE() ###
|
|
|
|
* ### AMF_UE_ECM_CONNECTED() ###
|
|
|
|
*
|
|
|
|
* o RECV Initial Context Setup Failure in EMM Registered State
|
|
|
|
* ### AMF_UE_DEASSOCIATE_GNB_UE() ###
|
|
|
|
* ### GNB_UE_REMOVE() ###
|
|
|
|
* ### AMF_UE_DEASSOCIATE() ###
|
|
|
|
*
|
|
|
|
* o SEND UE Context Release Command with NO_ACTION
|
|
|
|
* - RECV UE Context Release Complete
|
|
|
|
* ### GNB_UE_REMOVE() ###
|
|
|
|
* ### AMF_UE_DEASSOCIATE() ###
|
|
|
|
*
|
|
|
|
* o SEND UE Context Release Command with REMOVE_AMF_UE_CONTEXT
|
|
|
|
* - RECV UE Context Release Complete
|
|
|
|
* ### GNB_UE_REMOVE() ###
|
|
|
|
* ### AMF_UE_REMOVE() ###
|
|
|
|
*
|
|
|
|
*
|
|
|
|
* o RECV Handover Required
|
|
|
|
* ### SOURCE_UE_ASSOCIATE_TARGET_UE() ####
|
|
|
|
* - SEND Handover Request
|
|
|
|
*
|
|
|
|
* o RECV Handover Notify
|
|
|
|
* ### AMF_UE_ASSOCIATE_GNB_UE(TARGET) ###
|
|
|
|
* ### AMF_UE_ECM_CONNECTED(TARGET) ###
|
|
|
|
* - Modify Bearer Request/Response
|
|
|
|
* - UE Context Release Command/Complete
|
|
|
|
* ### SOURCE_UE_DEASSOCIATE_TARGET_UE() ####
|
|
|
|
* ### GNB_UE_REMOVE() ####
|
|
|
|
* - Delete Indirect Data Forwarding Tunnel Request/Response
|
|
|
|
*
|
|
|
|
* o RECV Handover Cancel
|
|
|
|
* - UE Context Release Command/Complete
|
|
|
|
* ### SOURCE_UE_DEASSOCIATE_TARGET_UE() ####
|
|
|
|
* ### GNB_UE_REMOVE() ####
|
|
|
|
* - Delete Indirect Data Forwarding Tunnel Request/Response
|
|
|
|
*
|
|
|
|
* o RECV Handover Failure
|
|
|
|
* - UE Context Release Command/Complete
|
|
|
|
* ### SOURCE_UE_DEASSOCIATE_TARGET_UE() ####
|
|
|
|
* ### GNB_UE_REMOVE() ####
|
|
|
|
* - Delete Indirect Data Forwarding Tunnel Request/Response
|
|
|
|
*/
|
|
|
|
void amf_ue_associate_ran_ue(amf_ue_t *amf_ue, ran_ue_t *ran_ue);
|
|
|
|
void ran_ue_deassociate(ran_ue_t *ran_ue);
|
|
|
|
void amf_ue_deassociate(amf_ue_t *amf_ue);
|
|
|
|
void source_ue_associate_target_ue(ran_ue_t *source_ue, ran_ue_t *target_ue);
|
|
|
|
void source_ue_deassociate_target_ue(ran_ue_t *ran_ue);
|
|
|
|
|
2020-06-17 05:22:28 +00:00
|
|
|
amf_sess_t *amf_sess_add(amf_ue_t *amf_ue, uint8_t psi);
|
2020-06-04 18:12:05 +00:00
|
|
|
void amf_sess_remove(amf_sess_t *sess);
|
|
|
|
void amf_sess_remove_all(amf_ue_t *amf_ue);
|
2020-06-17 05:22:28 +00:00
|
|
|
amf_sess_t *amf_sess_find_by_psi(amf_ue_t *amf_ue, uint8_t psi);
|
2020-06-04 18:12:05 +00:00
|
|
|
amf_sess_t *amf_sess_find_by_dnn(amf_ue_t *amf_ue, char *dnn);
|
|
|
|
|
2020-07-30 03:26:12 +00:00
|
|
|
amf_ue_t *amf_ue_cycle(amf_ue_t *amf_ue);
|
|
|
|
amf_sess_t *amf_sess_cycle(amf_sess_t *sess);
|
|
|
|
|
2021-03-08 12:25:09 +00:00
|
|
|
void amf_ue_select_nf(amf_ue_t *amf_ue, OpenAPI_nf_type_e nf_type);
|
|
|
|
void amf_sess_select_nf(amf_sess_t *sess, OpenAPI_nf_type_e nf_type);
|
|
|
|
|
|
|
|
void amf_sess_select_smf(amf_sess_t *sess);
|
|
|
|
|
2021-01-18 16:48:35 +00:00
|
|
|
#define SESSION_SYNC_DONE(__aMF, __sTATE) \
|
|
|
|
(amf_sess_xact_state_count(__aMF, __sTATE) == 0)
|
2020-08-03 03:22:41 +00:00
|
|
|
int amf_sess_xact_count(amf_ue_t *amf_ue);
|
2021-01-18 16:48:35 +00:00
|
|
|
int amf_sess_xact_state_count(amf_ue_t *amf_ue, int state);
|
2020-06-25 04:37:29 +00:00
|
|
|
|
2021-01-18 16:48:35 +00:00
|
|
|
#define PDU_RES_SETUP_REQ_TRANSFER_NEEDED(__aMF) \
|
|
|
|
(amf_pdu_res_setup_req_transfer_needed(__aMF) == true)
|
|
|
|
bool amf_pdu_res_setup_req_transfer_needed(amf_ue_t *amf_ue);
|
2021-01-08 03:26:06 +00:00
|
|
|
|
2021-03-08 12:25:09 +00:00
|
|
|
int amf_find_served_tai(ogs_5gs_tai_t *nr_tai);
|
2020-06-17 05:22:28 +00:00
|
|
|
ogs_s_nssai_t *amf_find_s_nssai(
|
2020-06-23 04:35:41 +00:00
|
|
|
ogs_plmn_id_t *served_plmn_id, ogs_s_nssai_t *s_nssai);
|
2020-05-25 16:15:22 +00:00
|
|
|
|
|
|
|
int amf_m_tmsi_pool_generate(void);
|
|
|
|
amf_m_tmsi_t *amf_m_tmsi_alloc(void);
|
|
|
|
int amf_m_tmsi_free(amf_m_tmsi_t *tmsi);
|
|
|
|
|
|
|
|
uint8_t amf_selected_int_algorithm(amf_ue_t *amf_ue);
|
|
|
|
uint8_t amf_selected_enc_algorithm(amf_ue_t *amf_ue);
|
|
|
|
|
2021-03-08 12:25:09 +00:00
|
|
|
void amf_clear_subscribed_info(amf_ue_t *amf_ue);
|
|
|
|
|
2021-04-03 05:07:44 +00:00
|
|
|
void amf_update_allowed_nssai(amf_ue_t *amf_ue);
|
|
|
|
|
2020-05-25 16:15:22 +00:00
|
|
|
#ifdef __cplusplus
|
|
|
|
}
|
|
|
|
#endif
|
|
|
|
|
|
|
|
#endif /* AMF_CONTEXT_H */
|