Skip to content
Projects
Groups
Snippets
Help
Loading...
Help
Support
Keyboard shortcuts
?
Submit feedback
Contribute to GitLab
Sign in / Register
Toggle navigation
O
OpenXG-AMF-Simple
Project overview
Project overview
Details
Activity
Releases
Repository
Repository
Files
Commits
Branches
Tags
Contributors
Graph
Compare
Issues
0
Issues
0
List
Boards
Labels
Milestones
Merge Requests
0
Merge Requests
0
CI / CD
CI / CD
Pipelines
Jobs
Schedules
Operations
Operations
Metrics
Environments
Analytics
Analytics
CI / CD
Repository
Value Stream
Wiki
Wiki
Snippets
Snippets
Members
Members
Collapse sidebar
Close sidebar
Activity
Graph
Create a new issue
Jobs
Commits
Issue Boards
Open sidebar
CommunityXG
OpenXG-AMF-Simple
Commits
914629c8
Commit
914629c8
authored
Sep 14, 2020
by
Tien-Thinh Nguyen
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
Polish header files/code cleanup
parent
3f35b76e
Changes
14
Hide whitespace changes
Inline
Side-by-side
Showing
14 changed files
with
13 additions
and
45 deletions
+13
-45
src/amf-app/amf_app.hpp
src/amf-app/amf_app.hpp
+0
-3
src/amf-app/amf_config.cpp
src/amf-app/amf_config.cpp
+4
-2
src/amf-app/amf_config.hpp
src/amf-app/amf_config.hpp
+0
-5
src/amf-app/amf_module_from_config.hpp
src/amf-app/amf_module_from_config.hpp
+0
-7
src/amf-app/amf_n1.hpp
src/amf-app/amf_n1.hpp
+0
-7
src/amf-app/amf_statistics.cpp
src/amf-app/amf_statistics.cpp
+0
-2
src/amf-app/amf_statistics.hpp
src/amf-app/amf_statistics.hpp
+0
-3
src/amf-app/mysql_db.hpp
src/amf-app/mysql_db.hpp
+0
-2
src/nas/msgs/RegistrationRequest.hpp
src/nas/msgs/RegistrationRequest.hpp
+6
-6
src/nas/msgs/ServiceRequest.hpp
src/nas/msgs/ServiceRequest.hpp
+2
-2
src/nas/utils/TLVEncoder.c
src/nas/utils/TLVEncoder.c
+0
-1
src/ngap/ngapMsgs/InitialUEMessage.cpp
src/ngap/ngapMsgs/InitialUEMessage.cpp
+0
-3
src/ngap/ngapMsgs/NGSetupResponse.hpp
src/ngap/ngapMsgs/NGSetupResponse.hpp
+1
-1
src/ngap/ngap_app/ngap_message_callback.hpp
src/ngap/ngap_app/ngap_message_callback.hpp
+0
-1
No files found.
src/amf-app/amf_app.hpp
View file @
914629c8
...
@@ -30,11 +30,8 @@
...
@@ -30,11 +30,8 @@
#define _AMF_APP_H_
#define _AMF_APP_H_
#include <map>
#include <map>
#include <set>
#include <shared_mutex>
#include <shared_mutex>
#include <string>
#include <string>
#include <thread>
#include <sstream>
#include "amf_config.hpp"
#include "amf_config.hpp"
#include "amf_module_from_config.hpp"
#include "amf_module_from_config.hpp"
#include "itti_msg_amf_app.hpp"
#include "itti_msg_amf_app.hpp"
...
...
src/amf-app/amf_config.cpp
View file @
914629c8
...
@@ -33,6 +33,10 @@
...
@@ -33,6 +33,10 @@
#include "string.hpp"
#include "string.hpp"
#include "thread_sched.hpp"
#include "thread_sched.hpp"
#include <boost/algorithm/string.hpp>
#include <boost/algorithm/string/classification.hpp>
#include <boost/algorithm/string/split.hpp>
#include "logger.hpp"
#include "logger.hpp"
#include "amf_app.hpp"
#include "amf_app.hpp"
#include "if.hpp"
#include "if.hpp"
...
@@ -41,10 +45,8 @@
...
@@ -41,10 +45,8 @@
extern
"C"
{
extern
"C"
{
#include <arpa/inet.h>
#include <arpa/inet.h>
#include <stdbool.h>
#include <stdbool.h>
#include <stdlib.h>
#include <string.h>
#include <string.h>
#include <sys/types.h>
#include <sys/types.h>
#include <unistd.h>
#include "common_defs.h"
#include "common_defs.h"
}
}
...
...
src/amf-app/amf_config.hpp
View file @
914629c8
...
@@ -35,15 +35,10 @@
...
@@ -35,15 +35,10 @@
#include <libconfig.h++>
#include <libconfig.h++>
#include <netinet/in.h>
#include <netinet/in.h>
#include <sys/socket.h>
#include <sys/socket.h>
#include <mutex>
#include <vector>
#include <vector>
#include <string>
#include <string>
#include "thread_sched.hpp"
#include "thread_sched.hpp"
#include <boost/algorithm/string.hpp>
#include <boost/algorithm/string/classification.hpp>
#include <boost/algorithm/string/split.hpp>
#define AMF_CONFIG_STRING_AMF_CONFIG "AMF"
#define AMF_CONFIG_STRING_AMF_CONFIG "AMF"
#define AMF_CONFIG_STRING_PID_DIRECTORY "PID_DIRECTORY"
#define AMF_CONFIG_STRING_PID_DIRECTORY "PID_DIRECTORY"
#define AMF_CONFIG_STRING_INSTANCE_ID "INSTANCE_ID"
#define AMF_CONFIG_STRING_INSTANCE_ID "INSTANCE_ID"
...
...
src/amf-app/amf_module_from_config.hpp
View file @
914629c8
...
@@ -29,14 +29,7 @@
...
@@ -29,14 +29,7 @@
#ifndef _AMF_MODULE_FROM_CONFIG_H_
#ifndef _AMF_MODULE_FROM_CONFIG_H_
#define _AMF_MODULE_FROM_CONFIG_H_
#define _AMF_MODULE_FROM_CONFIG_H_
#include <arpa/inet.h>
#include <libconfig.h++>
#include <libconfig.h++>
#include <netinet/in.h>
#include <sys/socket.h>
#include <mutex>
#include <vector>
#include <boost/algorithm/string.hpp>
#include <boost/algorithm/string.hpp>
#include <boost/algorithm/string/classification.hpp>
#include <boost/algorithm/string/classification.hpp>
#include <boost/algorithm/string/split.hpp>
#include <boost/algorithm/string/split.hpp>
...
...
src/amf-app/amf_n1.hpp
View file @
914629c8
...
@@ -31,15 +31,8 @@
...
@@ -31,15 +31,8 @@
#include <map>
#include <map>
#include <shared_mutex>
#include <shared_mutex>
#include <pthread.h>
#include <stdlib.h>
#include <stdlib.h>
#include <stdio.h>
#include <stdint.h>
#include <unistd.h>
#include <string.h>
#include <string.h>
#include <errno.h>
#include <error.h>
#include <inttypes.h>
#include <mysql/mysql.h>
#include <mysql/mysql.h>
#include "nas_context.hpp"
#include "nas_context.hpp"
...
...
src/amf-app/amf_statistics.cpp
View file @
914629c8
...
@@ -28,8 +28,6 @@
...
@@ -28,8 +28,6 @@
#include "amf_statistics.hpp"
#include "amf_statistics.hpp"
#include <iostream>
#include "logger.hpp"
#include "logger.hpp"
//------------------------------------------------------------------------------
//------------------------------------------------------------------------------
...
...
src/amf-app/amf_statistics.hpp
View file @
914629c8
...
@@ -29,9 +29,6 @@
...
@@ -29,9 +29,6 @@
#ifndef _STATISTICS_H_
#ifndef _STATISTICS_H_
#define _STATISTICS_H_
#define _STATISTICS_H_
#include <stdlib.h>
#include <unistd.h>
#include <stdint.h>
#include <vector>
#include <vector>
#include <string>
#include <string>
...
...
src/amf-app/mysql_db.hpp
View file @
914629c8
...
@@ -29,10 +29,8 @@
...
@@ -29,10 +29,8 @@
#ifndef _MYSQL_DB_HANDLERS_H_
#ifndef _MYSQL_DB_HANDLERS_H_
#define _MYSQL_DB_HANDLERS_H_
#define _MYSQL_DB_HANDLERS_H_
#include <stdint.h>
#include <pthread.h>
#include <pthread.h>
#include <mysql/mysql.h>
#include <mysql/mysql.h>
#include <netinet/in.h>
#include <string>
#include <string>
#define KEY_LENGTH (16)
#define KEY_LENGTH (16)
...
...
src/nas/msgs/RegistrationRequest.hpp
View file @
914629c8
...
@@ -92,17 +92,17 @@ class RegistrationRequest {
...
@@ -92,17 +92,17 @@ class RegistrationRequest {
void
setNAS_Message_Container
(
bstring
value
);
void
setNAS_Message_Container
(
bstring
value
);
void
setEPS_Bearer_Context_Status
(
uint16_t
value
);
void
setEPS_Bearer_Context_Status
(
uint16_t
value
);
bool
get5GSRegistrationType
(
bool
&
is_for
,
uint8_t
&
reg_type
/*3bits*/
);
//返回获取IE的状态,成功或者失败
bool
get5GSRegistrationType
(
bool
&
is_for
,
uint8_t
&
reg_type
/*3bits*/
);
uint8_t
getngKSI
();
//return -1;表示获取IE失败
uint8_t
getngKSI
();
uint8_t
getMobilityIdentityType
();
//return -1;表示获取IE失败
uint8_t
getMobilityIdentityType
();
std
::
string
get_5g_guti
();
//"error" for missing IE GUTI
std
::
string
get_5g_guti
();
//"error" for missing IE GUTI
bool
getSuciSupiFormatImsi
(
nas
::
SUCI_imsi_t
&
imsi
);
bool
getSuciSupiFormatImsi
(
nas
::
SUCI_imsi_t
&
imsi
);
uint8_t
getNonCurrentNativeNasKSI
();
//return -1;表示获取IE失败
uint8_t
getNonCurrentNativeNasKSI
();
uint8_t
get5GMMCapability
();
//return -1;表示获取IE失败; set接口可能有bug
uint8_t
get5GMMCapability
();
bool
getUeSecurityCapability
(
uint8_t
&
ea
,
uint8_t
&
ia
);
bool
getUeSecurityCapability
(
uint8_t
&
ea
,
uint8_t
&
ia
);
bool
getRequestedNssai
(
std
::
vector
<
struct
SNSSAI_s
>
&
nssai
);
bool
getRequestedNssai
(
std
::
vector
<
struct
SNSSAI_s
>
&
nssai
);
bool
getS1UeNetworkCapability
(
uint8_t
&
eea
,
uint8_t
&
eia
);
bool
getS1UeNetworkCapability
(
uint8_t
&
eea
,
uint8_t
&
eia
);
uint16_t
getUplinkDataStatus
();
//return -1;表示获取IE失败;
uint16_t
getUplinkDataStatus
();
uint16_t
getPduSessionStatus
();
uint16_t
getPduSessionStatus
();
bool
getMicoIndication
(
uint8_t
&
sprti
,
uint8_t
&
raai
);
bool
getMicoIndication
(
uint8_t
&
sprti
,
uint8_t
&
raai
);
bool
getUeStatus
(
uint8_t
&
n1ModeReg
,
uint8_t
&
s1ModeReg
);
bool
getUeStatus
(
uint8_t
&
n1ModeReg
,
uint8_t
&
s1ModeReg
);
...
...
src/nas/msgs/ServiceRequest.hpp
View file @
914629c8
...
@@ -53,10 +53,10 @@ class ServiceRequest {
...
@@ -53,10 +53,10 @@ class ServiceRequest {
int
encode2buffer
(
uint8_t
*
buf
,
int
len
);
int
encode2buffer
(
uint8_t
*
buf
,
int
len
);
public:
public:
int
decodefrombuffer
(
NasMmPlainHeader
*
header
,
uint8_t
*
buf
,
int
len
);
int
decodefrombuffer
(
NasMmPlainHeader
*
header
,
uint8_t
*
buf
,
int
len
);
uint8_t
getngKSI
();
//return -1;表示获取IE失败
uint8_t
getngKSI
();
uint8_t
getServiceType
();
uint8_t
getServiceType
();
bool
get5G_S_TMSI
(
uint16_t
&
amfSetId
,
uint8_t
&
amfPointer
,
string
&
tmsi
);
bool
get5G_S_TMSI
(
uint16_t
&
amfSetId
,
uint8_t
&
amfPointer
,
string
&
tmsi
);
uint16_t
getUplinkDataStatus
();
//return -1;表示获取IE失败;
uint16_t
getUplinkDataStatus
();
uint16_t
getPduSessionStatus
();
uint16_t
getPduSessionStatus
();
uint16_t
getAllowedPduSessionStatus
();
uint16_t
getAllowedPduSessionStatus
();
bool
getNasMessageContainer
(
bstring
&
nas
);
bool
getNasMessageContainer
(
bstring
&
nas
);
...
...
src/nas/utils/TLVEncoder.c
View file @
914629c8
...
@@ -31,7 +31,6 @@
...
@@ -31,7 +31,6 @@
#include <stdbool.h>
#include <stdbool.h>
#include "TLVEncoder.h"
#include "TLVEncoder.h"
//#include "log.h"
int
errorCodeEncoder
=
0
;
int
errorCodeEncoder
=
0
;
...
...
src/ngap/ngapMsgs/InitialUEMessage.cpp
View file @
914629c8
...
@@ -245,9 +245,6 @@ bool InitialUEMessageMsg::decodefrompdu(Ngap_NGAP_PDU_t *ngap_msg_pdu) {
...
@@ -245,9 +245,6 @@ bool InitialUEMessageMsg::decodefrompdu(Ngap_NGAP_PDU_t *ngap_msg_pdu) {
initialUEMessagePdu
=
ngap_msg_pdu
;
initialUEMessagePdu
=
ngap_msg_pdu
;
if
(
initialUEMessagePdu
->
present
==
Ngap_NGAP_PDU_PR_initiatingMessage
)
{
if
(
initialUEMessagePdu
->
present
==
Ngap_NGAP_PDU_PR_initiatingMessage
)
{
//cout<<"test0515: procedureCode "<<initialUEMessagePdu->choice.initiatingMessage->procedureCode<<endl;
//cout<<"test0515: criticality "<<initialUEMessagePdu->choice.initiatingMessage->criticality<<endl;
//cout<<"test0515: present "<<initialUEMessagePdu->choice.initiatingMessage->value.present<<endl;
if
(
initialUEMessagePdu
->
choice
.
initiatingMessage
if
(
initialUEMessagePdu
->
choice
.
initiatingMessage
&&
initialUEMessagePdu
->
choice
.
initiatingMessage
->
procedureCode
&&
initialUEMessagePdu
->
choice
.
initiatingMessage
->
procedureCode
==
Ngap_ProcedureCode_id_InitialUEMessage
==
Ngap_ProcedureCode_id_InitialUEMessage
...
...
src/ngap/ngapMsgs/NGSetupResponse.hpp
View file @
914629c8
...
@@ -54,7 +54,7 @@ class NGSetupResponseMsg {
...
@@ -54,7 +54,7 @@ class NGSetupResponseMsg {
//External interfaces
//External interfaces
//Encapsulation
//Encapsulation
void
setMessageType
();
//Initialize the PDU and populate the MessageType;
void
setMessageType
();
//Initialize the PDU and populate the MessageType;
void
setAMFName
(
const
std
::
string
name
);
//���IE
void
setAMFName
(
const
std
::
string
name
);
void
setGUAMIList
(
std
::
vector
<
struct
GuamiItem_s
>
list
);
void
setGUAMIList
(
std
::
vector
<
struct
GuamiItem_s
>
list
);
void
setRelativeAmfCapacity
(
long
capacity
);
void
setRelativeAmfCapacity
(
long
capacity
);
void
setPlmnSupportList
(
std
::
vector
<
PlmnSliceSupport_t
>
list
);
void
setPlmnSupportList
(
std
::
vector
<
PlmnSliceSupport_t
>
list
);
...
...
src/ngap/ngap_app/ngap_message_callback.hpp
View file @
914629c8
...
@@ -51,7 +51,6 @@ int ngap_amf_handle_ng_setup_request(const sctp_assoc_id_t assoc_id,
...
@@ -51,7 +51,6 @@ int ngap_amf_handle_ng_setup_request(const sctp_assoc_id_t assoc_id,
const
sctp_stream_id_t
stream
,
const
sctp_stream_id_t
stream
,
struct
Ngap_NGAP_PDU
*
message_p
)
{
struct
Ngap_NGAP_PDU
*
message_p
)
{
Logger
::
ngap
().
debug
(
"Sending ITTI NG Setup Request message to TASK_AMF_N2"
);
Logger
::
ngap
().
debug
(
"Sending ITTI NG Setup Request message to TASK_AMF_N2"
);
//need code from yangjian and send itti message to TASK_AMF_N2
asn_fprint
(
stderr
,
&
asn_DEF_Ngap_NGAP_PDU
,
message_p
);
asn_fprint
(
stderr
,
&
asn_DEF_Ngap_NGAP_PDU
,
message_p
);
NGSetupRequestMsg
*
ngSetupReq
=
new
NGSetupRequestMsg
();
NGSetupRequestMsg
*
ngSetupReq
=
new
NGSetupRequestMsg
();
if
(
!
ngSetupReq
->
decodefrompdu
(
message_p
))
{
if
(
!
ngSetupReq
->
decodefrompdu
(
message_p
))
{
...
...
Write
Preview
Markdown
is supported
0%
Try again
or
attach a new file
Attach a file
Cancel
You are about to add
0
people
to the discussion. Proceed with caution.
Finish editing this message first!
Cancel
Please
register
or
sign in
to comment