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
017ed78b
Commit
017ed78b
authored
Jan 15, 2023
by
Tien Thinh NGUYEN
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
Update MA PDU Session Information
parent
74a81963
Changes
7
Hide whitespace changes
Inline
Side-by-side
Showing
7 changed files
with
68 additions
and
29 deletions
+68
-29
src/nas/common/Ie_Const.hpp
src/nas/common/Ie_Const.hpp
+1
-1
src/nas/common/NasIeHeader.hpp
src/nas/common/NasIeHeader.hpp
+1
-1
src/nas/ies/ImeisvRequest.cpp
src/nas/ies/ImeisvRequest.cpp
+0
-1
src/nas/ies/MaPduSessionInformation.cpp
src/nas/ies/MaPduSessionInformation.cpp
+50
-0
src/nas/ies/MaPduSessionInformation.hpp
src/nas/ies/MaPduSessionInformation.hpp
+11
-20
src/nas/msgs/ULNASTransport.cpp
src/nas/msgs/ULNASTransport.cpp
+4
-5
src/nas/msgs/ULNASTransport.hpp
src/nas/msgs/ULNASTransport.hpp
+1
-1
No files found.
src/nas/common/Ie_Const.hpp
View file @
017ed78b
...
...
@@ -52,7 +52,6 @@ constexpr uint8_t kIeiExtendedProtocolConfigurationOptions =
0x7b
;
// To be verified
constexpr
uint8_t
kIeiIntegrityProtectionMaximumDataRate
=
0x13
;
constexpr
uint8_t
kIeiIpHeaderCompressionConfiguration
=
0x66
;
constexpr
uint8_t
kIeiMaPduSessionInformation
=
0xa0
;
constexpr
uint8_t
kIeiMappedEpsBearerContexts
=
0x75
;
constexpr
uint8_t
kIeiMaximumNumberOfSupportedPacketFilters
=
0x55
;
constexpr
uint8_t
kIeiNbN1ModeDrxParameters
=
0x29
;
...
...
@@ -90,6 +89,7 @@ constexpr uint8_t kIeiRequestType = 0x08; // 8-(4 higher bits)
constexpr
uint8_t
kIeiNetworkSlicingIndication
=
0x09
;
// 9-(4 higher bits)
constexpr
uint8_t
kIeiNssaiInclusionMode
=
0x0A
;
// A-(4 higher bits)
constexpr
uint8_t
kIeiMaPduSessionInformation
=
0x0A
;
// A-(4 higher bits)
constexpr
uint8_t
kIeiMicoIndication
=
0x0B
;
// B-(4 higher bits)
constexpr
uint8_t
kIeiNasKeySetIdentifier
=
0x0C
;
// C-(4 higher bits)
constexpr
uint8_t
kIeiNon3gppNwProvidedPolicies
=
0x0D
;
// D-(4 higher bits)
...
...
src/nas/common/NasIeHeader.hpp
View file @
017ed78b
...
...
@@ -45,7 +45,7 @@
#include "GprsTimer3.hpp"
#include "ImeisvRequest.hpp"
#include "LADN_Indication.hpp"
#include "M
A_PDU_Session_
Information.hpp"
#include "M
aPduSession
Information.hpp"
#include "NasMessageContainer.hpp"
#include "NasSecurityAlgorithms.hpp"
#include "NSSAI.hpp"
...
...
src/nas/ies/ImeisvRequest.cpp
View file @
017ed78b
...
...
@@ -21,7 +21,6 @@
#include "ImeisvRequest.hpp"
#include "logger.hpp"
using
namespace
nas
;
//------------------------------------------------------------------------------
...
...
src/nas/ies/M
A_PDU_Session_
Information.cpp
→
src/nas/ies/M
aPduSession
Information.cpp
View file @
017ed78b
...
...
@@ -19,84 +19,32 @@
* contact@openairinterface.org
*/
/*! \file
\brief
\author Keliang DU, BUPT
\date 2020
\email: contact@openairinterface.org
*/
#include "MA_PDU_Session_Information.hpp"
#include "MaPduSessionInformation.hpp"
#include "logger.hpp"
using
namespace
nas
;
//------------------------------------------------------------------------------
MA_PDU_Session_Information
::
MA_PDU_Session_Information
(
uint8_t
iei
)
{
_iei
=
iei
;
_value
=
0
;
}
//------------------------------------------------------------------------------
MA_PDU_Session_Information
::
MA_PDU_Session_Information
(
const
uint8_t
iei
,
uint8_t
value
)
{
_iei
=
iei
;
_value
=
value
;
MaPduSessionInformation
::
MaPduSessionInformation
()
:
Type1NasIeFormatTv
(
kIeiMaPduSessionInformation
)
{
SetIeName
(
kMaPduSessionInformationIeName
);
}
//------------------------------------------------------------------------------
MA_PDU_Session_Information
::
MA_PDU_Session_Information
()
{
_iei
=
0
;
_value
=
0
;
MaPduSessionInformation
::
MaPduSessionInformation
(
uint8_t
value
)
:
Type1NasIeFormatTv
(
kIeiMaPduSessionInformation
)
{
SetValue
(
value
&
0x0f
);
SetIeName
(
kMaPduSessionInformationIeName
);
}
//------------------------------------------------------------------------------
MA_PDU_Session_Information
::~
MA_PDU_Session_Information
()
{}
//------------------------------------------------------------------------------
void
MA_PDU_Session_Information
::
setValue
(
uint8_t
value
)
{
_value
=
value
;
}
//------------------------------------------------------------------------------
uint8_t
MA_PDU_Session_Information
::
getValue
()
{
return
_value
;
}
MaPduSessionInformation
::~
MaPduSessionInformation
()
{}
//------------------------------------------------------------------------------
int
MA_PDU_Session_Information
::
Encode
(
uint8_t
*
buf
,
int
len
)
{
Logger
::
nas_mm
().
debug
(
"encoding MA_PDU_Session_Information iei(0x%x)"
,
_iei
);
if
(
len
<
1
)
{
Logger
::
nas_mm
().
error
(
"len is less than 1"
);
return
0
;
}
int
encoded_size
=
0
;
if
(
_iei
)
{
*
(
buf
+
encoded_size
)
=
((
_iei
&
0x0f
)
<<
4
)
|
(
_value
&
0x0f
);
encoded_size
++
;
}
else
{
*
(
buf
+
encoded_size
)
=
_value
&
0x0f
;
encoded_size
++
;
}
Logger
::
nas_mm
().
debug
(
"encoded MA_PDU_Session_Information len(%d)"
,
encoded_size
);
return
encoded_size
;
void
MaPduSessionInformation
::
SetValue
(
uint8_t
value
)
{
SetValue
(
value
&
0x0f
);
}
//------------------------------------------------------------------------------
int
MA_PDU_Session_Information
::
Decode
(
uint8_t
*
buf
,
int
len
,
bool
is_option
)
{
Logger
::
nas_mm
().
debug
(
"decoding MA_PDU_Session_Information iei(0x%x)"
,
*
buf
);
int
decoded_size
=
0
;
uint8_t
octet
=
0
;
if
(
is_option
)
{
octet
=
*
buf
;
decoded_size
++
;
}
_value
=
0x00
;
_value
=
octet
&
0x0f
;
Logger
::
nas_mm
().
debug
(
"decoded MA_PDU_Session_Information _value(0x%x)"
,
_value
);
Logger
::
nas_mm
().
debug
(
"decoded MA_PDU_Session_Information len(%d)"
,
decoded_size
);
return
decoded_size
;
uint8_t
MaPduSessionInformation
::
GetValue
()
const
{
return
GetValue
()
&
0x0f
;
}
src/nas/ies/M
A_PDU_Session_
Information.hpp
→
src/nas/ies/M
aPduSession
Information.hpp
View file @
017ed78b
...
...
@@ -19,34 +19,25 @@
* contact@openairinterface.org
*/
/*! \file
\brief
\author Keliang DU, BUPT
\date 2020
\email: contact@openairinterface.org
*/
#ifndef _MA_PDU_SESSION_INFORMATION_H_
#define _MA_PDU_SESSION_INFORMATION_H_
#ifndef __MA_PDU_Session_Information_H_
#define __MA_PDU_Session_Information_H_
#include "Type1NasIeFormatTv.hpp"
#include <stdint.h>
constexpr
auto
kMaPduSessionInformationIeName
=
"MA PDU Session Information"
;
namespace
nas
{
class
M
A_PDU_Session_Information
{
class
M
aPduSessionInformation
:
public
Type1NasIeFormatTv
{
public:
MA_PDU_Session_Information
();
MA_PDU_Session_Information
(
uint8_t
iei
);
MA_PDU_Session_Information
(
const
uint8_t
iei
,
uint8_t
value
);
~
MA_PDU_Session_Information
();
int
Encode
(
uint8_t
*
buf
,
int
len
);
int
Decode
(
uint8_t
*
buf
,
int
len
,
bool
is_option
);
void
setValue
(
uint8_t
value
);
uint8_t
getValue
();
MaPduSessionInformation
();
MaPduSessionInformation
(
uint8_t
value
);
~
MaPduSessionInformation
();
void
SetValue
(
uint8_t
value
);
uint8_t
GetValue
()
const
;
private:
uint8_t
_iei
;
uint8_t
_value
;
};
}
// namespace nas
...
...
src/nas/msgs/ULNASTransport.cpp
View file @
017ed78b
...
...
@@ -159,7 +159,7 @@ void ULNASTransport::SetAdditionalInformation(const bstring& value) {
//------------------------------------------------------------------------------
void
ULNASTransport
::
SetMaPduSessionInformation
(
uint8_t
value
)
{
ie_ma_pdu_session_information
=
std
::
make_optional
<
M
A_PDU_Session_Information
>
(
0x0A
,
value
);
std
::
make_optional
<
M
aPduSessionInformation
>
(
value
);
}
//------------------------------------------------------------------------------
...
...
@@ -364,15 +364,14 @@ int ULNASTransport::Decode(NasMmPlainHeader* header, uint8_t* buf, int len) {
}
break
;
case
0xA
:
{
Logger
::
nas_mm
().
debug
(
"Decoding IEI (0xA)"
);
M
A_PDU_Session_
Information
ie_ma_pdu_session_information_tmp
=
{};
M
aPduSession
Information
ie_ma_pdu_session_information_tmp
=
{};
if
((
decoded_result
=
ie_ma_pdu_session_information_tmp
.
Decode
(
buf
+
decoded_size
,
len
-
decoded_size
,
true
))
==
KEncodeDecodeError
)
return
decoded_result
;
decoded_size
+=
decoded_result
;
ie_ma_pdu_session_information
=
std
::
optional
<
MA_PDU_Session_Information
>
(
ie_ma_pdu_session_information_tmp
);
ie_ma_pdu_session_information
=
std
::
optional
<
MaPduSessionInformation
>
(
ie_ma_pdu_session_information_tmp
);
octet
=
*
(
buf
+
decoded_size
);
Logger
::
nas_mm
().
debug
(
"Next IEI (0x%x)"
,
octet
);
}
break
;
...
...
src/nas/msgs/ULNASTransport.hpp
View file @
017ed78b
...
...
@@ -74,7 +74,7 @@ class ULNASTransport : public NasMmPlainHeader {
std
::
optional
<
S_NSSAI
>
ie_s_nssai
;
// Optional
std
::
optional
<
DNN
>
ie_dnn
;
// Optional
std
::
optional
<
AdditionalInformation
>
ie_additional_information
;
// Optional
std
::
optional
<
M
A_PDU_Session_
Information
>
std
::
optional
<
M
aPduSession
Information
>
ie_ma_pdu_session_information
;
// Optional
std
::
optional
<
Release_Assistance_Indication
>
ie_release_assistance_indication
;
// Optional
...
...
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