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
Project overview
Project overview
Details
Activity
Releases
Repository
Repository
Files
Commits
Branches
Tags
Contributors
Graph
Compare
Issues
1
Issues
1
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
OpenXG
OpenXG-AMF
Commits
030856ea
Commit
030856ea
authored
Feb 13, 2023
by
Tien Thinh NGUYEN
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
Add function to get GUTI from TMSI
parent
c904b0f4
Changes
3
Hide whitespace changes
Inline
Side-by-side
Showing
3 changed files
with
18 additions
and
1 deletion
+18
-1
src/amf-app/amf_app.cpp
src/amf-app/amf_app.cpp
+0
-1
src/common/conversions.cpp
src/common/conversions.cpp
+14
-0
src/common/conversions.hpp
src/common/conversions.hpp
+4
-0
No files found.
src/amf-app/amf_app.cpp
View file @
030856ea
...
...
@@ -204,7 +204,6 @@ long amf_app::generate_amf_ue_ngap_id() {
//------------------------------------------------------------------------------
bool
amf_app
::
is_ran_amf_id_2_ue_context
(
const
string
&
ue_context_key
)
const
{
std
::
shared_lock
lock
(
m_ue_ctx_key
);
// return bool{ue_ctx_key.count(ue_context_key) > 0};
if
(
ue_ctx_key
.
count
(
ue_context_key
)
>
0
)
{
if
(
ue_ctx_key
.
at
(
ue_context_key
)
!=
nullptr
)
{
return
true
;
...
...
src/common/conversions.cpp
View file @
030856ea
...
...
@@ -491,3 +491,17 @@ std::string conv::get_serving_network_name(
snn
=
"5G:mnc"
+
mnc
+
".mcc"
+
mcc
+
".3gppnetwork.org"
;
return
snn
;
}
//------------------------------------------------------------------------------
std
::
string
conv
::
uint32_to_hex_string
(
uint32_t
value
)
{
char
hex_str
[
8
];
sprintf
(
hex_str
,
"%X"
,
value
);
return
std
::
string
(
hex_str
);
}
//------------------------------------------------------------------------------
std
::
string
conv
::
tmsi_to_guti
(
const
std
::
string
&
mcc
,
const
std
::
string
&
mnc
,
const
std
::
string
&
region_id
,
const
std
::
string
&
tmsi
)
{
return
{
mcc
+
mnc
+
region_id
+
tmsi
};
}
src/common/conversions.hpp
View file @
030856ea
...
...
@@ -99,5 +99,9 @@ class conv {
const
uint32_t
ran_ue_ngap_id
,
long
amf_ue_ngap_id
);
static
std
::
string
get_serving_network_name
(
const
std
::
string
&
mnc
,
const
std
::
string
&
mcc
);
static
std
::
string
uint32_to_hex_string
(
uint32_t
value
);
static
std
::
string
tmsi_to_guti
(
const
std
::
string
&
mcc
,
const
std
::
string
&
mnc
,
const
std
::
string
&
region_id
,
const
std
::
string
&
tmsi
);
};
#endif
/* FILE_CONVERSIONS_HPP_SEEN */
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