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
a0d42520
Commit
a0d42520
authored
Nov 22, 2021
by
Tien-Thinh Nguyen
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
Fix issue to get NSSAI from Security Mode Complete
parent
23e5e58b
Changes
3
Show whitespace changes
Inline
Side-by-side
Showing
3 changed files
with
14 additions
and
7 deletions
+14
-7
src/amf-app/amf_n1.cpp
src/amf-app/amf_n1.cpp
+6
-0
src/nas/ies/struct.hpp
src/nas/ies/struct.hpp
+7
-0
src/nas/msgs/SecurityModeComplete.cpp
src/nas/msgs/SecurityModeComplete.cpp
+1
-7
No files found.
src/amf-app/amf_n1.cpp
View file @
a0d42520
...
...
@@ -2199,6 +2199,12 @@ void amf_n1::security_mode_complete_handle(
std
::
vector
<
SNSSAI_t
>
requested_nssai
=
{};
if
(
registration_request
->
getRequestedNssai
(
requested_nssai
))
{
nc
.
get
()
->
requestedNssai
=
requested_nssai
;
for
(
auto
s
:
nc
.
get
()
->
requestedNssai
)
{
Logger
::
amf_n1
().
debug
(
"Requested NSSAI SST (0x%x) SD (0x%x) hplmnSST (0x%x) hplmnSD "
"(%d)"
,
s
.
sst
,
s
.
sd
,
s
.
mHplmnSst
,
s
.
mHplmnSd
);
}
}
}
}
...
...
src/nas/ies/struct.hpp
View file @
a0d42520
...
...
@@ -45,6 +45,13 @@ typedef struct SNSSAI_s {
int32_t
sd
;
int32_t
mHplmnSst
;
int32_t
mHplmnSd
;
SNSSAI_s
&
operator
=
(
const
struct
SNSSAI_s
&
s
)
{
sst
=
s
.
sst
;
sd
=
s
.
sd
;
mHplmnSst
=
s
.
mHplmnSst
;
mHplmnSd
=
s
.
mHplmnSd
;
return
*
this
;
}
}
SNSSAI_t
;
typedef
struct
{
uint8_t
ie_type
;
...
...
src/nas/msgs/SecurityModeComplete.cpp
View file @
a0d42520
...
...
@@ -153,7 +153,7 @@ int SecurityModeComplete::encode2buffer(uint8_t* buf, int len) {
int
SecurityModeComplete
::
decodefrombuffer
(
NasMmPlainHeader
*
header
,
uint8_t
*
buf
,
int
len
)
{
Logger
::
nas_mm
().
debug
(
"Decoding SecurityModeComplete message"
);
int
decoded_size
=
3
;
int
decoded_size
=
3
;
// For the header
plain_header
=
header
;
Logger
::
nas_mm
().
debug
(
"Decoded_size (%d)"
,
decoded_size
);
...
...
@@ -167,24 +167,18 @@ int SecurityModeComplete::decodefrombuffer(
ie_imeisv
=
new
_5GSMobilityIdentity
();
decoded_size
+=
ie_imeisv
->
decodefrombuffer
(
buf
+
decoded_size
,
len
-
decoded_size
,
true
);
// octet = *(buf + decoded_size);
Logger
::
nas_mm
().
debug
(
"Next IEI (0x%x)"
,
octet
);
}
break
;
case
0x71
:
{
Logger
::
nas_mm
().
debug
(
"Decoding IEI (0x71)"
);
ie_nas_message_container
=
new
NAS_Message_Container
();
decoded_size
+=
ie_nas_message_container
->
decodefrombuffer
(
buf
+
decoded_size
,
len
-
decoded_size
,
true
);
// octet = *(buf + decoded_size);
Logger
::
nas_mm
().
debug
(
"Next IEI (0x%x)"
,
octet
);
}
break
;
case
0x78
:
{
Logger
::
nas_mm
().
debug
(
"Decoding IEI (0x78)"
);
ie_non_imeisvpei
=
new
_5GSMobilityIdentity
();
decoded_size
+=
ie_non_imeisvpei
->
decodefrombuffer
(
buf
+
decoded_size
,
len
-
decoded_size
,
true
);
// octet = *(buf + decoded_size);
Logger
::
nas_mm
().
debug
(
"Next IEI (0x%x)"
,
octet
);
}
break
;
default:
{
Logger
::
nas_mm
().
debug
(
"Unexpected IEI (0x%x)"
,
octet
);
...
...
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