issue 384

This commit is contained in:
laurent
2018-12-23 17:55:07 +01:00
parent 001163f63b
commit b3f1440249
44 changed files with 0 additions and 3014 deletions
-578
View File
@@ -1,578 +0,0 @@
/*
* Copyright (c) 2015, EURECOM (www.eurecom.fr)
* All rights reserved.
*
* Redistribution and use in source and binary forms, with or without
* modification, are permitted provided that the following conditions are met:
*
* 1. Redistributions of source code must retain the above copyright notice, this
* list of conditions and the following disclaimer.
* 2. Redistributions in binary form must reproduce the above copyright notice,
* this list of conditions and the following disclaimer in the documentation
* and/or other materials provided with the distribution.
*
* THIS SOFTWARE IS PROVIDED BY THE COPYRIGHT HOLDERS AND CONTRIBUTORS "AS IS" AND
* ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED
* WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE ARE
* DISCLAIMED. IN NO EVENT SHALL THE COPYRIGHT OWNER OR CONTRIBUTORS BE LIABLE FOR
* ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES
* (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES;
* LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND
* ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT
* (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF THIS
* SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE.
*
* The views and conclusions contained in the software and documentation are those
* of the authors and should not be interpreted as representing official policies,
* either expressed or implied, of the FreeBSD Project.
*/
/*****************************************************************************
Source as_message.h
Version 0.1
Date 2012/10/18
Product NAS stack
Subsystem Application Programming Interface
Author Frederic Maurel
Description Defines the messages supported by the Access Stratum sublayer
protocol (usually RRC and S1AP for E-UTRAN) and functions used
to encode and decode
*****************************************************************************/
#ifndef __AS_MESSAGE_H__
#define __AS_MESSAGE_H__
#include "commonDef.h"
#include "networkDef.h"
/****************************************************************************/
/********************* G L O B A L C O N S T A N T S *******************/
/****************************************************************************/
/*
* --------------------------------------------------------------------------
* Access Stratum message types
* --------------------------------------------------------------------------
*/
#define AS_REQUEST 0x0100
#define AS_RESPONSE 0x0200
#define AS_INDICATION 0x0400
#define AS_CONFIRM 0x0800
/*
* --------------------------------------------------------------------------
* Access Stratum message identifiers
* --------------------------------------------------------------------------
*/
/* Broadcast information */
#define AS_BROADCAST_INFO 0x01
#define AS_BROADCAST_INFO_IND (AS_BROADCAST_INFO | AS_INDICATION)
/* Cell information relevant for cell selection processing */
#define AS_CELL_INFO 0x02
#define AS_CELL_INFO_REQ (AS_CELL_INFO | AS_REQUEST)
#define AS_CELL_INFO_CNF (AS_CELL_INFO | AS_CONFIRM)
#define AS_CELL_INFO_IND (AS_CELL_INFO | AS_INDICATION)
/* Paging information */
#define AS_PAGING 0x03
#define AS_PAGING_REQ (AS_PAGING | AS_REQUEST)
#define AS_PAGING_IND (AS_PAGING | AS_INDICATION)
/* NAS signalling connection establishment */
#define AS_NAS_ESTABLISH 0x04
#define AS_NAS_ESTABLISH_REQ (AS_NAS_ESTABLISH | AS_REQUEST)
#define AS_NAS_ESTABLISH_IND (AS_NAS_ESTABLISH | AS_INDICATION)
#define AS_NAS_ESTABLISH_RSP (AS_NAS_ESTABLISH | AS_RESPONSE)
#define AS_NAS_ESTABLISH_CNF (AS_NAS_ESTABLISH | AS_CONFIRM)
/* NAS signalling connection release */
#define AS_NAS_RELEASE 0x05
#define AS_NAS_RELEASE_REQ (AS_NAS_RELEASE | AS_REQUEST)
#define AS_NAS_RELEASE_IND (AS_NAS_RELEASE | AS_INDICATION)
/* Uplink information transfer */
#define AS_UL_INFO_TRANSFER 0x06
#define AS_UL_INFO_TRANSFER_REQ (AS_UL_INFO_TRANSFER | AS_REQUEST)
#define AS_UL_INFO_TRANSFER_CNF (AS_UL_INFO_TRANSFER | AS_CONFIRM)
#define AS_UL_INFO_TRANSFER_IND (AS_UL_INFO_TRANSFER | AS_INDICATION)
/* Downlink information transfer */
#define AS_DL_INFO_TRANSFER 0x07
#define AS_DL_INFO_TRANSFER_REQ (AS_DL_INFO_TRANSFER | AS_REQUEST)
#define AS_DL_INFO_TRANSFER_CNF (AS_DL_INFO_TRANSFER | AS_CONFIRM)
#define AS_DL_INFO_TRANSFER_IND (AS_DL_INFO_TRANSFER | AS_INDICATION)
/* Radio Access Bearer establishment */
#define AS_RAB_ESTABLISH 0x08
#define AS_RAB_ESTABLISH_REQ (AS_RAB_ESTABLISH | AS_REQUEST)
#define AS_RAB_ESTABLISH_IND (AS_RAB_ESTABLISH | AS_INDICATION)
#define AS_RAB_ESTABLISH_RSP (AS_RAB_ESTABLISH | AS_RESPONSE)
#define AS_RAB_ESTABLISH_CNF (AS_RAB_ESTABLISH | AS_CONFIRM)
/* Radio Access Bearer release */
#define AS_RAB_RELEASE 0x09
#define AS_RAB_RELEASE_REQ (AS_RAB_RELEASE | AS_REQUEST)
#define AS_RAB_RELEASE_IND (AS_RAB_RELEASE | AS_INDICATION)
/* NAS Cause */
#define EPS_SERVICES_AND_NON_EPS_SERVICES_NOT_ALLOWED (8)
#define EPS_SERVICES_NOT_ALLOWED (7)
#define PLMN_NOT_ALLOWED (11)
#define TRACKING_AREA_NOT_ALLOWED (12)
#define ROAMING_NOT_ALLOWED_IN_THIS_TRACKING_AREA (13)
#define EPS_SERVICES_NOT_ALLOWED_IN_THIS_PLMN (14)
#define NO_SUITABLE_CELLS_IN_TRACKING_AREA (15)
#define NETWORK_FAILURE (17)
#define ESM_FAILURE (19)
typedef enum nas_cause_s {
NAS_CAUSE_EPS_SERVICES_AND_NON_EPS_SERVICES_NOT_ALLOWED = EPS_SERVICES_AND_NON_EPS_SERVICES_NOT_ALLOWED,
NAS_CAUSE_EPS_SERVICES_NOT_ALLOWED = EPS_SERVICES_NOT_ALLOWED,
NAS_CAUSE_PLMN_NOT_ALLOWED = PLMN_NOT_ALLOWED,
NAS_CAUSE_TRACKING_AREA_NOT_ALLOWED = TRACKING_AREA_NOT_ALLOWED,
NAS_CAUSE_ROAMING_NOT_ALLOWED_IN_THIS_TRACKING_AREA = ROAMING_NOT_ALLOWED_IN_THIS_TRACKING_AREA,
NAS_CAUSE_EPS_SERVICES_NOT_ALLOWED_IN_THIS_PLMN = EPS_SERVICES_NOT_ALLOWED_IN_THIS_PLMN,
NAS_CAUSE_NO_SUITABLE_CELLS_IN_TRACKING_AREA = NO_SUITABLE_CELLS_IN_TRACKING_AREA,
NAS_CAUSE_NETWORK_FAILURE = NETWORK_FAILURE,
NAS_CAUSE_ESM_FAILURE = ESM_FAILURE
} nas_cause_t;
/*
* --------------------------------------------------------------------------
* Access Stratum message global parameters
* --------------------------------------------------------------------------
*/
/* Error code */
typedef enum nas_error_code_s {
AS_SUCCESS = 1, /* Success code, transaction is going on */
AS_TERMINATED_NAS, /* Transaction terminated by NAS */
AS_TERMINATED_AS, /* Transaction terminated by AS */
AS_FAILURE /* Failure code */
} nas_error_code_t;
/* Core network domain */
typedef enum core_network_s {
AS_PS = 1, /* Packet-Switched */
AS_CS /* Circuit-Switched */
} core_network_t;
/* SAE Temporary Mobile Subscriber Identity */
typedef struct as_stmsi_s {
uint8_t MMEcode; /* MME code that allocated the GUTI */
uint32_t m_tmsi; /* M-Temporary Mobile Subscriber Identity */
} as_stmsi_t;
/* Dedicated NAS information */
typedef struct as_nas_info_s {
uint32_t length; /* Length of the NAS information data */
Byte_t* data; /* Dedicated NAS information data container */
} as_nas_info_t;
/* Radio Access Bearer identity */
typedef uint8_t as_rab_id_t;
/****************************************************************************/
/************************ G L O B A L T Y P E S ************************/
/****************************************************************************/
/*
* --------------------------------------------------------------------------
* Broadcast information
* --------------------------------------------------------------------------
*/
/*
* AS->NAS - Broadcast information indication
* AS may asynchronously report to NAS available PLMNs within specific
* location area
*/
typedef struct broadcast_info_ind_s {
#define PLMN_LIST_MAX_SIZE 6
PLMN_LIST_T(PLMN_LIST_MAX_SIZE) plmnIDs; /* List of PLMN identifiers */
ci_t cellID; /* Identity of the cell serving the listed PLMNs */
tac_t tac; /* Code of the tracking area the cell belongs to */
} broadcast_info_ind_t;
/*
* --------------------------------------------------------------------------
* Cell information relevant for cell selection processing
* --------------------------------------------------------------------------
*/
/* Radio access technologies supported by the network */
#define AS_GSM (1 << NET_ACCESS_GSM)
#define AS_COMPACT (1 << NET_ACCESS_COMPACT)
#define AS_UTRAN (1 << NET_ACCESS_UTRAN)
#define AS_EGPRS (1 << NET_ACCESS_EGPRS)
#define AS_HSDPA (1 << NET_ACCESS_HSDPA)
#define AS_HSUPA (1 << NET_ACCESS_HSUPA)
#define AS_HSDUPA (1 << NET_ACCESS_HSDUPA)
#define AS_EUTRAN (1 << NET_ACCESS_EUTRAN)
/*
* NAS->AS - Cell Information request
* NAS request AS to search for a suitable cell belonging to the selected
* PLMN to camp on.
*/
typedef struct cell_info_req_s {
plmn_t plmnID; /* Selected PLMN identity */
Byte_t rat; /* Bitmap - set of radio access technologies */
} cell_info_req_t;
/*
* AS->NAS - Cell Information confirm
* AS search for a suitable cell and respond to NAS. If found, the cell
* is selected to camp on.
*/
typedef struct cell_info_cnf_s {
uint8_t errCode; /* Error code */
ci_t cellID; /* Identity of the cell serving the selected PLMN */
tac_t tac; /* Code of the tracking area the cell belongs to */
AcT_t rat; /* Radio access technology supported by the cell */
uint8_t rsrq; /* Reference signal received quality */
uint8_t rsrp; /* Reference signal received power */
} cell_info_cnf_t;
/*
* AS->NAS - Cell Information indication
* AS may change cell selection if a more suitable cell is found.
*/
typedef struct cell_info_ind_s {
ci_t cellID; /* Identity of the new serving cell */
tac_t tac; /* Code of the tracking area the cell belongs to */
} cell_info_ind_t;
/*
* --------------------------------------------------------------------------
* Paging information
* --------------------------------------------------------------------------
*/
/* Paging cause */
typedef enum paging_cause_s {
AS_CONNECTION_ESTABLISH, /* Establish NAS signalling connection */
AS_EPS_ATTACH, /* Perform local detach and initiate EPS
* attach procedure */
AS_CS_FALLBACK /* Inititate CS fallback procedure */
} paging_cause_t;
/*
* NAS->AS - Paging Information request
* NAS requests the AS that NAS signalling messages or user data is pending
* to be sent.
*/
typedef struct paging_req_s {
as_stmsi_t s_tmsi; /* UE identity */
uint8_t CN_domain; /* Core network domain */
} paging_req_t;
/*
* AS->NAS - Paging Information indication
* AS reports to the NAS that appropriate procedure has to be initiated.
*/
typedef struct paging_ind_s {
paging_cause_t cause; /* Paging cause */
} paging_ind_t;
/*
* --------------------------------------------------------------------------
* NAS signalling connection establishment
* --------------------------------------------------------------------------
*/
/* Cause of RRC connection establishment */
typedef enum as_cause_s {
AS_CAUSE_UNKNOWN = 0,
AS_CAUSE_EMERGENCY = NET_ESTABLISH_CAUSE_EMERGENCY,
AS_CAUSE_HIGH_PRIO = NET_ESTABLISH_CAUSE_HIGH_PRIO,
AS_CAUSE_MT_ACCESS = NET_ESTABLISH_CAUSE_MT_ACCESS,
AS_CAUSE_MO_SIGNAL = NET_ESTABLISH_CAUSE_MO_SIGNAL,
AS_CAUSE_MO_DATA = NET_ESTABLISH_CAUSE_MO_DATA,
AS_CAUSE_V1020 = NET_ESTABLISH_CAUSE_V1020
} as_cause_t;
/* Type of the call associated to the RRC connection establishment */
typedef enum as_call_type_s {
AS_TYPE_ORIGINATING_SIGNAL = NET_ESTABLISH_TYPE_ORIGINATING_SIGNAL,
AS_TYPE_EMERGENCY_CALLS = NET_ESTABLISH_TYPE_EMERGENCY_CALLS,
AS_TYPE_ORIGINATING_CALLS = NET_ESTABLISH_TYPE_ORIGINATING_CALLS,
AS_TYPE_TERMINATING_CALLS = NET_ESTABLISH_TYPE_TERMINATING_CALLS,
AS_TYPE_MO_CS_FALLBACK = NET_ESTABLISH_TYPE_MO_CS_FALLBACK
} as_call_type_t;
/*
* NAS->AS - NAS signalling connection establishment request
* NAS requests the AS to perform the RRC connection establishment procedure
* to transfer initial NAS message to the network while UE is in IDLE mode.
*/
typedef struct nas_establish_req_s {
as_cause_t cause; /* RRC connection establishment cause */
as_call_type_t type; /* RRC associated call type */
as_stmsi_t s_tmsi; /* UE identity */
plmn_t plmnID; /* Selected PLMN identity */
as_nas_info_t initialNasMsg; /* Initial NAS message to transfer */
} nas_establish_req_t;
/*
* AS->NAS - NAS signalling connection establishment indication
* AS transfers the initial NAS message to the NAS.
*/
typedef struct nas_establish_ind_s {
uint32_t UEid; /* UE lower layer identifier */
tac_t tac; /* Code of the tracking area the initiating
* UE belongs to */
as_cause_t asCause; /* Establishment cause */
as_nas_info_t initialNasMsg; /* Initial NAS message to transfer */
} nas_establish_ind_t;
/*
* NAS->AS - NAS signalling connection establishment response
* NAS responds to the AS that initial answer message has to be provided to
* the UE.
*/
typedef struct nas_establish_rsp_s {
uint32_t UEid; /* UE lower layer identifier */
as_stmsi_t s_tmsi; /* UE identity */
nas_error_code_t errCode; /* Transaction status */
as_nas_info_t nasMsg; /* NAS message to transfer */
uint32_t nas_ul_count; /* UL NAS COUNT */
uint16_t selected_encryption_algorithm;
uint16_t selected_integrity_algorithm;
} nas_establish_rsp_t;
/*
* AS->NAS - NAS signalling connection establishment confirm
* AS transfers the initial answer message to the NAS.
*/
typedef struct nas_establish_cnf_s {
uint32_t UEid; /* UE lower layer identifier */
nas_error_code_t errCode; /* Transaction status */
as_nas_info_t nasMsg; /* NAS message to transfer */
uint32_t ul_nas_count;
uint16_t selected_encryption_algorithm;
uint16_t selected_integrity_algorithm;
} nas_establish_cnf_t;
/*
* --------------------------------------------------------------------------
* NAS signalling connection release
* --------------------------------------------------------------------------
*/
/* Release cause */
typedef enum release_cause_s {
AS_AUTHENTICATION_FAILURE = 1, /* Authentication procedure failed */
AS_DETACH /* Detach requested */
} release_cause_t;
/*
* NAS->AS - NAS signalling connection release request
* NAS requests the termination of the connection with the UE.
*/
typedef struct nas_release_req_s {
uint32_t UEid; /* UE lower layer identifier */
as_stmsi_t s_tmsi; /* UE identity */
release_cause_t cause; /* Release cause */
} nas_release_req_t;
/*
* AS->NAS - NAS signalling connection release indication
* AS reports that connection has been terminated by the network.
*/
typedef struct nas_release_ind_s {
release_cause_t cause; /* Release cause */
} nas_release_ind_t;
/*
* --------------------------------------------------------------------------
* NAS information transfer
* --------------------------------------------------------------------------
*/
/*
* NAS->AS - Uplink data transfer request
* NAS requests the AS to transfer uplink information to the NAS that
* operates at the network side.
*/
typedef struct ul_info_transfer_req_s {
uint32_t UEid; /* UE lower layer identifier */
as_stmsi_t s_tmsi; /* UE identity */
as_nas_info_t nasMsg; /* Uplink NAS message */
} ul_info_transfer_req_t;
/*
* AS->NAS - Uplink data transfer confirm
* AS immediately notifies the NAS whether uplink information has been
* successfully sent to the network or not.
*/
typedef struct ul_info_transfer_cnf_s {
uint32_t UEid; /* UE lower layer identifier */
nas_error_code_t errCode; /* Transaction status */
} ul_info_transfer_cnf_t;
/*
* AS->NAS - Uplink data transfer indication
* AS delivers the uplink information message to the NAS that operates
* at the network side.
*/
typedef struct ul_info_transfer_ind_s {
uint32_t UEid; /* UE lower layer identifier */
as_nas_info_t nasMsg; /* Uplink NAS message */
} ul_info_transfer_ind_t;
/*
* NAS->AS - Downlink data transfer request
* NAS requests the AS to transfer downlink information to the NAS that
* operates at the UE side.
*/
typedef ul_info_transfer_req_t dl_info_transfer_req_t;
/*
* AS->NAS - Downlink data transfer confirm
* AS immediately notifies the NAS whether downlink information has been
* successfully sent to the network or not.
*/
typedef ul_info_transfer_cnf_t dl_info_transfer_cnf_t;
/*
* AS->NAS - Downlink data transfer indication
* AS delivers the downlink information message to the NAS that operates
* at the UE side.
*/
typedef ul_info_transfer_ind_t dl_info_transfer_ind_t;
/*
* --------------------------------------------------------------------------
* Radio Access Bearer establishment
* --------------------------------------------------------------------------
*/
/* TODO: Quality of Service parameters */
typedef struct {} as_qos_t;
/*
* NAS->AS - Radio access bearer establishment request
* NAS requests the AS to allocate transmission resources to radio access
* bearer initialized at the network side.
*/
typedef struct rab_establish_req_s {
as_stmsi_t s_tmsi; /* UE identity */
as_rab_id_t rabID; /* Radio access bearer identity */
as_qos_t QoS; /* Requested Quality of Service */
} rab_establish_req_t;
/*
* AS->NAS - Radio access bearer establishment indication
* AS notifies the NAS that specific radio access bearer has to be setup.
*/
typedef struct rab_establish_ind_s {
as_rab_id_t rabID; /* Radio access bearer identity */
} rab_establish_ind_t;
/*
* NAS->AS - Radio access bearer establishment response
* NAS responds to AS whether the specified radio access bearer has been
* successfully setup or not.
*/
typedef struct rab_establish_rsp_s {
as_stmsi_t s_tmsi; /* UE identity */
as_rab_id_t rabID; /* Radio access bearer identity */
nas_error_code_t errCode; /* Transaction status */
} rab_establish_rsp_t;
/*
* AS->NAS - Radio access bearer establishment confirm
* AS notifies NAS whether the specified radio access bearer has been
* successfully setup at the UE side or not.
*/
typedef struct rab_establish_cnf_s {
as_rab_id_t rabID; /* Radio access bearer identity */
nas_error_code_t errCode; /* Transaction status */
} rab_establish_cnf_t;
/*
* --------------------------------------------------------------------------
* Radio Access Bearer release
* --------------------------------------------------------------------------
*/
/*
* NAS->AS - Radio access bearer release request
* NAS requests the AS to release transmission resources previously allocated
* to specific radio access bearer at the network side.
*/
typedef struct rab_release_req_s {
as_stmsi_t s_tmsi; /* UE identity */
as_rab_id_t rabID; /* Radio access bearer identity */
} rab_release_req_t;
/*
* AS->NAS - Radio access bearer release indication
* AS notifies NAS that specific radio access bearer has been released.
*/
typedef struct rab_release_ind_s {
as_rab_id_t rabID; /* Radio access bearer identity */
} rab_release_ind_t;
/*
* --------------------------------------------------------------------------
* Structure of the AS messages handled by the network sublayer
* --------------------------------------------------------------------------
*/
typedef struct as_message_s {
uint16_t msgID;
union {
broadcast_info_ind_t broadcast_info_ind;
cell_info_req_t cell_info_req;
cell_info_cnf_t cell_info_cnf;
cell_info_ind_t cell_info_ind;
paging_req_t paging_req;
paging_ind_t paging_ind;
nas_establish_req_t nas_establish_req;
nas_establish_ind_t nas_establish_ind;
nas_establish_rsp_t nas_establish_rsp;
nas_establish_cnf_t nas_establish_cnf;
nas_release_req_t nas_release_req;
nas_release_ind_t nas_release_ind;
ul_info_transfer_req_t ul_info_transfer_req;
ul_info_transfer_cnf_t ul_info_transfer_cnf;
ul_info_transfer_ind_t ul_info_transfer_ind;
dl_info_transfer_req_t dl_info_transfer_req;
dl_info_transfer_cnf_t dl_info_transfer_cnf;
dl_info_transfer_ind_t dl_info_transfer_ind;
rab_establish_req_t rab_establish_req;
rab_establish_ind_t rab_establish_ind;
rab_establish_rsp_t rab_establish_rsp;
rab_establish_cnf_t rab_establish_cnf;
rab_release_req_t rab_release_req;
rab_release_ind_t rab_release_ind;
} __attribute__((__packed__)) msg;
} as_message_t;
/****************************************************************************/
/******************** G L O B A L V A R I A B L E S ********************/
/****************************************************************************/
/****************************************************************************/
/****************** E X P O R T E D F U N C T I O N S ******************/
/****************************************************************************/
int as_message_decode(const char* buffer, as_message_t* msg, int length);
int as_message_encode(char* buffer, as_message_t* msg, int length);
/* Implemented in the network_api.c body file */
int as_message_send(as_message_t* as_msg);
#endif /* __AS_MESSAGE_H__*/
-29
View File
@@ -1,29 +0,0 @@
/*
* Licensed to the OpenAirInterface (OAI) Software Alliance under one or more
* contributor license agreements. See the NOTICE file distributed with
* this work for additional information regarding copyright ownership.
* The OpenAirInterface Software Alliance licenses this file to You under
* the OAI Public License, Version 1.1 (the "License"); you may not use this file
* except in compliance with the License.
* You may obtain a copy of the License at
*
* http://www.openairinterface.org/?page_id=698
*
* Unless required by applicable law or agreed to in writing, software
* distributed under the License is distributed on an "AS IS" BASIS,
* WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
* See the License for the specific language governing permissions and
* limitations under the License.
*-------------------------------------------------------------------------------
* For more information about the OpenAirInterface (OAI) Software Alliance:
* contact@openairinterface.org
*/
MESSAGE_DEF(GTPV1U_CREATE_TUNNEL_REQ, MESSAGE_PRIORITY_MED, Gtpv1uCreateTunnelReq, gtpv1uCreateTunnelReq)
MESSAGE_DEF(GTPV1U_CREATE_TUNNEL_RESP, MESSAGE_PRIORITY_MED, Gtpv1uCreateTunnelResp, gtpv1uCreateTunnelResp)
MESSAGE_DEF(GTPV1U_UPDATE_TUNNEL_REQ, MESSAGE_PRIORITY_MED, Gtpv1uUpdateTunnelReq, gtpv1uUpdateTunnelReq)
MESSAGE_DEF(GTPV1U_UPDATE_TUNNEL_RESP, MESSAGE_PRIORITY_MED, Gtpv1uUpdateTunnelResp, gtpv1uUpdateTunnelResp)
MESSAGE_DEF(GTPV1U_DELETE_TUNNEL_REQ, MESSAGE_PRIORITY_MED, Gtpv1uDeleteTunnelReq, gtpv1uDeleteTunnelReq)
MESSAGE_DEF(GTPV1U_DELETE_TUNNEL_RESP, MESSAGE_PRIORITY_MED, Gtpv1uDeleteTunnelResp, gtpv1uDeleteTunnelResp)
MESSAGE_DEF(GTPV1U_TUNNEL_DATA_IND, MESSAGE_PRIORITY_MED, Gtpv1uTunnelDataInd, gtpv1uTunnelDataInd)
MESSAGE_DEF(GTPV1U_TUNNEL_DATA_REQ, MESSAGE_PRIORITY_MED, Gtpv1uTunnelDataReq, gtpv1uTunnelDataReq)
-81
View File
@@ -1,81 +0,0 @@
/*
* Licensed to the OpenAirInterface (OAI) Software Alliance under one or more
* contributor license agreements. See the NOTICE file distributed with
* this work for additional information regarding copyright ownership.
* The OpenAirInterface Software Alliance licenses this file to You under
* the OAI Public License, Version 1.1 (the "License"); you may not use this file
* except in compliance with the License.
* You may obtain a copy of the License at
*
* http://www.openairinterface.org/?page_id=698
*
* Unless required by applicable law or agreed to in writing, software
* distributed under the License is distributed on an "AS IS" BASIS,
* WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
* See the License for the specific language governing permissions and
* limitations under the License.
*-------------------------------------------------------------------------------
* For more information about the OpenAirInterface (OAI) Software Alliance:
* contact@openairinterface.org
*/
#ifndef GTPV1_U_MESSAGES_TYPES_H_
#define GTPV1_U_MESSAGES_TYPES_H_
#include "../SGW-LITE/sgw_lite_ie_defs.h"
typedef struct {
Teid_t context_teid; ///< Tunnel Endpoint Identifier
ebi_t eps_bearer_id;
} Gtpv1uCreateTunnelReq;
typedef struct {
uint8_t status; ///< Status of S1U endpoint creation (Failed = 0xFF or Success = 0x0)
Teid_t context_teid; ///< local SGW S11 Tunnel Endpoint Identifier
Teid_t S1u_teid; ///< Tunnel Endpoint Identifier
ebi_t eps_bearer_id;
} Gtpv1uCreateTunnelResp;
typedef struct {
Teid_t context_teid; ///< S11 Tunnel Endpoint Identifier
Teid_t sgw_S1u_teid; ///< SGW S1U local Tunnel Endpoint Identifier
Teid_t enb_S1u_teid; ///< eNB S1U Tunnel Endpoint Identifier
ip_address_t enb_ip_address_for_S1u;
ebi_t eps_bearer_id;
} Gtpv1uUpdateTunnelReq;
typedef struct {
uint8_t status; ///< Status (Failed = 0xFF or Success = 0x0)
Teid_t context_teid; ///< S11 Tunnel Endpoint Identifier
Teid_t sgw_S1u_teid; ///< SGW S1U local Tunnel Endpoint Identifier
Teid_t enb_S1u_teid; ///< eNB S1U Tunnel Endpoint Identifier
ebi_t eps_bearer_id;
} Gtpv1uUpdateTunnelResp;
typedef struct {
Teid_t context_teid; ///< local SGW S11 Tunnel Endpoint Identifier
Teid_t S1u_teid; ///< local S1U Tunnel Endpoint Identifier to be deleted
} Gtpv1uDeleteTunnelReq;
typedef struct {
uint8_t status; ///< Status of S1U endpoint deleteion (Failed = 0xFF or Success = 0x0)
Teid_t context_teid; ///< local SGW S11 Tunnel Endpoint Identifier
Teid_t S1u_teid; ///< local S1U Tunnel Endpoint Identifier to be deleted
} Gtpv1uDeleteTunnelResp;
typedef struct {
uint8_t *buffer;
uint32_t length;
uint32_t offset; ///< start of message offset in buffer
Teid_t local_S1u_teid; ///< Tunnel Endpoint Identifier
} Gtpv1uTunnelDataInd;
typedef struct {
uint8_t *buffer;
uint32_t length;
uint32_t offset; ///< start of message offset in buffer
Teid_t local_S1u_teid; ///< Tunnel Endpoint Identifier
Teid_t S1u_enb_teid; ///< Tunnel Endpoint Identifier
} Gtpv1uTunnelDataReq;
#endif /* GTPV1_U_MESSAGES_TYPES_H_ */
-36
View File
@@ -1,36 +0,0 @@
/*
* Licensed to the OpenAirInterface (OAI) Software Alliance under one or more
* contributor license agreements. See the NOTICE file distributed with
* this work for additional information regarding copyright ownership.
* The OpenAirInterface Software Alliance licenses this file to You under
* the OAI Public License, Version 1.1 (the "License"); you may not use this file
* except in compliance with the License.
* You may obtain a copy of the License at
*
* http://www.openairinterface.org/?page_id=698
*
* Unless required by applicable law or agreed to in writing, software
* distributed under the License is distributed on an "AS IS" BASIS,
* WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
* See the License for the specific language governing permissions and
* limitations under the License.
*-------------------------------------------------------------------------------
* For more information about the OpenAirInterface (OAI) Software Alliance:
* contact@openairinterface.org
*/
// These messages files are mandatory and must always be placed in first position
#include "intertask_messages_def.h"
#include "timer_messages_def.h"
// Messages files used between tasks
#include "gtpv1_u_messages_def.h"
#include "ip_forward_messages_def.h"
#include "nas_messages_def.h"
#include "s11_messages_def.h"
#include "s1ap_messages_def.h"
#include "s6a_messages_def.h"
#include "sctp_messages_def.h"
#include "sgw_lite_def.h"
#include "udp_messages_def.h"
#include "mme_app_messages_def.h"
-63
View File
@@ -1,63 +0,0 @@
/*
* Licensed to the OpenAirInterface (OAI) Software Alliance under one or more
* contributor license agreements. See the NOTICE file distributed with
* this work for additional information regarding copyright ownership.
* The OpenAirInterface Software Alliance licenses this file to You under
* the OAI Public License, Version 1.1 (the "License"); you may not use this file
* except in compliance with the License.
* You may obtain a copy of the License at
*
* http://www.openairinterface.org/?page_id=698
*
* Unless required by applicable law or agreed to in writing, software
* distributed under the License is distributed on an "AS IS" BASIS,
* WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
* See the License for the specific language governing permissions and
* limitations under the License.
*-------------------------------------------------------------------------------
* For more information about the OpenAirInterface (OAI) Software Alliance:
* contact@openairinterface.org
*/
//WARNING: Do not include this header directly. Use intertask_interface.h instead.
// Messages for NAS logging
MESSAGE_DEF(NAS_DL_EMM_RAW_MSG, MESSAGE_PRIORITY_MED, nas_raw_msg_t, nas_dl_emm_raw_msg)
MESSAGE_DEF(NAS_UL_EMM_RAW_MSG, MESSAGE_PRIORITY_MED, nas_raw_msg_t, nas_ul_emm_raw_msg)
MESSAGE_DEF(NAS_DL_EMM_PLAIN_MSG, MESSAGE_PRIORITY_MED, nas_emm_plain_msg_t, nas_dl_emm_plain_msg)
MESSAGE_DEF(NAS_UL_EMM_PLAIN_MSG, MESSAGE_PRIORITY_MED, nas_emm_plain_msg_t, nas_ul_emm_plain_msg)
MESSAGE_DEF(NAS_DL_EMM_PROTECTED_MSG, MESSAGE_PRIORITY_MED, nas_emm_protected_msg_t, nas_dl_emm_protected_msg)
MESSAGE_DEF(NAS_UL_EMM_PROTECTED_MSG, MESSAGE_PRIORITY_MED, nas_emm_protected_msg_t, nas_ul_emm_protected_msg)
MESSAGE_DEF(NAS_DL_ESM_RAW_MSG, MESSAGE_PRIORITY_MED, nas_raw_msg_t, nas_dl_esm_raw_msg)
MESSAGE_DEF(NAS_UL_ESM_RAW_MSG, MESSAGE_PRIORITY_MED, nas_raw_msg_t, nas_ul_esm_raw_msg)
MESSAGE_DEF(NAS_DL_ESM_PLAIN_MSG, MESSAGE_PRIORITY_MED, nas_esm_plain_msg_t, nas_dl_esm_plain_msg)
MESSAGE_DEF(NAS_UL_ESM_PLAIN_MSG, MESSAGE_PRIORITY_MED, nas_esm_plain_msg_t, nas_ul_esm_plain_msg)
MESSAGE_DEF(NAS_DL_ESM_PROTECTED_MSG, MESSAGE_PRIORITY_MED, nas_esm_protected_msg_t, nas_dl_esm_protected_msg)
MESSAGE_DEF(NAS_UL_ESM_PROTECTED_MSG, MESSAGE_PRIORITY_MED, nas_esm_protected_msg_t, nas_ul_esm_protected_msg)
/* */
MESSAGE_DEF(NAS_PAGING_IND, MESSAGE_PRIORITY_MED, nas_paging_ind_t, nas_paging_ind)
MESSAGE_DEF(NAS_PDN_CONNECTIVITY_REQ, MESSAGE_PRIORITY_MED, nas_pdn_connectivity_req_t, nas_pdn_connectivity_req)
MESSAGE_DEF(NAS_CONNECTION_ESTABLISHMENT_IND, MESSAGE_PRIORITY_MED, nas_conn_est_ind_t, nas_conn_est_ind)
MESSAGE_DEF(NAS_CONNECTION_ESTABLISHMENT_CNF, MESSAGE_PRIORITY_MED, nas_conn_est_cnf_t, nas_conn_est_cnf)
MESSAGE_DEF(NAS_CONNECTION_RELEASE_IND, MESSAGE_PRIORITY_MED, nas_conn_rel_ind_t, nas_conn_rel_ind)
MESSAGE_DEF(NAS_UPLINK_DATA_IND, MESSAGE_PRIORITY_MED, nas_ul_data_ind_t, nas_ul_data_ind)
MESSAGE_DEF(NAS_DOWNLINK_DATA_REQ, MESSAGE_PRIORITY_MED, nas_dl_data_req_t, nas_dl_data_req)
MESSAGE_DEF(NAS_DOWNLINK_DATA_CNF, MESSAGE_PRIORITY_MED, nas_dl_data_cnf_t, nas_dl_data_cnf)
MESSAGE_DEF(NAS_DOWNLINK_DATA_REJ, MESSAGE_PRIORITY_MED, nas_dl_data_rej_t, nas_dl_data_rej)
MESSAGE_DEF(NAS_RAB_ESTABLISHMENT_REQ, MESSAGE_PRIORITY_MED, nas_rab_est_req_t, nas_rab_est_req)
MESSAGE_DEF(NAS_RAB_ESTABLISHMENT_RESP, MESSAGE_PRIORITY_MED, nas_rab_est_rsp_t, nas_rab_est_rsp)
MESSAGE_DEF(NAS_RAB_RELEASE_REQ, MESSAGE_PRIORITY_MED, nas_rab_rel_req_t, nas_rab_rel_req)
/* NAS layer -> MME app messages */
MESSAGE_DEF(NAS_AUTHENTICATION_PARAM_REQ, MESSAGE_PRIORITY_MED, nas_auth_param_req_t, nas_auth_param_req)
/* MME app -> NAS layer messages */
MESSAGE_DEF(NAS_PDN_CONNECTIVITY_RSP, MESSAGE_PRIORITY_MED, nas_pdn_connectivity_rsp_t, nas_pdn_connectivity_rsp)
MESSAGE_DEF(NAS_PDN_CONNECTIVITY_FAIL, MESSAGE_PRIORITY_MED, nas_pdn_connectivity_fail_t, nas_pdn_connectivity_fail)
MESSAGE_DEF(NAS_AUTHENTICATION_PARAM_RSP, MESSAGE_PRIORITY_MED, nas_auth_param_rsp_t, nas_auth_param_rsp)
MESSAGE_DEF(NAS_AUTHENTICATION_PARAM_FAIL, MESSAGE_PRIORITY_MED, nas_auth_param_fail_t, nas_auth_param_fail)
-329
View File
@@ -1,329 +0,0 @@
/*
* Licensed to the OpenAirInterface (OAI) Software Alliance under one or more
* contributor license agreements. See the NOTICE file distributed with
* this work for additional information regarding copyright ownership.
* The OpenAirInterface Software Alliance licenses this file to You under
* the OAI Public License, Version 1.1 (the "License"); you may not use this file
* except in compliance with the License.
* You may obtain a copy of the License at
*
* http://www.openairinterface.org/?page_id=698
*
* Unless required by applicable law or agreed to in writing, software
* distributed under the License is distributed on an "AS IS" BASIS,
* WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
* See the License for the specific language governing permissions and
* limitations under the License.
*-------------------------------------------------------------------------------
* For more information about the OpenAirInterface (OAI) Software Alliance:
* contact@openairinterface.org
*/
#include "as_message.h"
#include "nas_message.h"
#ifndef NAS_MESSAGES_TYPES_H_
#define NAS_MESSAGES_TYPES_H_
#define NAS_DL_EMM_RAW_MSG(mSGpTR) (mSGpTR)->ittiMsg.nas_dl_emm_raw_msg
#define NAS_UL_EMM_RAW_MSG(mSGpTR) (mSGpTR)->ittiMsg.nas_ul_emm_raw_msg
#define NAS_DL_EMM_PROTECTED_MSG(mSGpTR) (mSGpTR)->ittiMsg.nas_dl_emm_protected_msg
#define NAS_UL_EMM_PROTECTED_MSG(mSGpTR) (mSGpTR)->ittiMsg.nas_ul_emm_protected_msg
#define NAS_DL_EMM_PLAIN_MSG(mSGpTR) (mSGpTR)->ittiMsg.nas_dl_emm_plain_msg
#define NAS_UL_EMM_PLAIN_MSG(mSGpTR) (mSGpTR)->ittiMsg.nas_ul_emm_plain_msg
#define NAS_DL_ESM_RAW_MSG(mSGpTR) (mSGpTR)->ittiMsg.nas_dl_esm_raw_msg
#define NAS_UL_ESM_RAW_MSG(mSGpTR) (mSGpTR)->ittiMsg.nas_ul_esm_raw_msg
#define NAS_DL_ESM_PROTECTED_MSG(mSGpTR) (mSGpTR)->ittiMsg.nas_dl_esm_protected_msg
#define NAS_UL_ESM_PROTECTED_MSG(mSGpTR) (mSGpTR)->ittiMsg.nas_ul_esm_protected_msg
#define NAS_DL_ESM_PLAIN_MSG(mSGpTR) (mSGpTR)->ittiMsg.nas_dl_esm_plain_msg
#define NAS_UL_ESM_PLAIN_MSG(mSGpTR) (mSGpTR)->ittiMsg.nas_ul_esm_plain_msg
#define NAS_UL_DATA_IND(mSGpTR) (mSGpTR)->ittiMsg.nas_ul_data_ind
#define NAS_DL_DATA_REQ(mSGpTR) (mSGpTR)->ittiMsg.nas_dl_data_req
#define NAS_DL_DATA_CNF(mSGpTR) (mSGpTR)->ittiMsg.nas_dl_data_cnf
#define NAS_DL_DATA_REJ(mSGpTR) (mSGpTR)->ittiMsg.nas_dl_data_rej
#define NAS_PDN_CONNECTIVITY_REQ(mSGpTR) (mSGpTR)->ittiMsg.nas_pdn_connectivity_req
#define NAS_PDN_CONNECTIVITY_RSP(mSGpTR) (mSGpTR)->ittiMsg.nas_pdn_connectivity_rsp
#define NAS_PDN_CONNECTIVITY_FAIL(mSGpTR) (mSGpTR)->ittiMsg.nas_pdn_connectivity_fail
#define NAS_CONN_EST_IND(mSGpTR) (mSGpTR)->ittiMsg.nas_conn_est_ind
#define NAS_CONNECTION_ESTABLISHMENT_CNF(mSGpTR) (mSGpTR)->ittiMsg.nas_conn_est_cnf
#define NAS_BEARER_PARAM(mSGpTR) (mSGpTR)->ittiMsg.nas_bearer_param
#define NAS_AUTHENTICATION_REQ(mSGpTR) (mSGpTR)->ittiMsg.nas_auth_req
#define NAS_AUTHENTICATION_PARAM_REQ(mSGpTR) (mSGpTR)->ittiMsg.nas_auth_param_req
#define NAS_AUTHENTICATION_PARAM_RSP(mSGpTR) (mSGpTR)->ittiMsg.nas_auth_param_rsp
#define NAS_AUTHENTICATION_PARAM_FAIL(mSGpTR) (mSGpTR)->ittiMsg.nas_auth_param_fail
#define NAS_DATA_LENGHT_MAX 256
typedef enum {
EMM_MSG_HEADER = 1,
EMM_MSG_ATTACH_REQUEST,
EMM_MSG_ATTACH_ACCEPT,
EMM_MSG_ATTACH_COMPLETE,
EMM_MSG_ATTACH_REJECT,
EMM_MSG_DETACH_REQUEST,
EMM_MSG_DETACH_ACCEPT,
EMM_MSG_TRACKING_AREA_UPDATE_REQUEST,
EMM_MSG_TRACKING_AREA_UPDATE_ACCEPT,
EMM_MSG_TRACKING_AREA_UPDATE_COMPLETE,
EMM_MSG_TRACKING_AREA_UPDATE_REJECT,
EMM_MSG_EXTENDED_SERVICE_REQUEST,
EMM_MSG_SERVICE_REQUEST,
EMM_MSG_SERVICE_REJECT,
EMM_MSG_GUTI_REALLOCATION_COMMAND,
EMM_MSG_GUTI_REALLOCATION_COMPLETE,
EMM_MSG_AUTHENTICATION_REQUEST,
EMM_MSG_AUTHENTICATION_RESPONSE,
EMM_MSG_AUTHENTICATION_REJECT,
EMM_MSG_AUTHENTICATION_FAILURE,
EMM_MSG_IDENTITY_REQUEST,
EMM_MSG_IDENTITY_RESPONSE,
EMM_MSG_SECURITY_MODE_COMMAND,
EMM_MSG_SECURITY_MODE_COMPLETE,
EMM_MSG_SECURITY_MODE_REJECT,
EMM_MSG_EMM_STATUS,
EMM_MSG_EMM_INFORMATION,
EMM_MSG_DOWNLINK_NAS_TRANSPORT,
EMM_MSG_UPLINK_NAS_TRANSPORT,
EMM_MSG_CS_SERVICE_NOTIFICATION,
} emm_message_ids_t;
typedef enum {
ESM_MSG_HEADER = 1,
ESM_MSG_ACTIVATE_DEFAULT_EPS_BEARER_CONTEXT_REQUEST,
ESM_MSG_ACTIVATE_DEFAULT_EPS_BEARER_CONTEXT_ACCEPT,
ESM_MSG_ACTIVATE_DEFAULT_EPS_BEARER_CONTEXT_REJECT,
ESM_MSG_ACTIVATE_DEDICATED_EPS_BEARER_CONTEXT_REQUEST,
ESM_MSG_ACTIVATE_DEDICATED_EPS_BEARER_CONTEXT_ACCEPT,
ESM_MSG_ACTIVATE_DEDICATED_EPS_BEARER_CONTEXT_REJECT,
ESM_MSG_MODIFY_EPS_BEARER_CONTEXT_REQUEST,
ESM_MSG_MODIFY_EPS_BEARER_CONTEXT_ACCEPT,
ESM_MSG_MODIFY_EPS_BEARER_CONTEXT_REJECT,
ESM_MSG_DEACTIVATE_EPS_BEARER_CONTEXT_REQUEST,
ESM_MSG_DEACTIVATE_EPS_BEARER_CONTEXT_ACCEPT,
ESM_MSG_PDN_CONNECTIVITY_REQUEST,
ESM_MSG_PDN_CONNECTIVITY_REJECT,
ESM_MSG_PDN_DISCONNECT_REQUEST,
ESM_MSG_PDN_DISCONNECT_REJECT,
ESM_MSG_BEARER_RESOURCE_ALLOCATION_REQUEST,
ESM_MSG_BEARER_RESOURCE_ALLOCATION_REJECT,
ESM_MSG_BEARER_RESOURCE_MODIFICATION_REQUEST,
ESM_MSG_BEARER_RESOURCE_MODIFICATION_REJECT,
ESM_MSG_ESM_INFORMATION_REQUEST,
ESM_MSG_ESM_INFORMATION_RESPONSE,
ESM_MSG_ESM_STATUS,
} esm_message_ids_t;
typedef struct nas_raw_msg_s {
uint32_t lenght;
uint8_t data[NAS_DATA_LENGHT_MAX];
} nas_raw_msg_t;
typedef struct nas_emm_plain_msg_s {
emm_message_ids_t present;
EMM_msg choice;
} nas_emm_plain_msg_t;
typedef struct nas_emm_protected_msg_s {
nas_message_security_header_t header;
emm_message_ids_t present;
EMM_msg choice;
} nas_emm_protected_msg_t;
typedef struct nas_esm_plain_msg_s {
esm_message_ids_t present;
ESM_msg choice;
} nas_esm_plain_msg_t;
typedef struct nas_esm_protected_msg_s {
nas_message_security_header_t header;
esm_message_ids_t present;
ESM_msg choice;
} nas_esm_protected_msg_t;
typedef struct nas_paging_ind_s {
} nas_paging_ind_t;
typedef struct nas_pdn_connectivity_req_s {
int pti; // nas ref Identity of the procedure transaction executed to activate the PDN connection entry
unsigned ue_id; // nas ref
char imsi[16];
uint8_t imsi_length;
network_qos_t qos;
pco_flat_t pco;
OctetString apn;
OctetString pdn_addr;
int pdn_type;
void *proc_data;
int request_type;
} nas_pdn_connectivity_req_t;
typedef struct nas_pdn_connectivity_rsp_s {
int pti; // nas ref Identity of the procedure transaction executed to activate the PDN connection entry
unsigned ue_id; // nas ref
network_qos_t qos;
pco_flat_t pco;
OctetString apn;
OctetString pdn_addr;
int pdn_type;
void *proc_data;
int request_type;
unsigned eNB_ue_s1ap_id:24;
uint32_t mme_ue_s1ap_id;
/* Key eNB */
//uint8_t keNB[32];
ambr_t ambr;
ambr_t apn_ambr;
/* EPS bearer ID */
unsigned ebi:4;
/* QoS */
qci_t qci;
priority_level_t prio_level;
pre_emp_vulnerability_t pre_emp_vulnerability;
pre_emp_capability_t pre_emp_capability;
/* S-GW TEID for user-plane */
Teid_t sgw_s1u_teid;
/* S-GW IP address for User-Plane */
ip_address_t sgw_s1u_address;
} nas_pdn_connectivity_rsp_t;
typedef struct nas_pdn_connectivity_fail_s {
unsigned ue_id; // nas ref
} nas_pdn_connectivity_fail_t;
typedef struct nas_conn_est_ind_s {
nas_establish_ind_t nas;
/* Transparent message from s1ap to be forwarded to MME_APP or
* to S1AP if connection establishment is rejected by NAS.
*/
s1ap_initial_ue_message_t transparent;
} nas_conn_est_ind_t;
typedef nas_establish_rsp_t nas_conn_est_rej_t;
typedef nas_establish_cnf_t nas_conn_est_cnf_t;
typedef struct nas_conn_rel_ind_s {
} nas_conn_rel_ind_t;
typedef ul_info_transfer_ind_t nas_ul_data_ind_t;
typedef dl_info_transfer_req_t nas_dl_data_req_t;
typedef dl_info_transfer_cnf_t nas_dl_data_cnf_t;
typedef struct nas_dl_data_rej_s {
uint32_t UEid; /* UE lower layer identifier */
as_nas_info_t nasMsg; /* Uplink NAS message */
} nas_dl_data_rej_t;
typedef struct nas_rab_est_req_s {
} nas_rab_est_req_t;
typedef struct nas_rab_est_rsp_s {
} nas_rab_est_rsp_t;
typedef struct nas_rab_rel_req_s {
} nas_rab_rel_req_t;
typedef struct nas_attach_req_s {
/* TODO: Set the correct size */
char apn[100];
char imsi[16];
#define INITIAL_REQUEST (0x1)
unsigned initial:1;
s1ap_initial_ue_message_t transparent;
} nas_attach_req_t;
typedef struct nas_auth_req_s {
/* UE imsi */
char imsi[16];
#define NAS_FAILURE_OK 0x0
#define NAS_FAILURE_IND 0x1
unsigned failure:1;
int cause;
} nas_auth_req_t;
typedef struct nas_auth_resp_s {
char imsi[16];
} nas_auth_resp_t;
typedef struct nas_auth_param_req_s {
/* UE identifier */
uint32_t ue_id;
/* Imsi of the UE (In case of initial request) */
char imsi[16];
uint8_t imsi_length;
/* Indicates whether the procedure corresponds to a new connection or not */
uint8_t initial_req:1;
uint8_t re_synchronization:1;
uint8_t auts[14];
} nas_auth_param_req_t;
typedef struct nas_auth_param_rsp_s {
/* UE identifier */
uint32_t ue_id;
/* For future use: nb of vectors provided */
uint8_t nb_vectors;
/* Consider only one E-UTRAN vector for the moment... */
eutran_vector_t vector;
} nas_auth_param_rsp_t;
typedef struct nas_auth_param_fail_s {
/* UE identifier */
uint32_t ue_id;
/* S6A mapped to NAS cause */
nas_cause_t cause;
} nas_auth_param_fail_t;
#endif /* NAS_MESSAGES_TYPES_H_ */
-42
View File
@@ -1,42 +0,0 @@
/*
* Licensed to the OpenAirInterface (OAI) Software Alliance under one or more
* contributor license agreements. See the NOTICE file distributed with
* this work for additional information regarding copyright ownership.
* The OpenAirInterface Software Alliance licenses this file to You under
* the OAI Public License, Version 1.1 (the "License"); you may not use this file
* except in compliance with the License.
* You may obtain a copy of the License at
*
* http://www.openairinterface.org/?page_id=698
*
* Unless required by applicable law or agreed to in writing, software
* distributed under the License is distributed on an "AS IS" BASIS,
* WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
* See the License for the specific language governing permissions and
* limitations under the License.
*-------------------------------------------------------------------------------
* For more information about the OpenAirInterface (OAI) Software Alliance:
* contact@openairinterface.org
*/
//WARNING: Do not include this header directly. Use intertask_interface.h instead.
/* Messages for S1AP logging */
MESSAGE_DEF(S1AP_UPLINK_NAS_LOG , MESSAGE_PRIORITY_MED, IttiMsgText , s1ap_uplink_nas_log)
MESSAGE_DEF(S1AP_UE_CAPABILITY_IND_LOG , MESSAGE_PRIORITY_MED, IttiMsgText , s1ap_ue_capability_ind_log)
MESSAGE_DEF(S1AP_INITIAL_CONTEXT_SETUP_LOG , MESSAGE_PRIORITY_MED, IttiMsgText , s1ap_initial_context_setup_log)
MESSAGE_DEF(S1AP_NAS_NON_DELIVERY_IND_LOG , MESSAGE_PRIORITY_MED, IttiMsgText , s1ap_nas_non_delivery_ind_log)
MESSAGE_DEF(S1AP_DOWNLINK_NAS_LOG , MESSAGE_PRIORITY_MED, IttiMsgText , s1ap_downlink_nas_log)
MESSAGE_DEF(S1AP_S1_SETUP_LOG , MESSAGE_PRIORITY_MED, IttiMsgText , s1ap_s1_setup_log)
MESSAGE_DEF(S1AP_INITIAL_UE_MESSAGE_LOG , MESSAGE_PRIORITY_MED, IttiMsgText , s1ap_initial_ue_message_log)
MESSAGE_DEF(S1AP_UE_CONTEXT_RELEASE_REQ_LOG, MESSAGE_PRIORITY_MED, IttiMsgText , s1ap_ue_context_release_req_log)
MESSAGE_DEF(S1AP_UE_CONTEXT_RELEASE_COMMAND_LOG, MESSAGE_PRIORITY_MED, IttiMsgText , s1ap_ue_context_release_command_log)
MESSAGE_DEF(S1AP_UE_CONTEXT_RELEASE_LOG , MESSAGE_PRIORITY_MED, IttiMsgText , s1ap_ue_context_release_log)
MESSAGE_DEF(S1AP_ERROR_INDICATION_LOG , MESSAGE_PRIORITY_MED, IttiMsgText , s1ap_error_indication_log)
MESSAGE_DEF(S1AP_UE_CAPABILITIES_IND , MESSAGE_PRIORITY_MED, s1ap_ue_cap_ind_t , s1ap_ue_cap_ind)
MESSAGE_DEF(S1AP_ENB_DEREGISTERED_IND , MESSAGE_PRIORITY_MED, s1ap_eNB_deregistered_ind_t , s1ap_eNB_deregistered_ind)
MESSAGE_DEF(S1AP_DEREGISTER_UE_REQ , MESSAGE_PRIORITY_MED, s1ap_deregister_ue_req_t , s1ap_deregister_ue_req)
MESSAGE_DEF(S1AP_UE_CONTEXT_RELEASE_REQ , MESSAGE_PRIORITY_MED, s1ap_ue_context_release_req_t , s1ap_ue_context_release_req)
MESSAGE_DEF(S1AP_UE_CONTEXT_RELEASE_COMMAND, MESSAGE_PRIORITY_MED, s1ap_ue_context_release_command_t, s1ap_ue_context_release_command)
MESSAGE_DEF(S1AP_UE_CONTEXT_RELEASE_COMPLETE, MESSAGE_PRIORITY_MED, s1ap_ue_context_release_complete_t, s1ap_ue_context_release_complete)
-91
View File
@@ -1,91 +0,0 @@
/*
* Licensed to the OpenAirInterface (OAI) Software Alliance under one or more
* contributor license agreements. See the NOTICE file distributed with
* this work for additional information regarding copyright ownership.
* The OpenAirInterface Software Alliance licenses this file to You under
* the OAI Public License, Version 1.1 (the "License"); you may not use this file
* except in compliance with the License.
* You may obtain a copy of the License at
*
* http://www.openairinterface.org/?page_id=698
*
* Unless required by applicable law or agreed to in writing, software
* distributed under the License is distributed on an "AS IS" BASIS,
* WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
* See the License for the specific language governing permissions and
* limitations under the License.
*-------------------------------------------------------------------------------
* For more information about the OpenAirInterface (OAI) Software Alliance:
* contact@openairinterface.org
*/
#ifndef S1AP_MESSAGES_TYPES_H_
#define S1AP_MESSAGES_TYPES_H_
#define S1AP_ENB_DEREGISTERED_IND(mSGpTR) (mSGpTR)->ittiMsg.s1ap_eNB_deregistered_ind
#define S1AP_DEREGISTER_UE_REQ(mSGpTR) (mSGpTR)->ittiMsg.s1ap_deregister_ue_req
#define S1AP_UE_CONTEXT_RELEASE_REQ(mSGpTR) (mSGpTR)->ittiMsg.s1ap_ue_context_release_req
#define S1AP_UE_CONTEXT_RELEASE_COMMAND(mSGpTR) (mSGpTR)->ittiMsg.s1ap_ue_context_release_command
#define S1AP_UE_CONTEXT_RELEASE_COMPLETE(mSGpTR) (mSGpTR)->ittiMsg.s1ap_ue_context_release_complete
typedef struct s1ap_initial_ue_message_s {
unsigned eNB_ue_s1ap_id:24;
uint32_t mme_ue_s1ap_id;
cgi_t e_utran_cgi;
} s1ap_initial_ue_message_t;
typedef struct s1ap_initial_ctxt_setup_req_s {
unsigned eNB_ue_s1ap_id:24;
uint32_t mme_ue_s1ap_id;
/* Key eNB */
uint8_t keNB[32];
ambr_t ambr;
ambr_t apn_ambr;
/* EPS bearer ID */
unsigned ebi:4;
/* QoS */
qci_t qci;
priority_level_t prio_level;
pre_emp_vulnerability_t pre_emp_vulnerability;
pre_emp_capability_t pre_emp_capability;
/* S-GW TEID for user-plane */
Teid_t teid;
/* S-GW IP address for User-Plane */
ip_address_t s_gw_address;
} s1ap_initial_ctxt_setup_req_t;
typedef struct s1ap_ue_cap_ind_s {
unsigned eNB_ue_s1ap_id:24;
uint32_t mme_ue_s1ap_id;
uint8_t radio_capabilities[100];
uint32_t radio_capabilities_length;
} s1ap_ue_cap_ind_t;
#define S1AP_ITTI_UE_PER_DEREGISTER_MESSAGE 20
typedef struct s1ap_eNB_deregistered_ind_s {
uint8_t nb_ue_to_deregister;
uint32_t mme_ue_s1ap_id[S1AP_ITTI_UE_PER_DEREGISTER_MESSAGE];
} s1ap_eNB_deregistered_ind_t;
typedef struct s1ap_deregister_ue_req_s {
uint32_t mme_ue_s1ap_id;
} s1ap_deregister_ue_req_t;
typedef struct s1ap_ue_context_release_req_s {
uint32_t mme_ue_s1ap_id;
} s1ap_ue_context_release_req_t;
typedef struct s1ap_ue_context_release_command_s {
uint32_t mme_ue_s1ap_id;
} s1ap_ue_context_release_command_t;
typedef struct s1ap_ue_context_release_complete_s {
uint32_t mme_ue_s1ap_id;
} s1ap_ue_context_release_complete_t;
#endif /* S1AP_MESSAGES_TYPES_H_ */
-28
View File
@@ -1,28 +0,0 @@
/*
* Licensed to the OpenAirInterface (OAI) Software Alliance under one or more
* contributor license agreements. See the NOTICE file distributed with
* this work for additional information regarding copyright ownership.
* The OpenAirInterface Software Alliance licenses this file to You under
* the OAI Public License, Version 1.1 (the "License"); you may not use this file
* except in compliance with the License.
* You may obtain a copy of the License at
*
* http://www.openairinterface.org/?page_id=698
*
* Unless required by applicable law or agreed to in writing, software
* distributed under the License is distributed on an "AS IS" BASIS,
* WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
* See the License for the specific language governing permissions and
* limitations under the License.
*-------------------------------------------------------------------------------
* For more information about the OpenAirInterface (OAI) Software Alliance:
* contact@openairinterface.org
*/
//WARNING: Do not include this header directly. Use intertask_interface.h instead.
MESSAGE_DEF(SCTP_INIT_MSG, MESSAGE_PRIORITY_MED, SctpInit, sctpInit)
MESSAGE_DEF(SCTP_DATA_REQ, MESSAGE_PRIORITY_MED, sctp_data_req_t, sctp_data_req)
MESSAGE_DEF(SCTP_DATA_IND, MESSAGE_PRIORITY_MED, sctp_data_ind_t, sctp_data_ind)
MESSAGE_DEF(SCTP_NEW_ASSOCIATION, MESSAGE_PRIORITY_MAX, sctp_new_peer_t, sctp_new_peer)
MESSAGE_DEF(SCTP_CLOSE_ASSOCIATION, MESSAGE_PRIORITY_MAX, sctp_close_association_t, sctp_close_association)
-69
View File
@@ -1,69 +0,0 @@
/*
* Licensed to the OpenAirInterface (OAI) Software Alliance under one or more
* contributor license agreements. See the NOTICE file distributed with
* this work for additional information regarding copyright ownership.
* The OpenAirInterface Software Alliance licenses this file to You under
* the OAI Public License, Version 1.1 (the "License"); you may not use this file
* except in compliance with the License.
* You may obtain a copy of the License at
*
* http://www.openairinterface.org/?page_id=698
*
* Unless required by applicable law or agreed to in writing, software
* distributed under the License is distributed on an "AS IS" BASIS,
* WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
* See the License for the specific language governing permissions and
* limitations under the License.
*-------------------------------------------------------------------------------
* For more information about the OpenAirInterface (OAI) Software Alliance:
* contact@openairinterface.org
*/
#ifndef SCTP_MESSAGES_TYPES_H_
#define SCTP_MESSAGES_TYPES_H_
#define SCTP_DATA_IND(mSGpTR) (mSGpTR)->ittiMsg.sctp_data_ind
#define SCTP_DATA_REQ(mSGpTR) (mSGpTR)->ittiMsg.sctp_data_req
#define SCTP_INIT_MSG(mSGpTR) (mSGpTR)->ittiMsg.sctpInit
#define SCTP_CLOSE_ASSOCIATION(mSGpTR) (mSGpTR)->ittiMsg.sctp_close_association
typedef struct sctp_data_req_s {
uint8_t *buffer;
uint32_t bufLen;
uint32_t assocId;
uint16_t stream;
} sctp_data_req_t;
typedef struct sctp_data_ind_s {
uint8_t *buffer; ///< SCTP buffer
uint32_t buf_length; ///< SCTP buffer length
int32_t assoc_id; ///< SCTP physical association ID
uint8_t stream; ///< Stream number on which data had been received
uint16_t instreams; ///< Number of input streams for the SCTP connection between peers
uint16_t outstreams; ///< Number of output streams for the SCTP connection between peers
} sctp_data_ind_t;
typedef struct sctp_init_s {
/* Request usage of ipv4 */
unsigned ipv4:1;
/* Request usage of ipv6 */
unsigned ipv6:1;
uint8_t nb_ipv4_addr;
uint32_t ipv4_address[10];
uint8_t nb_ipv6_addr;
char *ipv6_address[10];
uint16_t port;
uint32_t ppid;
} SctpInit;
typedef struct sctp_close_association_s {
uint32_t assoc_id;
} sctp_close_association_t;
typedef struct sctp_new_peer_s {
uint32_t instreams;
uint32_t outstreams;
uint32_t assoc_id;
} sctp_new_peer_t;
#endif /* SCTP_MESSAGES_TYPES_H_ */
-48
View File
@@ -1,48 +0,0 @@
/*
* Licensed to the OpenAirInterface (OAI) Software Alliance under one or more
* contributor license agreements. See the NOTICE file distributed with
* this work for additional information regarding copyright ownership.
* The OpenAirInterface Software Alliance licenses this file to You under
* the OAI Public License, Version 1.1 (the "License"); you may not use this file
* except in compliance with the License.
* You may obtain a copy of the License at
*
* http://www.openairinterface.org/?page_id=698
*
* Unless required by applicable law or agreed to in writing, software
* distributed under the License is distributed on an "AS IS" BASIS,
* WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
* See the License for the specific language governing permissions and
* limitations under the License.
*-------------------------------------------------------------------------------
* For more information about the OpenAirInterface (OAI) Software Alliance:
* contact@openairinterface.org
*/
// This task is mandatory and must always be placed in first position
TASK_DEF(TASK_TIMER, TASK_PRIORITY_MED, 10)
// Other possible tasks in the process
/// GTPV1-U task
TASK_DEF(TASK_GTPV1_U, TASK_PRIORITY_MED, 200)
/// FW_IP task
TASK_DEF(TASK_FW_IP, TASK_PRIORITY_MED, 200)
/// MME Applicative task
TASK_DEF(TASK_MME_APP, TASK_PRIORITY_MED, 200)
/// NAS task
TASK_DEF(TASK_NAS_MME, TASK_PRIORITY_MED, 200)
/// S11 task
TASK_DEF(TASK_S11, TASK_PRIORITY_MED, 200)
/// S1AP task
TASK_DEF(TASK_S1AP, TASK_PRIORITY_MED, 200)
/// S6a task
TASK_DEF(TASK_S6A, TASK_PRIORITY_MED, 200)
/// SCTP task
TASK_DEF(TASK_SCTP, TASK_PRIORITY_MED, 200)
/// Serving and Proxy Gateway Application task
TASK_DEF(TASK_SPGW_APP, TASK_PRIORITY_MED, 200)
/// UDP task
TASK_DEF(TASK_UDP, TASK_PRIORITY_MED, 200)
//MESSAGE GENERATOR TASK
TASK_DEF(TASK_MSC, TASK_PRIORITY_MED, 200)
-24
View File
@@ -1,24 +0,0 @@
/*
* Licensed to the OpenAirInterface (OAI) Software Alliance under one or more
* contributor license agreements. See the NOTICE file distributed with
* this work for additional information regarding copyright ownership.
* The OpenAirInterface Software Alliance licenses this file to You under
* the OAI Public License, Version 1.1 (the "License"); you may not use this file
* except in compliance with the License.
* You may obtain a copy of the License at
*
* http://www.openairinterface.org/?page_id=698
*
* Unless required by applicable law or agreed to in writing, software
* distributed under the License is distributed on an "AS IS" BASIS,
* WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
* See the License for the specific language governing permissions and
* limitations under the License.
*-------------------------------------------------------------------------------
* For more information about the OpenAirInterface (OAI) Software Alliance:
* contact@openairinterface.org
*/
MESSAGE_DEF(UDP_INIT, MESSAGE_PRIORITY_MED, udp_init_t, udp_init)
MESSAGE_DEF(UDP_DATA_REQ, MESSAGE_PRIORITY_MED, udp_data_req_t, udp_data_req)
MESSAGE_DEF(UDP_DATA_IND, MESSAGE_PRIORITY_MED, udp_data_ind_t, udp_data_ind)
-47
View File
@@ -1,47 +0,0 @@
/*
* Licensed to the OpenAirInterface (OAI) Software Alliance under one or more
* contributor license agreements. See the NOTICE file distributed with
* this work for additional information regarding copyright ownership.
* The OpenAirInterface Software Alliance licenses this file to You under
* the OAI Public License, Version 1.1 (the "License"); you may not use this file
* except in compliance with the License.
* You may obtain a copy of the License at
*
* http://www.openairinterface.org/?page_id=698
*
* Unless required by applicable law or agreed to in writing, software
* distributed under the License is distributed on an "AS IS" BASIS,
* WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
* See the License for the specific language governing permissions and
* limitations under the License.
*-------------------------------------------------------------------------------
* For more information about the OpenAirInterface (OAI) Software Alliance:
* contact@openairinterface.org
*/
#ifndef UDP_MESSAGES_TYPES_H_
#define UDP_MESSAGES_TYPES_H_
#define UDP_INIT(mSGpTR) (mSGpTR)->ittiMsg.udp_init
typedef struct {
uint32_t port;
char *address;
} udp_init_t;
typedef struct {
uint8_t *buffer;
uint32_t buffer_length;
uint32_t buffer_offset;
uint32_t peer_address;
uint32_t peer_port;
} udp_data_req_t;
typedef struct {
uint8_t *buffer;
uint32_t buffer_length;
uint32_t peer_address;
uint32_t peer_port;
} udp_data_ind_t;
#endif /* UDP_MESSAGES_TYPES_H_ */