Commit ea9769b8 authored by Tien-Thinh Nguyen's avatar Tien-Thinh Nguyen

Merge branch 'dsTest' into amf_bupt

parents c8d54a02 c5c7dad2
......@@ -5,15 +5,16 @@ AMF =
PID_DIRECTORY = "/var/run";
######################################################################## NG SETUP RESPONSE IEs ############################################################
AMF_NAME = "bupt-amf";
GUAMI:{MCC = "460"; MNC = "11"; RegionID = "128"; AMFSetID = "4"; AMFPointer = "1"}
GUAMI:{MCC = "208"; MNC = "95"; RegionID = "128"; AMFSetID = "1"; AMFPointer = "1"}
ServedGUAMIList = (
{MCC = "460"; MNC = "11"; RegionID = "10"; AMFSetID = "1"; AMFPointer = "0"}, #48bits <MCC><MNC><RegionID><AMFSetID><AMFPointer>
{MCC = "208"; MNC = "95"; RegionID = "10"; AMFSetID = "1"; AMFPointer = "0"}, #48bits <MCC><MNC><RegionID><AMFSetID><AMFPointer>
{MCC = "460"; MNC = "11"; RegionID = "10"; AMFSetID = "1"; AMFPointer = "1"} #48bits <MCC><MNC><RegionID><AMFSetID><AMFPointer>
);
RelativeAMFCapacity = 30;
PLMNSupportList = (
{MCC = "460"; MNC = "11"; TAC = 100;
{MCC = "208"; MNC = "95"; TAC = 0xa000;
SliceSupportList = (
{SST = "222"; SD = "123"},
{SST = "1"; SD = "none"},
{SST = "1"; SD = "12"}
)
......@@ -23,14 +24,14 @@ AMF =
STATISTICS_TIMER_INTERVAL = 20; #second
INTERFACES:{
NGAP_AMF:{
INTERFACE_NAME = "ens33";
INTERFACE_NAME = "ens3";
IPV4_ADDRESS = "read";
SCTP_PORT = 38412;
PPID = 60;
};
N11:{
SMF_INSTANCES_POOL = (
{SMF_INSTANCE_ID = 1; IPV4_ADDRESS = "192.168.2.189"; PORT = "8889"; VERSION = "v1"; SELECTED = "true"},
{SMF_INSTANCE_ID = 1; IPV4_ADDRESS = "192.168.122.168"; PORT = "80"; VERSION = "v2"; SELECTED = "true"},
{SMF_INSTANCE_ID = 2; IPV4_ADDRESS = "10.103.238.21"; PORT = "8181"; VERSION = "v1"; SELECTED = "false"}
);
};
......@@ -40,15 +41,16 @@ AMF =
};
AUTHENTICATION:{
MYSQL_server = "127.0.0.1";
MYSQL_user = "bupt"; # Database server login
MYSQL_user = "root"; # Database server login
MYSQL_pass = "linux"; # Database server password
MYSQL_db = "OAI_DB";
OPERATOR_key = "1006020f0a478bf6b699f15c062e42b3"; # op
MYSQL_db = "oai_db";
OPERATOR_key = "63bfa50ee6523365ff14c1f45f88737d"; # op 0x63bfa50ee6523365ff14c1f45f88737d
#Key: 0x0C0A34601D4F07677303652C0462535B
RANDOM = "true";
};
NAS:{
#ORDERED_SUPPORTED_INTEGRITY_ALGORITHM_LIST = [ "NIA2" , "NIA1" , "NIA0" ];
ORDERED_SUPPORTED_INTEGRITY_ALGORITHM_LIST = [ "NIA1" , "NIA1" , "NIA1" ];
ORDERED_SUPPORTED_INTEGRITY_ALGORITHM_LIST = [ "NIA0" , "NIA1" , "NIA1" ];
ORDERED_SUPPORTED_CIPHERING_ALGORITHM_LIST = [ "NEA0" , "NEA1" , "NEA2" ];
#ORDERED_SUPPORTED_CIPHERING_ALGORITHM_LIST = [ "NEA1" , "NEA1" , "NEA1" ];
};
......
......@@ -177,13 +177,13 @@ void amf_n11::handle_pdu_session_initial_request(string supi, std::shared_ptr<pd
pdu_session_establishment_request["pei"] = "imei-200000000000001";
pdu_session_establishment_request["gpsi"] = "msisdn-200000000001";
pdu_session_establishment_request["dnn"] = "carrier.com";
pdu_session_establishment_request["sNssai"]["sst"] = 0;
pdu_session_establishment_request["sNssai"]["sd"] = "0";
pdu_session_establishment_request["sNssai"]["sst"] = 222;
pdu_session_establishment_request["sNssai"]["sd"] = "123";
pdu_session_establishment_request["pduSessionId"] = psc.get()->pdu_session_id;
pdu_session_establishment_request["requestType"] = "INITIAL_REQUEST";
pdu_session_establishment_request["servingNfId"] = "servingNfId";
pdu_session_establishment_request["servingNetwork"]["mcc"] = "460";
pdu_session_establishment_request["servingNetwork"]["mnc"] = "011";
pdu_session_establishment_request["servingNetwork"]["mcc"] = "208";
pdu_session_establishment_request["servingNetwork"]["mnc"] = "95";
pdu_session_establishment_request["anType"] = "3GPP_ACCESS";
pdu_session_establishment_request["smContextStatusUri"] = "smContextStatusUri";
......@@ -271,7 +271,7 @@ void amf_n11::curl_http_client(string remoteUri, string jsonData, string n1SmMsg
if(n1SmMsg != ""){
Logger::amf_n11().debug("is there ok? n1");
unsigned char *n1_msg_hex = format_string_as_hex(n1SmMsg);
Logger::amf_n11().debug("n1 msg hex: %s", n1_msg_hex);
//Logger::amf_n11().debug("n1 msg hex: %s", n1_msg_hex);
part = curl_mime_addpart(mime);
curl_mime_data(part, reinterpret_cast<const char*>(n1_msg_hex), n1SmMsg.length()/2);
curl_mime_type(part, "application/vnd.3gpp.5gnas");
......
......@@ -123,7 +123,9 @@ void RegistrationRequest::set5G_MM_capability(uint8_t value){
ie_5g_mm_capability = new _5GMMCapability(0x10,value);
}
uint8_t RegistrationRequest::get5GMMCapability(){
if (ie_5g_mm_capability != nullptr)
return ie_5g_mm_capability->getValue();
else return -1;
}
void RegistrationRequest::setUE_Security_Capability(uint8_t g_EASel, uint8_t g_IASel) {
ie_ue_security_capability = new UESecurityCapability(0x2E, g_EASel, g_IASel);
......
......@@ -128,7 +128,7 @@ int ngap_amf_handle_ue_context_release_complete(const sctp_assoc_id_t assoc_id,
int ngap_amf_handle_pdu_session_resource_setup_response(const sctp_assoc_id_t assoc_id, const sctp_stream_id_t stream, struct Ngap_NGAP_PDU *message_p){
Logger::ngap().debug("sending itti pdu_session_resource_setup_response to TASK_AMF_N2");
#if 0
#if 1
PduSessionResourceSetupResponseMsg * pduresp = new PduSessionResourceSetupResponseMsg();
if(!pduresp->decodefrompdu(message_p)){
Logger::ngap().error("decoding PduSessionResourceSetupResponseMsg message error");
......
Markdown is supported
0%
or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment