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
8fff9809
Commit
8fff9809
authored
Mar 04, 2021
by
dukl
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
fix bugs for service request procedure
parent
5268a8b9
Changes
2
Hide whitespace changes
Inline
Side-by-side
Showing
2 changed files
with
17 additions
and
2 deletions
+17
-2
src/amf-app/amf_n1.cpp
src/amf-app/amf_n1.cpp
+14
-1
src/nas/msgs/ServiceRequest.cpp
src/nas/msgs/ServiceRequest.cpp
+3
-1
No files found.
src/amf-app/amf_n1.cpp
View file @
8fff9809
...
...
@@ -598,6 +598,15 @@ void amf_n1::service_request_handle(
ServiceRequest
*
serReq
=
new
ServiceRequest
();
serReq
->
decodefrombuffer
(
nullptr
,
(
uint8_t
*
)
bdata
(
nas
),
blength
(
nas
));
bdestroy
(
nas
);
uint16_t
pdu_session_status
=
0xffff
;
bstring
nas_container
;
Logger
::
amf_n1
().
debug
(
"try to decode pdu-session-status in service_request(service_request)"
);
if
(
serReq
->
getNasMessageContainer
(
nas_container
)){
Logger
::
amf_n1
().
debug
(
"try to get pdu-session-status value from nas message container(length: %d)"
,
blength
(
nas_container
));
uint8_t
*
buf
=
(
uint8_t
*
)
bdata
(
nas_container
);
pdu_session_status
=
buf
[
18
]
<<
8
|
buf
[
19
];
Logger
::
amf_n1
().
debug
(
"Get pdu-session-status value: 0x%x"
,
pdu_session_status
);
}
ServiceAccept
*
serApt
=
new
ServiceAccept
();
serApt
->
setHeader
(
PLAIN_5GS_MSG
);
string
supi
=
"imsi-"
+
nc
.
get
()
->
imsi
;
...
...
@@ -661,7 +670,11 @@ void amf_n1::service_request_handle(
delete
serReq
;
return
;
}
serApt
->
setPDU_session_status
(
0x2000
);
if
(
pdu_session_status
==
0x00
){
serApt
->
setPDU_session_status
(
0x0000
);
}
else
{
serApt
->
setPDU_session_status
(
pdu_session_status
);
}
serApt
->
setPDU_session_reactivation_result
(
0x0000
);
uint8_t
buffer
[
BUFFER_SIZE_256
];
int
encoded_size
=
serApt
->
encode2buffer
(
buffer
,
BUFFER_SIZE_256
);
...
...
src/nas/msgs/ServiceRequest.cpp
View file @
8fff9809
...
...
@@ -33,7 +33,9 @@
using
namespace
nas
;
//------------------------------------------------------------------------------
ServiceRequest
::
ServiceRequest
()
{}
ServiceRequest
::
ServiceRequest
()
{
ie_nas_message_container
=
nullptr
;
}
//------------------------------------------------------------------------------
ServiceRequest
::~
ServiceRequest
()
{}
...
...
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