Add an initial code for PFCP

This commit is contained in:
Sukchan Lee 2019-12-01 21:40:52 +09:00
parent ce6d2c5889
commit 4e2d7bf708
32 changed files with 4795 additions and 288 deletions

File diff suppressed because it is too large Load Diff

View File

@ -20,7 +20,7 @@
/*******************************************************************************
* This file had been created by gtp-tlv.py script v0.1.0
* Please do not modify this file but regenerate it via script.
* Created on: 2019-12-01 20:43:32.876644 by acetcom
* Created on: 2019-12-01 21:10:09.844182 by acetcom
* from 29274-d80.docx
******************************************************************************/
@ -130,128 +130,128 @@ typedef struct ogs_gtp_header_s {
#define OGS_GTP_MODIFY_ACCESS_BEARERS_REQUEST_TYPE 211
#define OGS_GTP_MODIFY_ACCESS_BEARERS_RESPONSE_TYPE 212
#define OGS_TLV_IMSI_TYPE 1
#define OGS_TLV_CAUSE_TYPE 2
#define OGS_TLV_RECOVERY_TYPE 3
#define OGS_TLV_STN_SR_TYPE 51
#define OGS_TLV_APN_TYPE 71
#define OGS_TLV_AMBR_TYPE 72
#define OGS_TLV_EBI_TYPE 73
#define OGS_TLV_IP_ADDRESS_TYPE 74
#define OGS_TLV_MEI_TYPE 75
#define OGS_TLV_MSISDN_TYPE 76
#define OGS_TLV_INDICATION_TYPE 77
#define OGS_TLV_PCO_TYPE 78
#define OGS_TLV_PAA_TYPE 79
#define OGS_TLV_BEARER_QOS_TYPE 80
#define OGS_TLV_FLOW_QOS_TYPE 81
#define OGS_TLV_RAT_TYPE_TYPE 82
#define OGS_TLV_SERVING_NETWORK_TYPE 83
#define OGS_TLV_BEARER_TFT_TYPE 84
#define OGS_TLV_TAD_TYPE 85
#define OGS_TLV_ULI_TYPE 86
#define OGS_TLV_F_TEID_TYPE 87
#define OGS_TLV_TMSI_TYPE 88
#define OGS_TLV_GLOBAL_CN_ID_TYPE 89
#define OGS_TLV_S103PDF_TYPE 90
#define OGS_TLV_S1UDF_TYPE 91
#define OGS_TLV_DELAY_VALUE_TYPE 92
#define OGS_TLV_BEARER_CONTEXT_TYPE 93
#define OGS_TLV_CHARGING_ID_TYPE 94
#define OGS_TLV_CHARGING_CHARACTERISTICS_TYPE 95
#define OGS_TLV_TRACE_INFORMATION_TYPE 96
#define OGS_TLV_BEARER_FLAGS_TYPE 97
#define OGS_TLV_PDN_TYPE_TYPE 99
#define OGS_TLV_PTI_TYPE 100
#define OGS_TLV_MM_CONTEXT_TYPE 107
#define OGS_TLV_PDN_CONNECTION_TYPE 109
#define OGS_TLV_PDU_NUMBERS_TYPE 110
#define OGS_TLV_P_TMSI_TYPE 111
#define OGS_TLV_P_TMSI_SIGNATURE_TYPE 112
#define OGS_TLV_HOP_COUNTER_TYPE 113
#define OGS_TLV_UE_TIME_ZONE_TYPE 114
#define OGS_TLV_TRACE_REFERENCE_TYPE 115
#define OGS_TLV_COMPLETE_REQUEST_MESSAGE_TYPE 116
#define OGS_TLV_GUTI_TYPE 117
#define OGS_TLV_F_CONTAINER_TYPE 118
#define OGS_TLV_F_CAUSE_TYPE 119
#define OGS_TLV_PLMN_ID_TYPE 120
#define OGS_TLV_TARGET_IDENTIFICATION_TYPE 121
#define OGS_TLV_PACKET_FLOW_ID_TYPE 123
#define OGS_TLV_RAB_CONTEXT_TYPE 124
#define OGS_TLV_SOURCE_RNC_PDCP_CONTEXT_INFO_TYPE 125
#define OGS_TLV_PORT_NUMBER_TYPE 126
#define OGS_TLV_APN_RESTRICTION_TYPE 127
#define OGS_TLV_SELECTION_MODE_TYPE 128
#define OGS_TLV_SOURCE_IDENTIFICATION_TYPE 129
#define OGS_TLV_CHANGE_REPORTING_ACTION_TYPE 131
#define OGS_TLV_FQ_CSID_TYPE 132
#define OGS_TLV_CHANNEL_NEEDED_TYPE 133
#define OGS_TLV_EMLPP_PRIORITY_TYPE 134
#define OGS_TLV_NODE_TYPE_TYPE 135
#define OGS_TLV_FQDN_TYPE 136
#define OGS_TLV_TI_TYPE 137
#define OGS_TLV_MBMS_SESSION_DURATION_TYPE 138
#define OGS_TLV_MBMS_SERVICE_AREA_TYPE 139
#define OGS_TLV_MBMS_SESSION_IDENTIFIER_TYPE 140
#define OGS_TLV_MBMS_FLOW_IDENTIFIER_TYPE 141
#define OGS_TLV_MBMS_IP_MULTICAST_DISTRIBUTION_TYPE 142
#define OGS_TLV_MBMS_DISTRIBUTION_ACKNOWLEDGE_TYPE 143
#define OGS_TLV_RFSP_INDEX_TYPE 144
#define OGS_TLV_UCI_TYPE 145
#define OGS_TLV_CSG_INFORMATION_REPORTING_ACTION_TYPE 146
#define OGS_TLV_CSG_ID_TYPE 147
#define OGS_TLV_CMI_TYPE 148
#define OGS_TLV_SERVICE_INDICATOR_TYPE 149
#define OGS_TLV_DETACH_TYPE_TYPE 150
#define OGS_TLV_LDN_TYPE 151
#define OGS_TLV_NODE_FEATURES_TYPE 152
#define OGS_TLV_MBMS_TIME_TO_DATA_TRANSFER_TYPE 153
#define OGS_TLV_THROTTLING_TYPE 154
#define OGS_TLV_ARP_TYPE 155
#define OGS_TLV_EPC_TIMER_TYPE 156
#define OGS_TLV_SIGNALLING_PRIORITY_INDICATION_TYPE 157
#define OGS_TLV_TMGI_TYPE 158
#define OGS_TLV_ADDITIONAL_MM_CONTEXT_FOR_SRVCC_TYPE 159
#define OGS_TLV_ADDITIONAL_FLAGS_FOR_SRVCC_TYPE 160
#define OGS_TLV_MDT_CONFIGURATION_TYPE 162
#define OGS_TLV_APCO_TYPE 163
#define OGS_TLV_ABSOLUTE_TIME_OF_MBMS_DATA_TRANSFER_TYPE 164
#define OGS_TLV_ENB_INFORMATION_REPORTING_TYPE 165
#define OGS_TLV_IP4CP_TYPE 166
#define OGS_TLV_CHANGE_TO_REPORT_FLAGS_TYPE 167
#define OGS_TLV_ACTION_INDICATION_TYPE 168
#define OGS_TLV_TWAN_IDENTIFIER_TYPE 169
#define OGS_TLV_ULI_TIMESTAMP_TYPE 170
#define OGS_TLV_MBMS_FLAGS_TYPE 171
#define OGS_TLV_RAN_NAS_CAUSE_TYPE 172
#define OGS_TLV_CN_OPERATOR_SELECTION_ENTITY_TYPE 173
#define OGS_TLV_TWMI_TYPE 174
#define OGS_TLV_NODE_NUMBER_TYPE 175
#define OGS_TLV_NODE_IDENTIFIER_TYPE 176
#define OGS_TLV_PRESENCE_REPORTING_AREA_ACTION_TYPE 177
#define OGS_TLV_PRESENCE_REPORTING_AREA_INFORMATION_TYPE 178
#define OGS_TLV_TWAN_IDENTIFIER_TIMESTAMP_TYPE 179
#define OGS_TLV_OVERLOAD_CONTROL_INFORMATION_TYPE 180
#define OGS_TLV_LOAD_CONTROL_INFORMATION_TYPE 181
#define OGS_TLV_METRIC_TYPE 182
#define OGS_TLV_SEQUENCE_NUMBER_TYPE 183
#define OGS_TLV_APN_AND_RELATIVE_CAPACITY_TYPE 184
#define OGS_TLV_WLAN_OFFLOADABILITY_INDICATION_TYPE 185
#define OGS_TLV_PAGING_AND_SERVICE_INFORMATION_TYPE 186
#define OGS_TLV_INTEGER_NUMBER_TYPE 187
#define OGS_TLV_MILLISECOND_TIME_STAMP_TYPE 188
#define OGS_TLV_MONITORING_EVENT_INFORMATION_TYPE 189
#define OGS_TLV_ECGI_LIST_TYPE 190
#define OGS_TLV_REMOTE_UE_CONTEXT_TYPE 191
#define OGS_TLV_REMOTE_USER_ID_TYPE 192
#define OGS_TLV_REMOTE_UE_IP_INFORMATION_TYPE 193
#define OGS_TLV_CIOT_OPTIMIZATIONS_SUPPORT_INDICATION_TYPE 194
#define OGS_TLV_SCEF_PDN_CONNECTION_TYPE 195
#define OGS_TLV_HEADER_COMPRESSION_CONFIGURATION_TYPE 196
#define OGS_TLV_EPCO_TYPE 197
#define OGS_TLV_SERVING_PLMN_RATE_CONTROL_TYPE 198
#define OGS_TLV_COUNTER_TYPE 199
#define OGS_GTP_IMSI_TYPE 1
#define OGS_GTP_CAUSE_TYPE 2
#define OGS_GTP_RECOVERY_TYPE 3
#define OGS_GTP_STN_SR_TYPE 51
#define OGS_GTP_APN_TYPE 71
#define OGS_GTP_AMBR_TYPE 72
#define OGS_GTP_EBI_TYPE 73
#define OGS_GTP_IP_ADDRESS_TYPE 74
#define OGS_GTP_MEI_TYPE 75
#define OGS_GTP_MSISDN_TYPE 76
#define OGS_GTP_INDICATION_TYPE 77
#define OGS_GTP_PCO_TYPE 78
#define OGS_GTP_PAA_TYPE 79
#define OGS_GTP_BEARER_QOS_TYPE 80
#define OGS_GTP_FLOW_QOS_TYPE 81
#define OGS_GTP_RAT_TYPE_TYPE 82
#define OGS_GTP_SERVING_NETWORK_TYPE 83
#define OGS_GTP_BEARER_TFT_TYPE 84
#define OGS_GTP_TAD_TYPE 85
#define OGS_GTP_ULI_TYPE 86
#define OGS_GTP_F_TEID_TYPE 87
#define OGS_GTP_TMSI_TYPE 88
#define OGS_GTP_GLOBAL_CN_ID_TYPE 89
#define OGS_GTP_S103PDF_TYPE 90
#define OGS_GTP_S1UDF_TYPE 91
#define OGS_GTP_DELAY_VALUE_TYPE 92
#define OGS_GTP_BEARER_CONTEXT_TYPE 93
#define OGS_GTP_CHARGING_ID_TYPE 94
#define OGS_GTP_CHARGING_CHARACTERISTICS_TYPE 95
#define OGS_GTP_TRACE_INFORMATION_TYPE 96
#define OGS_GTP_BEARER_FLAGS_TYPE 97
#define OGS_GTP_PDN_TYPE_TYPE 99
#define OGS_GTP_PTI_TYPE 100
#define OGS_GTP_MM_CONTEXT_TYPE 107
#define OGS_GTP_PDN_CONNECTION_TYPE 109
#define OGS_GTP_PDU_NUMBERS_TYPE 110
#define OGS_GTP_P_TMSI_TYPE 111
#define OGS_GTP_P_TMSI_SIGNATURE_TYPE 112
#define OGS_GTP_HOP_COUNTER_TYPE 113
#define OGS_GTP_UE_TIME_ZONE_TYPE 114
#define OGS_GTP_TRACE_REFERENCE_TYPE 115
#define OGS_GTP_COMPLETE_REQUEST_MESSAGE_TYPE 116
#define OGS_GTP_GUTI_TYPE 117
#define OGS_GTP_F_CONTAINER_TYPE 118
#define OGS_GTP_F_CAUSE_TYPE 119
#define OGS_GTP_PLMN_ID_TYPE 120
#define OGS_GTP_TARGET_IDENTIFICATION_TYPE 121
#define OGS_GTP_PACKET_FLOW_ID_TYPE 123
#define OGS_GTP_RAB_CONTEXT_TYPE 124
#define OGS_GTP_SOURCE_RNC_PDCP_CONTEXT_INFO_TYPE 125
#define OGS_GTP_PORT_NUMBER_TYPE 126
#define OGS_GTP_APN_RESTRICTION_TYPE 127
#define OGS_GTP_SELECTION_MODE_TYPE 128
#define OGS_GTP_SOURCE_IDENTIFICATION_TYPE 129
#define OGS_GTP_CHANGE_REPORTING_ACTION_TYPE 131
#define OGS_GTP_FQ_CSID_TYPE 132
#define OGS_GTP_CHANNEL_NEEDED_TYPE 133
#define OGS_GTP_EMLPP_PRIORITY_TYPE 134
#define OGS_GTP_NODE_TYPE_TYPE 135
#define OGS_GTP_FQDN_TYPE 136
#define OGS_GTP_TI_TYPE 137
#define OGS_GTP_MBMS_SESSION_DURATION_TYPE 138
#define OGS_GTP_MBMS_SERVICE_AREA_TYPE 139
#define OGS_GTP_MBMS_SESSION_IDENTIFIER_TYPE 140
#define OGS_GTP_MBMS_FLOW_IDENTIFIER_TYPE 141
#define OGS_GTP_MBMS_IP_MULTICAST_DISTRIBUTION_TYPE 142
#define OGS_GTP_MBMS_DISTRIBUTION_ACKNOWLEDGE_TYPE 143
#define OGS_GTP_RFSP_INDEX_TYPE 144
#define OGS_GTP_UCI_TYPE 145
#define OGS_GTP_CSG_INFORMATION_REPORTING_ACTION_TYPE 146
#define OGS_GTP_CSG_ID_TYPE 147
#define OGS_GTP_CMI_TYPE 148
#define OGS_GTP_SERVICE_INDICATOR_TYPE 149
#define OGS_GTP_DETACH_TYPE_TYPE 150
#define OGS_GTP_LDN_TYPE 151
#define OGS_GTP_NODE_FEATURES_TYPE 152
#define OGS_GTP_MBMS_TIME_TO_DATA_TRANSFER_TYPE 153
#define OGS_GTP_THROTTLING_TYPE 154
#define OGS_GTP_ARP_TYPE 155
#define OGS_GTP_EPC_TIMER_TYPE 156
#define OGS_GTP_SIGNALLING_PRIORITY_INDICATION_TYPE 157
#define OGS_GTP_TMGI_TYPE 158
#define OGS_GTP_ADDITIONAL_MM_CONTEXT_FOR_SRVCC_TYPE 159
#define OGS_GTP_ADDITIONAL_FLAGS_FOR_SRVCC_TYPE 160
#define OGS_GTP_MDT_CONFIGURATION_TYPE 162
#define OGS_GTP_APCO_TYPE 163
#define OGS_GTP_ABSOLUTE_TIME_OF_MBMS_DATA_TRANSFER_TYPE 164
#define OGS_GTP_ENB_INFORMATION_REPORTING_TYPE 165
#define OGS_GTP_IP4CP_TYPE 166
#define OGS_GTP_CHANGE_TO_REPORT_FLAGS_TYPE 167
#define OGS_GTP_ACTION_INDICATION_TYPE 168
#define OGS_GTP_TWAN_IDENTIFIER_TYPE 169
#define OGS_GTP_ULI_TIMESTAMP_TYPE 170
#define OGS_GTP_MBMS_FLAGS_TYPE 171
#define OGS_GTP_RAN_NAS_CAUSE_TYPE 172
#define OGS_GTP_CN_OPERATOR_SELECTION_ENTITY_TYPE 173
#define OGS_GTP_TWMI_TYPE 174
#define OGS_GTP_NODE_NUMBER_TYPE 175
#define OGS_GTP_NODE_IDENTIFIER_TYPE 176
#define OGS_GTP_PRESENCE_REPORTING_AREA_ACTION_TYPE 177
#define OGS_GTP_PRESENCE_REPORTING_AREA_INFORMATION_TYPE 178
#define OGS_GTP_TWAN_IDENTIFIER_TIMESTAMP_TYPE 179
#define OGS_GTP_OVERLOAD_CONTROL_INFORMATION_TYPE 180
#define OGS_GTP_LOAD_CONTROL_INFORMATION_TYPE 181
#define OGS_GTP_METRIC_TYPE 182
#define OGS_GTP_SEQUENCE_NUMBER_TYPE 183
#define OGS_GTP_APN_AND_RELATIVE_CAPACITY_TYPE 184
#define OGS_GTP_WLAN_OFFLOADABILITY_INDICATION_TYPE 185
#define OGS_GTP_PAGING_AND_SERVICE_INFORMATION_TYPE 186
#define OGS_GTP_INTEGER_NUMBER_TYPE 187
#define OGS_GTP_MILLISECOND_TIME_STAMP_TYPE 188
#define OGS_GTP_MONITORING_EVENT_INFORMATION_TYPE 189
#define OGS_GTP_ECGI_LIST_TYPE 190
#define OGS_GTP_REMOTE_UE_CONTEXT_TYPE 191
#define OGS_GTP_REMOTE_USER_ID_TYPE 192
#define OGS_GTP_REMOTE_UE_IP_INFORMATION_TYPE 193
#define OGS_GTP_CIOT_OPTIMIZATIONS_SUPPORT_INDICATION_TYPE 194
#define OGS_GTP_SCEF_PDN_CONNECTION_TYPE 195
#define OGS_GTP_HEADER_COMPRESSION_CONFIGURATION_TYPE 196
#define OGS_GTP_EPCO_TYPE 197
#define OGS_GTP_SERVING_PLMN_RATE_CONTROL_TYPE 198
#define OGS_GTP_COUNTER_TYPE 199
/* Infomration Element TLV Descriptor */
extern ogs_tlv_desc_t ogs_gtp_tlv_desc_imsi_0;

View File

@ -435,7 +435,7 @@ f.write("\n")
tmp = [(k, v["type"]) for k, v in type_list.items()]
sorted_type_list = sorted(tmp, key=lambda tup: int(tup[1]))
for (k, v) in sorted_type_list:
f.write("#define OGS_TLV_" + v_upper(k) + "_TYPE " + v + "\n")
f.write("#define OGS_GTP_" + v_upper(k) + "_TYPE " + v + "\n")
f.write("\n")
f.write("/* Infomration Element TLV Descriptor */\n")
@ -557,7 +557,7 @@ for (k, v) in sorted_type_list:
else:
f.write(" OGS_TLV_VAR_STR,\n")
f.write(" \"%s\",\n" % k)
f.write(" OGS_TLV_%s_TYPE,\n" % v_upper(k))
f.write(" OGS_GTP_%s_TYPE,\n" % v_upper(k))
if "size" in type_list[k]:
f.write(" %d,\n" % type_list[k]["size"])
else:
@ -573,7 +573,7 @@ for (k, v) in sorted_group_list:
f.write("{\n")
f.write(" OGS_TLV_COMPOUND,\n")
f.write(" \"%s\",\n" % k)
f.write(" OGS_TLV_%s_TYPE,\n" % v_upper(k))
f.write(" OGS_GTP_%s_TYPE,\n" % v_upper(k))
f.write(" 0,\n")
f.write(" %d,\n" % instance)
f.write(" sizeof(ogs_gtp_tlv_%s_t),\n" % v_lower(k))

2176
lib/pfcp/message.c Normal file

File diff suppressed because it is too large Load Diff

970
lib/pfcp/message.h Normal file
View File

@ -0,0 +1,970 @@
/*
* Copyright (C) 2019 by Sukchan Lee <acetcom@gmail.com>
*
* This file is part of Open5GS.
*
* This program is free software: you can redistribute it and/or modify
* it under the terms of the GNU Affero General Public License as published by
* the Free Software Foundation, either version 3 of the License, or
* (at your option) any later version.
*
* This program is distributed in the hope that it will be useful,
* but WITHOUT ANY WARRANTY; without even the implied warranty of
* MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
* GNU General Public License for more details.
*
* You should have received a copy of the GNU General Public License
* along with this program. If not, see <https://www.gnu.org/licenses/>.
*/
/*******************************************************************************
* This file had been created by pfcp-tlv.py script v0.1.0
* Please do not modify this file but regenerate it via script.
* Created on: 2019-12-01 21:40:00.632173 by acetcom
* from 29244-f40.docx
******************************************************************************/
#if !defined(OGS_PFCP_INSIDE) && !defined(OGS_PFCP_COMPILATION)
#error "This header cannot be included directly."
#endif
#ifndef OGS_PFCP_MESSAGE_H
#define OGS_PFCP_MESSAGE_H
#ifdef __cplusplus
extern "C" {
#endif
/* 5.1 General format */
#define OGS_PFCP_HEADER_LEN 16
#define OGS_PFCP_SEID_LEN 8
typedef struct ogs_pfcp_header_s {
union {
struct {
ED4(uint8_t version:3;,
uint8_t spare1:3;,
uint8_t mp:1;,
uint8_t seid_p:1;)
};
uint8_t flags;
};
uint8_t type;
uint16_t length;
union {
struct {
uint64_t seid;
/* sqn : 31bit ~ 8bit, spare : 7bit ~ 0bit */
#define OGS_PFCP_XID_TO_SQN(__xid) htonl(((__xid) << 8))
#define OGS_PFCP_SQN_TO_XID(__sqn) (ntohl(__sqn) >> 8)
uint32_t sqn;
};
/* sqn : 31bit ~ 8bit, spare : 7bit ~ 0bit */
uint32_t sqn_only;
};
} __attribute__ ((packed)) ogs_pfcp_header_t;
/* PFCP message type */
#define OGS_PFCP_HEARTBEAT_REQUEST_TYPE 1
#define OGS_PFCP_HEARTBEAT_RESPONSE_TYPE 2
#define OGS_PFCP_PFD_MANAGEMENT_REQUEST_TYPE 3
#define OGS_PFCP_PFD_MANAGEMENT_RESPONSE_TYPE 4
#define OGS_PFCP_ASSOCIATION_SETUP_REQUEST_TYPE 5
#define OGS_PFCP_ASSOCIATION_SETUP_RESPONSE_TYPE 6
#define OGS_PFCP_ASSOCIATION_UPDATE_REQUEST_TYPE 7
#define OGS_PFCP_ASSOCIATION_UPDATE_RESPONSE_TYPE 8
#define OGS_PFCP_ASSOCIATION_RELEASE_REQUEST_TYPE 9
#define OGS_PFCP_ASSOCIATION_RELEASE_RESPONSE_TYPE 10
#define OGS_PFCP_VERSION_NOT_SUPPORTED_RESPONSE_TYPE 11
#define OGS_PFCP_NODE_REPORT_REQUEST_TYPE 12
#define OGS_PFCP_NODE_REPORT_RESPONSE_TYPE 13
#define OGS_PFCP_SESSION_SET_DELETION_REQUEST_TYPE 14
#define OGS_PFCP_SESSION_SET_DELETION_RESPONSE_TYPE 15
#define OGS_PFCP_SESSION_ESTABLISHMENT_REQUEST_TYPE 50
#define OGS_PFCP_SESSION_ESTABLISHMENT_RESPONSE_TYPE 51
#define OGS_PFCP_SESSION_MODIFICATION_REQUEST_TYPE 52
#define OGS_PFCP_SESSION_MODIFICATION_RESPONSE_TYPE 53
#define OGS_PFCP_SESSION_DELETION_REQUEST_TYPE 54
#define OGS_PFCP_SESSION_DELETION_RESPONSE_TYPE 55
#define OGS_PFCP_SESSION_REPORT_REQUEST_TYPE 56
#define OGS_PFCP_SESSION_REPORT_RESPONSE_TYPE 57
#define OGS_PFCP_CREATE_PDR_TYPE 1
#define OGS_PFCP_PDI_TYPE 2
#define OGS_PFCP_CREATE_FAR_TYPE 3
#define OGS_PFCP_FORWARDING_PARAMETERS_TYPE 4
#define OGS_PFCP_DUPLICATING_PARAMETERS_TYPE 5
#define OGS_PFCP_CREATE_URR_TYPE 6
#define OGS_PFCP_CREATE_QER_TYPE 7
#define OGS_PFCP_CREATED_PDR_TYPE 8
#define OGS_PFCP_UPDATE_PDR_TYPE 9
#define OGS_PFCP_UPDATE_FAR_TYPE 10
#define OGS_PFCP_UPDATE_FORWARDING_PARAMETERS_TYPE 11
#define OGS_PFCP_UPDATE_BAR_PFCP_SESSION_REPORT_RESPONSE_TYPE 12
#define OGS_PFCP_UPDATE_URR_TYPE 13
#define OGS_PFCP_UPDATE_QER_TYPE 14
#define OGS_PFCP_REMOVE_PDR_TYPE 15
#define OGS_PFCP_REMOVE_FAR_TYPE 16
#define OGS_PFCP_REMOVE_URR_TYPE 17
#define OGS_PFCP_REMOVE_QER_TYPE 18
#define OGS_PFCP_CAUSE_TYPE 19
#define OGS_PFCP_SOURCE_INTERFACE_TYPE 20
#define OGS_PFCP_F_TEID_TYPE 21
#define OGS_PFCP_NETWORK_INSTANCE_TYPE 22
#define OGS_PFCP_SDF_FILTER_TYPE 23
#define OGS_PFCP_APPLICATION_ID_TYPE 24
#define OGS_PFCP_GATE_STATUS_TYPE 25
#define OGS_PFCP_MBR_TYPE 26
#define OGS_PFCP_GBR_TYPE 27
#define OGS_PFCP_QER_CORRELATION_ID_TYPE 28
#define OGS_PFCP_PRECEDENCE_TYPE 29
#define OGS_PFCP_TRANSPORT_LEVEL_MARKING_TYPE 30
#define OGS_PFCP_VOLUME_THRESHOLD_TYPE 31
#define OGS_PFCP_TIME_THRESHOLD_TYPE 32
#define OGS_PFCP_MONITORING_TIME_TYPE 33
#define OGS_PFCP_SUBSEQUENT_VOLUME_THRESHOLD_TYPE 34
#define OGS_PFCP_SUBSEQUENT_TIME_THRESHOLD_TYPE 35
#define OGS_PFCP_INACTIVITY_DETECTION_TIME_TYPE 36
#define OGS_PFCP_REPORTING_TRIGGERS_TYPE 37
#define OGS_PFCP_REDIRECT_INFORMATION_TYPE 38
#define OGS_PFCP_REPORT_TYPE_TYPE 39
#define OGS_PFCP_OFFENDING_IE_TYPE 40
#define OGS_PFCP_FORWARDING_POLICY_TYPE 41
#define OGS_PFCP_DESTINATION_INTERFACE_TYPE 42
#define OGS_PFCP_UP_FUNCTION_FEATURES_TYPE 43
#define OGS_PFCP_APPLY_ACTION_TYPE 44
#define OGS_PFCP_DOWNLINK_DATA_SERVICE_INFORMATION_TYPE 45
#define OGS_PFCP_DOWNLINK_DATA_NOTIFICATION_DELAY_TYPE 46
#define OGS_PFCP_DL_BUFFERING_DURATION_TYPE 47
#define OGS_PFCP_DL_BUFFERING_SUGGESTED_PACKET_COUNT_TYPE 48
#define OGS_PFCP_PFCPSMREQ_FLAGS_TYPE 49
#define OGS_PFCP_PFCPSRRSP_FLAGS_TYPE 50
#define OGS_PFCP_LOAD_CONTROL_INFORMATIONP_TYPE 51
#define OGS_PFCP_SEQUENCE_NUMBER_TYPE 52
#define OGS_PFCP_METRICP_TYPE 53
#define OGS_PFCP_OVERLOAD_CONTROL_INFORMATIONP_TYPE 54
#define OGS_PFCP_TIMER_TYPE 55
#define OGS_PFCP_PACKET_DETECTION_RULE_ID_TYPE 56
#define OGS_PFCP_F_SEID_TYPE 57
#define OGS_PFCP_APPLICATION_ID_S_PFDS_TYPE 58
#define OGS_PFCP_PFD_CONTEXT_TYPE 59
#define OGS_PFCP_NODE_ID_TYPE 60
#define OGS_PFCP_PFD_CONTENTS_TYPE 61
#define OGS_PFCP_MEASUREMENT_METHOD_TYPE 62
#define OGS_PFCP_USAGE_REPORT_TRIGGER_TYPE 63
#define OGS_PFCP_MEASUREMENT_PERIOD_TYPE 64
#define OGS_PFCP_FQ_CSIDP_TYPE 65
#define OGS_PFCP_VOLUME_MEASUREMENT_TYPE 66
#define OGS_PFCP_DURATION_MEASUREMENT_TYPE 67
#define OGS_PFCP_APPLICATION_DETECTION_INFORMATION_TYPE 68
#define OGS_PFCP_TIME_OF_FIRST_PACKET_TYPE 69
#define OGS_PFCP_TIME_OF_LAST_PACKET_TYPE 70
#define OGS_PFCP_QUOTA_HOLDING_TIME_TYPE 71
#define OGS_PFCP_DROPPED_DL_TRAFFIC_THRESHOLD_TYPE 72
#define OGS_PFCP_VOLUME_QUOTA_TYPE 73
#define OGS_PFCP_TIME_QUOTA_TYPE 74
#define OGS_PFCP_START_TIME_TYPE 75
#define OGS_PFCP_END_TIME_TYPE 76
#define OGS_PFCP_QUERY_URR_TYPE 77
#define OGS_PFCP_USAGE_REPORT_IN_SESSION_MODIFICATION_RESPONSE_TYPE 78
#define OGS_PFCP_USAGE_REPORT_SESSION_DELETION_RESPONSE_TYPE 79
#define OGS_PFCP_USAGE_REPORT_SESSION_REPORT_REQUEST_TYPE 80
#define OGS_PFCP_URR_ID_TYPE 81
#define OGS_PFCP_LINKED_URR_ID_TYPE 82
#define OGS_PFCP_DOWNLINK_DATA_REPORT_TYPE 83
#define OGS_PFCP_OUTER_HEADER_CREATION_TYPE 84
#define OGS_PFCP_CREATE_BAR_TYPE 85
#define OGS_PFCP_UPDATE_BAR_SESSION_MODIFICATION_REQUEST_TYPE 86
#define OGS_PFCP_REMOVE_BAR_TYPE 87
#define OGS_PFCP_BAR_ID_TYPE 88
#define OGS_PFCP_CP_FUNCTION_FEATURES_TYPE 89
#define OGS_PFCP_USAGE_INFORMATION_TYPE 90
#define OGS_PFCP_APPLICATION_INSTANCE_ID_TYPE 91
#define OGS_PFCP_FLOW_INFORMATION_TYPE 92
#define OGS_PFCP_UE_IP_ADDRESS_TYPE 93
#define OGS_PFCP_PACKET_RATE_TYPE 94
#define OGS_PFCP_OUTER_HEADER_REMOVAL_TYPE 95
#define OGS_PFCP_RECOVERY_TIME_STAMP_TYPE 96
#define OGS_PFCP_DL_FLOW_LEVEL_MARKING_TYPE 97
#define OGS_PFCP_HEADER_ENRICHMENT_TYPE 98
#define OGS_PFCP_ERROR_INDICATION_REPORT_TYPE 99
#define OGS_PFCP_MEASUREMENT_INFORMATION_TYPE 100
#define OGS_PFCP_NODE_REPORT_TYPE_TYPE 101
#define OGS_PFCP_USER_PLANE_PATH_FAILURE_REPORT_TYPE 102
#define OGS_PFCP_REMOTE_GTP_U_PEER_TYPE 103
#define OGS_PFCP_UR_SEQN_TYPE 104
#define OGS_PFCP_UPDATE_DUPLICATING_PARAMETERS_TYPE 105
#define OGS_PFCP_ACTIVATE_PREDEFINED_RULES_TYPE 106
#define OGS_PFCP_DEACTIVATE_PREDEFINED_RULES_TYPE 107
#define OGS_PFCP_FAR_ID_TYPE 108
#define OGS_PFCP_QER_ID_TYPE 109
#define OGS_PFCP_OCI_FLAGS_TYPE 110
#define OGS_PFCP_PFCP_ASSOCIATION_RELEASE_REQUEST_TYPE 111
#define OGS_PFCP_GRACEFUL_RELEASE_PERIOD_TYPE 112
#define OGS_PFCP_PDN_TYPEP_TYPE 113
#define OGS_PFCP_FAILED_RULE_ID_TYPE 114
#define OGS_PFCP_TIME_QUOTA_MECHANISM_TYPE 115
#define OGS_PFCP_USER_PLANE_IP_RESOURCE_INFORMATION_TYPE 116
#define OGS_PFCP_USER_PLANE_INACTIVITY_TIMER_TYPE 117
#define OGS_PFCP_AGGREGATED_URRS_TYPE 118
#define OGS_PFCP_MULTIPLIER_TYPE 119
#define OGS_PFCP_AGGREGATED_URR_ID_TYPE 120
#define OGS_PFCP_SUBSEQUENT_VOLUME_QUOTA_TYPE 121
#define OGS_PFCP_SUBSEQUENT_TIME_QUOTA_TYPE 122
#define OGS_PFCP_RQI_TYPE 123
#define OGS_PFCP_QFI_TYPE 124
/* Infomration Element TLV Descriptor */
extern ogs_tlv_desc_t ogs_pfcp_tlv_desc_cause_0;
extern ogs_tlv_desc_t ogs_pfcp_tlv_desc_source_interface_0;
extern ogs_tlv_desc_t ogs_pfcp_tlv_desc_f_teid_0;
extern ogs_tlv_desc_t ogs_pfcp_tlv_desc_network_instance_0;
extern ogs_tlv_desc_t ogs_pfcp_tlv_desc_sdf_filter_0;
extern ogs_tlv_desc_t ogs_pfcp_tlv_desc_application_id_0;
extern ogs_tlv_desc_t ogs_pfcp_tlv_desc_gate_status_0;
extern ogs_tlv_desc_t ogs_pfcp_tlv_desc_mbr_0;
extern ogs_tlv_desc_t ogs_pfcp_tlv_desc_gbr_0;
extern ogs_tlv_desc_t ogs_pfcp_tlv_desc_qer_correlation_id_0;
extern ogs_tlv_desc_t ogs_pfcp_tlv_desc_precedence_0;
extern ogs_tlv_desc_t ogs_pfcp_tlv_desc_transport_level_marking_0;
extern ogs_tlv_desc_t ogs_pfcp_tlv_desc_volume_threshold_0;
extern ogs_tlv_desc_t ogs_pfcp_tlv_desc_time_threshold_0;
extern ogs_tlv_desc_t ogs_pfcp_tlv_desc_monitoring_time_0;
extern ogs_tlv_desc_t ogs_pfcp_tlv_desc_subsequent_volume_threshold_0;
extern ogs_tlv_desc_t ogs_pfcp_tlv_desc_subsequent_time_threshold_0;
extern ogs_tlv_desc_t ogs_pfcp_tlv_desc_inactivity_detection_time_0;
extern ogs_tlv_desc_t ogs_pfcp_tlv_desc_reporting_triggers_0;
extern ogs_tlv_desc_t ogs_pfcp_tlv_desc_redirect_information_0;
extern ogs_tlv_desc_t ogs_pfcp_tlv_desc_report_type_0;
extern ogs_tlv_desc_t ogs_pfcp_tlv_desc_offending_ie_0;
extern ogs_tlv_desc_t ogs_pfcp_tlv_desc_forwarding_policy_0;
extern ogs_tlv_desc_t ogs_pfcp_tlv_desc_destination_interface_0;
extern ogs_tlv_desc_t ogs_pfcp_tlv_desc_up_function_features_0;
extern ogs_tlv_desc_t ogs_pfcp_tlv_desc_apply_action_0;
extern ogs_tlv_desc_t ogs_pfcp_tlv_desc_downlink_data_service_information_0;
extern ogs_tlv_desc_t ogs_pfcp_tlv_desc_downlink_data_notification_delay_0;
extern ogs_tlv_desc_t ogs_pfcp_tlv_desc_dl_buffering_duration_0;
extern ogs_tlv_desc_t ogs_pfcp_tlv_desc_dl_buffering_suggested_packet_count_0;
extern ogs_tlv_desc_t ogs_pfcp_tlv_desc_pfcpsmreq_flags_0;
extern ogs_tlv_desc_t ogs_pfcp_tlv_desc_pfcpsrrsp_flags_0;
extern ogs_tlv_desc_t ogs_pfcp_tlv_desc_sequence_number_0;
extern ogs_tlv_desc_t ogs_pfcp_tlv_desc_metricp_0;
extern ogs_tlv_desc_t ogs_pfcp_tlv_desc_timer_0;
extern ogs_tlv_desc_t ogs_pfcp_tlv_desc_packet_detection_rule_id_0;
extern ogs_tlv_desc_t ogs_pfcp_tlv_desc_f_seid_0;
extern ogs_tlv_desc_t ogs_pfcp_tlv_desc_node_id_0;
extern ogs_tlv_desc_t ogs_pfcp_tlv_desc_pfd_contents_0;
extern ogs_tlv_desc_t ogs_pfcp_tlv_desc_measurement_method_0;
extern ogs_tlv_desc_t ogs_pfcp_tlv_desc_usage_report_trigger_0;
extern ogs_tlv_desc_t ogs_pfcp_tlv_desc_measurement_period_0;
extern ogs_tlv_desc_t ogs_pfcp_tlv_desc_fq_csidp_0;
extern ogs_tlv_desc_t ogs_pfcp_tlv_desc_volume_measurement_0;
extern ogs_tlv_desc_t ogs_pfcp_tlv_desc_duration_measurement_0;
extern ogs_tlv_desc_t ogs_pfcp_tlv_desc_time_of_first_packet_0;
extern ogs_tlv_desc_t ogs_pfcp_tlv_desc_time_of_last_packet_0;
extern ogs_tlv_desc_t ogs_pfcp_tlv_desc_quota_holding_time_0;
extern ogs_tlv_desc_t ogs_pfcp_tlv_desc_dropped_dl_traffic_threshold_0;
extern ogs_tlv_desc_t ogs_pfcp_tlv_desc_volume_quota_0;
extern ogs_tlv_desc_t ogs_pfcp_tlv_desc_time_quota_0;
extern ogs_tlv_desc_t ogs_pfcp_tlv_desc_start_time_0;
extern ogs_tlv_desc_t ogs_pfcp_tlv_desc_end_time_0;
extern ogs_tlv_desc_t ogs_pfcp_tlv_desc_urr_id_0;
extern ogs_tlv_desc_t ogs_pfcp_tlv_desc_linked_urr_id_0;
extern ogs_tlv_desc_t ogs_pfcp_tlv_desc_outer_header_creation_0;
extern ogs_tlv_desc_t ogs_pfcp_tlv_desc_bar_id_0;
extern ogs_tlv_desc_t ogs_pfcp_tlv_desc_cp_function_features_0;
extern ogs_tlv_desc_t ogs_pfcp_tlv_desc_usage_information_0;
extern ogs_tlv_desc_t ogs_pfcp_tlv_desc_application_instance_id_0;
extern ogs_tlv_desc_t ogs_pfcp_tlv_desc_flow_information_0;
extern ogs_tlv_desc_t ogs_pfcp_tlv_desc_ue_ip_address_0;
extern ogs_tlv_desc_t ogs_pfcp_tlv_desc_packet_rate_0;
extern ogs_tlv_desc_t ogs_pfcp_tlv_desc_outer_header_removal_0;
extern ogs_tlv_desc_t ogs_pfcp_tlv_desc_recovery_time_stamp_0;
extern ogs_tlv_desc_t ogs_pfcp_tlv_desc_dl_flow_level_marking_0;
extern ogs_tlv_desc_t ogs_pfcp_tlv_desc_header_enrichment_0;
extern ogs_tlv_desc_t ogs_pfcp_tlv_desc_measurement_information_0;
extern ogs_tlv_desc_t ogs_pfcp_tlv_desc_node_report_type_0;
extern ogs_tlv_desc_t ogs_pfcp_tlv_desc_user_plane_path_failure_report_0;
extern ogs_tlv_desc_t ogs_pfcp_tlv_desc_remote_gtp_u_peer_0;
extern ogs_tlv_desc_t ogs_pfcp_tlv_desc_ur_seqn_0;
extern ogs_tlv_desc_t ogs_pfcp_tlv_desc_activate_predefined_rules_0;
extern ogs_tlv_desc_t ogs_pfcp_tlv_desc_deactivate_predefined_rules_0;
extern ogs_tlv_desc_t ogs_pfcp_tlv_desc_far_id_0;
extern ogs_tlv_desc_t ogs_pfcp_tlv_desc_qer_id_0;
extern ogs_tlv_desc_t ogs_pfcp_tlv_desc_oci_flags_0;
extern ogs_tlv_desc_t ogs_pfcp_tlv_desc_pfcp_association_release_request_0;
extern ogs_tlv_desc_t ogs_pfcp_tlv_desc_graceful_release_period_0;
extern ogs_tlv_desc_t ogs_pfcp_tlv_desc_pdn_typep_0;
extern ogs_tlv_desc_t ogs_pfcp_tlv_desc_failed_rule_id_0;
extern ogs_tlv_desc_t ogs_pfcp_tlv_desc_time_quota_mechanism_0;
extern ogs_tlv_desc_t ogs_pfcp_tlv_desc_user_plane_ip_resource_information_0;
extern ogs_tlv_desc_t ogs_pfcp_tlv_desc_user_plane_inactivity_timer_0;
extern ogs_tlv_desc_t ogs_pfcp_tlv_desc_aggregated_urrs_0;
extern ogs_tlv_desc_t ogs_pfcp_tlv_desc_multiplier_0;
extern ogs_tlv_desc_t ogs_pfcp_tlv_desc_aggregated_urr_id_0;
extern ogs_tlv_desc_t ogs_pfcp_tlv_desc_subsequent_volume_quota_0;
extern ogs_tlv_desc_t ogs_pfcp_tlv_desc_subsequent_time_quota_0;
extern ogs_tlv_desc_t ogs_pfcp_tlv_desc_rqi_0;
extern ogs_tlv_desc_t ogs_pfcp_tlv_desc_qfi_0;
/* Group Infomration Element TLV Descriptor */
extern ogs_tlv_desc_t ogs_pfcp_tlv_desc_create_pdr_0;
extern ogs_tlv_desc_t ogs_pfcp_tlv_desc_create_pdr_1;
extern ogs_tlv_desc_t ogs_pfcp_tlv_desc_pdi_0;
extern ogs_tlv_desc_t ogs_pfcp_tlv_desc_create_far_0;
extern ogs_tlv_desc_t ogs_pfcp_tlv_desc_create_far_1;
extern ogs_tlv_desc_t ogs_pfcp_tlv_desc_forwarding_parameters_0;
extern ogs_tlv_desc_t ogs_pfcp_tlv_desc_duplicating_parameters_0;
extern ogs_tlv_desc_t ogs_pfcp_tlv_desc_create_urr_0;
extern ogs_tlv_desc_t ogs_pfcp_tlv_desc_create_qer_0;
extern ogs_tlv_desc_t ogs_pfcp_tlv_desc_created_pdr_0;
extern ogs_tlv_desc_t ogs_pfcp_tlv_desc_update_pdr_0;
extern ogs_tlv_desc_t ogs_pfcp_tlv_desc_update_pdr_1;
extern ogs_tlv_desc_t ogs_pfcp_tlv_desc_update_far_0;
extern ogs_tlv_desc_t ogs_pfcp_tlv_desc_update_forwarding_parameters_0;
extern ogs_tlv_desc_t ogs_pfcp_tlv_desc_update_bar_pfcp_session_report_response_0;
extern ogs_tlv_desc_t ogs_pfcp_tlv_desc_update_urr_0;
extern ogs_tlv_desc_t ogs_pfcp_tlv_desc_update_qer_0;
extern ogs_tlv_desc_t ogs_pfcp_tlv_desc_remove_pdr_0;
extern ogs_tlv_desc_t ogs_pfcp_tlv_desc_remove_far_0;
extern ogs_tlv_desc_t ogs_pfcp_tlv_desc_remove_urr_0;
extern ogs_tlv_desc_t ogs_pfcp_tlv_desc_remove_qer_0;
extern ogs_tlv_desc_t ogs_pfcp_tlv_desc_load_control_informationp_0;
extern ogs_tlv_desc_t ogs_pfcp_tlv_desc_overload_control_informationp_0;
extern ogs_tlv_desc_t ogs_pfcp_tlv_desc_application_id_s_pfds_0;
extern ogs_tlv_desc_t ogs_pfcp_tlv_desc_pfd_context_0;
extern ogs_tlv_desc_t ogs_pfcp_tlv_desc_application_detection_information_0;
extern ogs_tlv_desc_t ogs_pfcp_tlv_desc_query_urr_0;
extern ogs_tlv_desc_t ogs_pfcp_tlv_desc_usage_report_in_session_modification_response_0;
extern ogs_tlv_desc_t ogs_pfcp_tlv_desc_usage_report_session_deletion_response_0;
extern ogs_tlv_desc_t ogs_pfcp_tlv_desc_usage_report_session_report_request_0;
extern ogs_tlv_desc_t ogs_pfcp_tlv_desc_downlink_data_report_0;
extern ogs_tlv_desc_t ogs_pfcp_tlv_desc_create_bar_0;
extern ogs_tlv_desc_t ogs_pfcp_tlv_desc_update_bar_session_modification_request_0;
extern ogs_tlv_desc_t ogs_pfcp_tlv_desc_remove_bar_0;
extern ogs_tlv_desc_t ogs_pfcp_tlv_desc_error_indication_report_0;
extern ogs_tlv_desc_t ogs_pfcp_tlv_desc_update_duplicating_parameters_0;
/* Message Descriptor */
extern ogs_tlv_desc_t ogs_pfcp_tlv_desc_pfcp_heartbeat_request;
extern ogs_tlv_desc_t ogs_pfcp_tlv_desc_pfcp_heartbeat_response;
extern ogs_tlv_desc_t ogs_pfcp_tlv_desc_pfcp_pfd_management_request;
extern ogs_tlv_desc_t ogs_pfcp_tlv_desc_pfcp_pfd_management_response;
extern ogs_tlv_desc_t ogs_pfcp_tlv_desc_pfcp_association_setup_request;
extern ogs_tlv_desc_t ogs_pfcp_tlv_desc_pfcp_association_setup_response;
extern ogs_tlv_desc_t ogs_pfcp_tlv_desc_pfcp_association_update_request;
extern ogs_tlv_desc_t ogs_pfcp_tlv_desc_pfcp_association_update_response;
extern ogs_tlv_desc_t ogs_pfcp_tlv_desc_pfcp_association_release_request;
extern ogs_tlv_desc_t ogs_pfcp_tlv_desc_pfcp_association_release_response;
extern ogs_tlv_desc_t ogs_pfcp_tlv_desc_pfcp_version_not_supported_response;
extern ogs_tlv_desc_t ogs_pfcp_tlv_desc_pfcp_node_report_request;
extern ogs_tlv_desc_t ogs_pfcp_tlv_desc_pfcp_node_report_response;
extern ogs_tlv_desc_t ogs_pfcp_tlv_desc_pfcp_session_set_deletion_request;
extern ogs_tlv_desc_t ogs_pfcp_tlv_desc_pfcp_session_set_deletion_response;
extern ogs_tlv_desc_t ogs_pfcp_tlv_desc_pfcp_session_establishment_request;
extern ogs_tlv_desc_t ogs_pfcp_tlv_desc_pfcp_session_establishment_response;
extern ogs_tlv_desc_t ogs_pfcp_tlv_desc_pfcp_session_modification_request;
extern ogs_tlv_desc_t ogs_pfcp_tlv_desc_pfcp_session_modification_response;
extern ogs_tlv_desc_t ogs_pfcp_tlv_desc_pfcp_session_deletion_request;
extern ogs_tlv_desc_t ogs_pfcp_tlv_desc_pfcp_session_deletion_response;
extern ogs_tlv_desc_t ogs_pfcp_tlv_desc_pfcp_session_report_request;
extern ogs_tlv_desc_t ogs_pfcp_tlv_desc_pfcp_session_report_response;
/* Structure for Infomration Element */
typedef ogs_tlv_octet_t ogs_pfcp_tlv_cause_t;
typedef ogs_tlv_octet_t ogs_pfcp_tlv_source_interface_t;
typedef ogs_tlv_octet_t ogs_pfcp_tlv_f_teid_t;
typedef ogs_tlv_octet_t ogs_pfcp_tlv_network_instance_t;
typedef ogs_tlv_octet_t ogs_pfcp_tlv_sdf_filter_t;
typedef ogs_tlv_octet_t ogs_pfcp_tlv_application_id_t;
typedef ogs_tlv_octet_t ogs_pfcp_tlv_gate_status_t;
typedef ogs_tlv_octet_t ogs_pfcp_tlv_mbr_t;
typedef ogs_tlv_octet_t ogs_pfcp_tlv_gbr_t;
typedef ogs_tlv_octet_t ogs_pfcp_tlv_qer_correlation_id_t;
typedef ogs_tlv_octet_t ogs_pfcp_tlv_precedence_t;
typedef ogs_tlv_octet_t ogs_pfcp_tlv_transport_level_marking_t;
typedef ogs_tlv_octet_t ogs_pfcp_tlv_volume_threshold_t;
typedef ogs_tlv_octet_t ogs_pfcp_tlv_time_threshold_t;
typedef ogs_tlv_octet_t ogs_pfcp_tlv_monitoring_time_t;
typedef ogs_tlv_octet_t ogs_pfcp_tlv_subsequent_volume_threshold_t;
typedef ogs_tlv_octet_t ogs_pfcp_tlv_subsequent_time_threshold_t;
typedef ogs_tlv_octet_t ogs_pfcp_tlv_inactivity_detection_time_t;
typedef ogs_tlv_octet_t ogs_pfcp_tlv_reporting_triggers_t;
typedef ogs_tlv_octet_t ogs_pfcp_tlv_redirect_information_t;
typedef ogs_tlv_octet_t ogs_pfcp_tlv_report_type_t;
typedef ogs_tlv_octet_t ogs_pfcp_tlv_offending_ie_t;
typedef ogs_tlv_octet_t ogs_pfcp_tlv_forwarding_policy_t;
typedef ogs_tlv_octet_t ogs_pfcp_tlv_destination_interface_t;
typedef ogs_tlv_octet_t ogs_pfcp_tlv_up_function_features_t;
typedef ogs_tlv_octet_t ogs_pfcp_tlv_apply_action_t;
typedef ogs_tlv_octet_t ogs_pfcp_tlv_downlink_data_service_information_t;
typedef ogs_tlv_octet_t ogs_pfcp_tlv_downlink_data_notification_delay_t;
typedef ogs_tlv_octet_t ogs_pfcp_tlv_dl_buffering_duration_t;
typedef ogs_tlv_octet_t ogs_pfcp_tlv_dl_buffering_suggested_packet_count_t;
typedef ogs_tlv_octet_t ogs_pfcp_tlv_pfcpsmreq_flags_t;
typedef ogs_tlv_octet_t ogs_pfcp_tlv_pfcpsrrsp_flags_t;
typedef ogs_tlv_octet_t ogs_pfcp_tlv_sequence_number_t;
typedef ogs_tlv_octet_t ogs_pfcp_tlv_metricp_t;
typedef ogs_tlv_octet_t ogs_pfcp_tlv_timer_t;
typedef ogs_tlv_octet_t ogs_pfcp_tlv_packet_detection_rule_id_t;
typedef ogs_tlv_octet_t ogs_pfcp_tlv_f_seid_t;
typedef ogs_tlv_octet_t ogs_pfcp_tlv_node_id_t;
typedef ogs_tlv_octet_t ogs_pfcp_tlv_pfd_contents_t;
typedef ogs_tlv_octet_t ogs_pfcp_tlv_measurement_method_t;
typedef ogs_tlv_octet_t ogs_pfcp_tlv_usage_report_trigger_t;
typedef ogs_tlv_octet_t ogs_pfcp_tlv_measurement_period_t;
typedef ogs_tlv_octet_t ogs_pfcp_tlv_fq_csidp_t;
typedef ogs_tlv_octet_t ogs_pfcp_tlv_volume_measurement_t;
typedef ogs_tlv_octet_t ogs_pfcp_tlv_duration_measurement_t;
typedef ogs_tlv_octet_t ogs_pfcp_tlv_time_of_first_packet_t;
typedef ogs_tlv_octet_t ogs_pfcp_tlv_time_of_last_packet_t;
typedef ogs_tlv_octet_t ogs_pfcp_tlv_quota_holding_time_t;
typedef ogs_tlv_octet_t ogs_pfcp_tlv_dropped_dl_traffic_threshold_t;
typedef ogs_tlv_octet_t ogs_pfcp_tlv_volume_quota_t;
typedef ogs_tlv_octet_t ogs_pfcp_tlv_time_quota_t;
typedef ogs_tlv_octet_t ogs_pfcp_tlv_start_time_t;
typedef ogs_tlv_octet_t ogs_pfcp_tlv_end_time_t;
typedef ogs_tlv_octet_t ogs_pfcp_tlv_urr_id_t;
typedef ogs_tlv_octet_t ogs_pfcp_tlv_linked_urr_id_t;
typedef ogs_tlv_octet_t ogs_pfcp_tlv_outer_header_creation_t;
typedef ogs_tlv_octet_t ogs_pfcp_tlv_bar_id_t;
typedef ogs_tlv_octet_t ogs_pfcp_tlv_cp_function_features_t;
typedef ogs_tlv_octet_t ogs_pfcp_tlv_usage_information_t;
typedef ogs_tlv_octet_t ogs_pfcp_tlv_application_instance_id_t;
typedef ogs_tlv_octet_t ogs_pfcp_tlv_flow_information_t;
typedef ogs_tlv_octet_t ogs_pfcp_tlv_ue_ip_address_t;
typedef ogs_tlv_octet_t ogs_pfcp_tlv_packet_rate_t;
typedef ogs_tlv_octet_t ogs_pfcp_tlv_outer_header_removal_t;
typedef ogs_tlv_octet_t ogs_pfcp_tlv_recovery_time_stamp_t;
typedef ogs_tlv_octet_t ogs_pfcp_tlv_dl_flow_level_marking_t;
typedef ogs_tlv_octet_t ogs_pfcp_tlv_header_enrichment_t;
typedef ogs_tlv_octet_t ogs_pfcp_tlv_measurement_information_t;
typedef ogs_tlv_octet_t ogs_pfcp_tlv_node_report_type_t;
typedef ogs_tlv_octet_t ogs_pfcp_tlv_user_plane_path_failure_report_t;
typedef ogs_tlv_octet_t ogs_pfcp_tlv_remote_gtp_u_peer_t;
typedef ogs_tlv_octet_t ogs_pfcp_tlv_ur_seqn_t;
typedef ogs_tlv_octet_t ogs_pfcp_tlv_activate_predefined_rules_t;
typedef ogs_tlv_octet_t ogs_pfcp_tlv_deactivate_predefined_rules_t;
typedef ogs_tlv_octet_t ogs_pfcp_tlv_far_id_t;
typedef ogs_tlv_octet_t ogs_pfcp_tlv_qer_id_t;
typedef ogs_tlv_octet_t ogs_pfcp_tlv_oci_flags_t;
typedef ogs_tlv_octet_t ogs_pfcp_tlv_pfcp_association_release_request_t;
typedef ogs_tlv_octet_t ogs_pfcp_tlv_graceful_release_period_t;
typedef ogs_tlv_octet_t ogs_pfcp_tlv_pdn_typep_t;
typedef ogs_tlv_octet_t ogs_pfcp_tlv_failed_rule_id_t;
typedef ogs_tlv_octet_t ogs_pfcp_tlv_time_quota_mechanism_t;
typedef ogs_tlv_octet_t ogs_pfcp_tlv_user_plane_ip_resource_information_t;
typedef ogs_tlv_octet_t ogs_pfcp_tlv_user_plane_inactivity_timer_t;
typedef ogs_tlv_octet_t ogs_pfcp_tlv_aggregated_urrs_t;
typedef ogs_tlv_octet_t ogs_pfcp_tlv_multiplier_t;
typedef ogs_tlv_octet_t ogs_pfcp_tlv_aggregated_urr_id_t;
typedef ogs_tlv_octet_t ogs_pfcp_tlv_subsequent_volume_quota_t;
typedef ogs_tlv_octet_t ogs_pfcp_tlv_subsequent_time_quota_t;
typedef ogs_tlv_octet_t ogs_pfcp_tlv_rqi_t;
typedef ogs_tlv_octet_t ogs_pfcp_tlv_qfi_t;
/* Structure for Group Infomration Element */
typedef struct ogs_pfcp_tlv_pdi_s {
ogs_tlv_presence_t presence;
ogs_pfcp_tlv_source_interface_t source_interface;
ogs_pfcp_tlv_f_teid_t local_f_teid; /* Instance : 0 */
ogs_pfcp_tlv_network_instance_t network_instance;
ogs_pfcp_tlv_ue_ip_address_t ue_ip_address;
ogs_pfcp_tlv_sdf_filter_t sdf_filter;
ogs_pfcp_tlv_application_id_t application_id;
} ogs_pfcp_tlv_pdi_t; ;
typedef struct ogs_pfcp_tlv_forwarding_parameters_s {
ogs_tlv_presence_t presence;
ogs_pfcp_tlv_destination_interface_t destination_interface;
ogs_pfcp_tlv_network_instance_t network_instance;
ogs_pfcp_tlv_redirect_information_t redirect_information;
ogs_pfcp_tlv_outer_header_creation_t outer_header_creation;
ogs_pfcp_tlv_transport_level_marking_t transport_level_marking;
ogs_pfcp_tlv_forwarding_policy_t forwarding_policy;
ogs_pfcp_tlv_header_enrichment_t header_enrichment;
} ogs_pfcp_tlv_forwarding_parameters_t; ;
typedef struct ogs_pfcp_tlv_duplicating_parameters_s {
ogs_tlv_presence_t presence;
ogs_pfcp_tlv_destination_interface_t destination_interface;
ogs_pfcp_tlv_outer_header_creation_t outer_header_creation;
ogs_pfcp_tlv_transport_level_marking_t transport_level_marking;
ogs_pfcp_tlv_forwarding_policy_t forwarding_policy;
} ogs_pfcp_tlv_duplicating_parameters_t; ;
typedef struct ogs_pfcp_tlv_create_urr_s {
ogs_tlv_presence_t presence;
ogs_pfcp_tlv_urr_id_t urr_id;
ogs_pfcp_tlv_measurement_method_t measurement_method;
ogs_pfcp_tlv_reporting_triggers_t reporting_triggers;
ogs_pfcp_tlv_measurement_period_t measurement_period;
ogs_pfcp_tlv_volume_threshold_t volume_threshold;
ogs_pfcp_tlv_volume_quota_t volume_quota;
ogs_pfcp_tlv_time_threshold_t time_threshold;
ogs_pfcp_tlv_time_quota_t time_quota;
ogs_pfcp_tlv_quota_holding_time_t quota_holding_time;
ogs_pfcp_tlv_dropped_dl_traffic_threshold_t dropped_dl_traffic_threshold;
ogs_pfcp_tlv_monitoring_time_t monitoring_time;
ogs_pfcp_tlv_subsequent_volume_threshold_t subsequent_volume_threshold;
ogs_pfcp_tlv_subsequent_time_threshold_t subsequent_time_threshold;
ogs_pfcp_tlv_subsequent_volume_quota_t subsequent_volume_quota;
ogs_pfcp_tlv_subsequent_time_quota_t subsequent_time_quota;
ogs_pfcp_tlv_inactivity_detection_time_t inactivity_detection_time;
ogs_pfcp_tlv_linked_urr_id_t linked_urr_id;
ogs_pfcp_tlv_measurement_information_t measurement_information;
ogs_pfcp_tlv_time_quota_mechanism_t time_quota_mechanism;
ogs_pfcp_tlv_aggregated_urrs_t aggregated_urrs;
} ogs_pfcp_tlv_create_urr_t; ;
typedef struct ogs_pfcp_tlv_create_qer_s {
ogs_tlv_presence_t presence;
ogs_pfcp_tlv_qer_id_t qer_id;
ogs_pfcp_tlv_qer_correlation_id_t qer_correlation_id;
ogs_pfcp_tlv_gate_status_t gate_status;
ogs_pfcp_tlv_mbr_t maximum_bitrate;
ogs_pfcp_tlv_gbr_t guaranteed_bitrate;
ogs_pfcp_tlv_packet_rate_t packet_rate;
ogs_pfcp_tlv_dl_flow_level_marking_t dl_flow_level_marking;
ogs_pfcp_tlv_qfi_t qos_flow_identifier;
ogs_pfcp_tlv_rqi_t reflective_qos;
} ogs_pfcp_tlv_create_qer_t; ;
typedef struct ogs_pfcp_tlv_created_pdr_s {
ogs_tlv_presence_t presence;
ogs_pfcp_tlv_packet_detection_rule_id_t pdr_id;
ogs_pfcp_tlv_f_teid_t local_f_teid; /* Instance : 0 */
} ogs_pfcp_tlv_created_pdr_t; ;
typedef struct ogs_pfcp_tlv_update_pdr_s {
ogs_tlv_presence_t presence;
ogs_pfcp_tlv_packet_detection_rule_id_t pdr_id;
ogs_pfcp_tlv_outer_header_removal_t outer_header_removal;
ogs_pfcp_tlv_precedence_t precedence;
ogs_pfcp_tlv_pdi_t pdi;
ogs_pfcp_tlv_far_id_t far_id;
ogs_pfcp_tlv_urr_id_t urr_id;
ogs_pfcp_tlv_qer_id_t qer_id;
ogs_pfcp_tlv_activate_predefined_rules_t activate_predefined_rules;
ogs_pfcp_tlv_deactivate_predefined_rules_t deactivate_predefined_rules;
} ogs_pfcp_tlv_update_pdr_t; ;
typedef struct ogs_pfcp_tlv_update_forwarding_parameters_s {
ogs_tlv_presence_t presence;
ogs_pfcp_tlv_destination_interface_t destination_interface;
ogs_pfcp_tlv_network_instance_t network_instance;
ogs_pfcp_tlv_redirect_information_t redirect_information;
ogs_pfcp_tlv_outer_header_creation_t outer_header_creation;
ogs_pfcp_tlv_transport_level_marking_t transport_level_marking;
ogs_pfcp_tlv_forwarding_policy_t forwarding_policy;
ogs_pfcp_tlv_header_enrichment_t header_enrichment;
ogs_pfcp_tlv_pfcpsmreq_flags_t sxsmreq_flags;
} ogs_pfcp_tlv_update_forwarding_parameters_t; ;
typedef struct ogs_pfcp_tlv_update_bar_pfcp_session_report_response_s {
ogs_tlv_presence_t presence;
ogs_pfcp_tlv_bar_id_t bar_id;
ogs_pfcp_tlv_downlink_data_notification_delay_t downlink_data_notification_delay;
ogs_pfcp_tlv_dl_buffering_duration_t dl_buffering_duration;
ogs_pfcp_tlv_dl_buffering_suggested_packet_count_t dl_buffering_suggested_packet_count;
} ogs_pfcp_tlv_update_bar_pfcp_session_report_response_t; ;
typedef struct ogs_pfcp_tlv_update_urr_s {
ogs_tlv_presence_t presence;
ogs_pfcp_tlv_urr_id_t urr_id;
ogs_pfcp_tlv_measurement_method_t measurement_method;
ogs_pfcp_tlv_reporting_triggers_t reporting_triggers;
ogs_pfcp_tlv_measurement_period_t measurement_period;
ogs_pfcp_tlv_volume_threshold_t volume_threshold;
ogs_pfcp_tlv_volume_quota_t volume_quota;
ogs_pfcp_tlv_time_threshold_t time_threshold;
ogs_pfcp_tlv_time_quota_t time_quota;
ogs_pfcp_tlv_quota_holding_time_t quota_holding_time;
ogs_pfcp_tlv_dropped_dl_traffic_threshold_t dropped_dl_traffic_threshold;
ogs_pfcp_tlv_monitoring_time_t monitoring_time;
ogs_pfcp_tlv_subsequent_volume_threshold_t subsequent_volume_threshold;
ogs_pfcp_tlv_subsequent_time_threshold_t subsequent_time_threshold;
ogs_pfcp_tlv_subsequent_volume_quota_t subsequent_volume_quota;
ogs_pfcp_tlv_subsequent_time_quota_t subsequent_time_quota;
ogs_pfcp_tlv_inactivity_detection_time_t inactivity_detection_time;
ogs_pfcp_tlv_linked_urr_id_t linked_urr_id;
ogs_pfcp_tlv_measurement_information_t measurement_information;
ogs_pfcp_tlv_time_quota_mechanism_t time_quota_mechanism;
ogs_pfcp_tlv_aggregated_urrs_t aggregated_urrs;
} ogs_pfcp_tlv_update_urr_t; ;
typedef struct ogs_pfcp_tlv_update_qer_s {
ogs_tlv_presence_t presence;
ogs_pfcp_tlv_qer_id_t qer_id;
ogs_pfcp_tlv_qer_correlation_id_t qer_correlation_id;
ogs_pfcp_tlv_gate_status_t gate_status;
ogs_pfcp_tlv_mbr_t maximum_bitrate;
ogs_pfcp_tlv_gbr_t guaranteed_bitrate;
ogs_pfcp_tlv_packet_rate_t packet_rate;
ogs_pfcp_tlv_dl_flow_level_marking_t dl_flow_level_marking;
ogs_pfcp_tlv_qfi_t qos_flow_identifier;
ogs_pfcp_tlv_rqi_t reflective_qos;
} ogs_pfcp_tlv_update_qer_t; ;
typedef struct ogs_pfcp_tlv_remove_pdr_s {
ogs_tlv_presence_t presence;
ogs_pfcp_tlv_packet_detection_rule_id_t pdr_id;
} ogs_pfcp_tlv_remove_pdr_t; ;
typedef struct ogs_pfcp_tlv_remove_far_s {
ogs_tlv_presence_t presence;
ogs_pfcp_tlv_far_id_t far_id;
} ogs_pfcp_tlv_remove_far_t; ;
typedef struct ogs_pfcp_tlv_remove_urr_s {
ogs_tlv_presence_t presence;
ogs_pfcp_tlv_urr_id_t urr_id;
} ogs_pfcp_tlv_remove_urr_t; ;
typedef struct ogs_pfcp_tlv_remove_qer_s {
ogs_tlv_presence_t presence;
ogs_pfcp_tlv_qer_id_t qer_id;
} ogs_pfcp_tlv_remove_qer_t; ;
typedef struct ogs_pfcp_tlv_load_control_informationp_s {
ogs_tlv_presence_t presence;
ogs_pfcp_tlv_sequence_number_t load_control_sequence_number;
ogs_pfcp_tlv_metricp_t load_metric;
} ogs_pfcp_tlv_load_control_informationp_t; ;
typedef struct ogs_pfcp_tlv_overload_control_informationp_s {
ogs_tlv_presence_t presence;
ogs_pfcp_tlv_sequence_number_t overload_control_sequence_number;
ogs_pfcp_tlv_metricp_t overload_reduction_metric;
ogs_pfcp_tlv_timer_t period_of_validity;
ogs_pfcp_tlv_oci_flags_t overload_control_information_flags;
} ogs_pfcp_tlv_overload_control_informationp_t; ;
typedef struct ogs_pfcp_tlv_pfd_context_s {
ogs_tlv_presence_t presence;
ogs_pfcp_tlv_pfd_contents_t pfd_contents;
} ogs_pfcp_tlv_pfd_context_t; ;
typedef struct ogs_pfcp_tlv_application_detection_information_s {
ogs_tlv_presence_t presence;
ogs_pfcp_tlv_application_id_t application_id;
ogs_pfcp_tlv_application_instance_id_t application_instance_id;
ogs_pfcp_tlv_flow_information_t flow_information;
} ogs_pfcp_tlv_application_detection_information_t; ;
typedef struct ogs_pfcp_tlv_query_urr_s {
ogs_tlv_presence_t presence;
ogs_pfcp_tlv_urr_id_t urr_id;
} ogs_pfcp_tlv_query_urr_t; ;
typedef struct ogs_pfcp_tlv_usage_report_in_session_modification_response_s {
ogs_tlv_presence_t presence;
ogs_pfcp_tlv_urr_id_t urr_id;
ogs_pfcp_tlv_ur_seqn_t ur_seqn;
ogs_pfcp_tlv_usage_report_trigger_t usage_report_trigger;
ogs_pfcp_tlv_start_time_t start_time;
ogs_pfcp_tlv_end_time_t end_time;
ogs_pfcp_tlv_volume_measurement_t volume_measurement;
ogs_pfcp_tlv_duration_measurement_t duration_measurement;
ogs_pfcp_tlv_time_of_first_packet_t time_of_first_packet;
ogs_pfcp_tlv_time_of_last_packet_t time_of_last_packet;
ogs_pfcp_tlv_usage_information_t usage_information;
} ogs_pfcp_tlv_usage_report_in_session_modification_response_t; ;
typedef struct ogs_pfcp_tlv_usage_report_session_deletion_response_s {
ogs_tlv_presence_t presence;
ogs_pfcp_tlv_urr_id_t urr_id;
ogs_pfcp_tlv_ur_seqn_t ur_seqn;
ogs_pfcp_tlv_usage_report_trigger_t usage_report_trigger;
ogs_pfcp_tlv_start_time_t start_time;
ogs_pfcp_tlv_end_time_t end_time;
ogs_pfcp_tlv_volume_measurement_t volume_measurement;
ogs_pfcp_tlv_duration_measurement_t duration_measurement;
ogs_pfcp_tlv_time_of_first_packet_t time_of_first_packet;
ogs_pfcp_tlv_time_of_last_packet_t time_of_last_packet;
ogs_pfcp_tlv_usage_information_t usage_information;
} ogs_pfcp_tlv_usage_report_session_deletion_response_t; ;
typedef struct ogs_pfcp_tlv_usage_report_session_report_request_s {
ogs_tlv_presence_t presence;
ogs_pfcp_tlv_urr_id_t urr_id;
ogs_pfcp_tlv_ur_seqn_t ur_seqn;
ogs_pfcp_tlv_usage_report_trigger_t usage_report_trigger;
ogs_pfcp_tlv_start_time_t start_time;
ogs_pfcp_tlv_end_time_t end_time;
ogs_pfcp_tlv_volume_measurement_t volume_measurement;
ogs_pfcp_tlv_duration_measurement_t duration_measurement;
ogs_pfcp_tlv_application_detection_information_t application_detection_information;
ogs_pfcp_tlv_ue_ip_address_t ue_ip_address;
ogs_pfcp_tlv_network_instance_t network_instance;
ogs_pfcp_tlv_time_of_first_packet_t time_of_first_packet;
ogs_pfcp_tlv_time_of_last_packet_t time_of_last_packet;
ogs_pfcp_tlv_usage_information_t usage_information;
} ogs_pfcp_tlv_usage_report_session_report_request_t; ;
typedef struct ogs_pfcp_tlv_downlink_data_report_s {
ogs_tlv_presence_t presence;
ogs_pfcp_tlv_packet_detection_rule_id_t pdr_id;
ogs_pfcp_tlv_downlink_data_service_information_t downlink_data_service_information;
} ogs_pfcp_tlv_downlink_data_report_t; ;
typedef struct ogs_pfcp_tlv_create_bar_s {
ogs_tlv_presence_t presence;
ogs_pfcp_tlv_bar_id_t bar_id;
ogs_pfcp_tlv_downlink_data_notification_delay_t downlink_data_notification_delay;
} ogs_pfcp_tlv_create_bar_t; ;
typedef struct ogs_pfcp_tlv_update_bar_session_modification_request_s {
ogs_tlv_presence_t presence;
ogs_pfcp_tlv_bar_id_t bar_id;
ogs_pfcp_tlv_downlink_data_notification_delay_t downlink_data_notification_delay;
} ogs_pfcp_tlv_update_bar_session_modification_request_t; ;
typedef struct ogs_pfcp_tlv_remove_bar_s {
ogs_tlv_presence_t presence;
ogs_pfcp_tlv_bar_id_t bar_id;
} ogs_pfcp_tlv_remove_bar_t; ;
typedef struct ogs_pfcp_tlv_error_indication_report_s {
ogs_tlv_presence_t presence;
ogs_pfcp_tlv_f_teid_t remote_f_teid; /* Instance : 0 */
} ogs_pfcp_tlv_error_indication_report_t; ;
typedef struct ogs_pfcp_tlv_update_duplicating_parameters_s {
ogs_tlv_presence_t presence;
ogs_pfcp_tlv_destination_interface_t destination_interface;
ogs_pfcp_tlv_outer_header_creation_t outer_header_creation;
ogs_pfcp_tlv_transport_level_marking_t transport_level_marking;
ogs_pfcp_tlv_forwarding_policy_t forwarding_policy;
} ogs_pfcp_tlv_update_duplicating_parameters_t; ;
typedef struct ogs_pfcp_tlv_create_pdr_s {
tlv_presence_t presence;
tlv_packet_detection_rule_id_t pdr_id;
tlv_precedence_t precedence;
tlv_pdi_t pdi;
tlv_outer_header_removal_t outer_header_removal;
tlv_far_id_t far_id;
tlv_urr_id_t urr_id;
tlv_qer_id_t qer_id;
tlv_activate_predefined_rules_t activate_predefined_rules;
} ogs_pfcp_tlv_create_pdr_t; ;
typedef struct ogs_pfcp_tlv_create_far_s {
tlv_presence_t presence;
tlv_far_id_t far_id;
tlv_apply_action_t apply_action;
tlv_forwarding_parameters_t forwarding_parameters;
tlv_duplicating_parameters_t duplicating_parameters;
tlv_bar_id_t bar_id;
} ogs_pfcp_tlv_create_far_t; ;
typedef struct ogs_pfcp_tlv_update_far_s {
tlv_presence_t presence;
tlv_far_id_t far_id;
tlv_apply_action_t apply_action;
tlv_update_forwarding_parameters_t update_forwarding_parameters;
tlv_update_duplicating_parameters_t update_duplicating_parameters;
tlv_bar_id_t bar_id;
} ogs_pfcp_tlv_update_far_t; ;
typedef struct ogs_pfcp_tlv_application_id_s_pfds_s {
tlv_presence_t presence;
tlv_application_id_t application_id;
tlv_pfd_context_t pfd;
} ogs_pfcp_tlv_application_id_s_pfds_t; ;
/* Structure for Message */
typedef struct ogs_pfcp_heartbeat_request_s {
ogs_pfcp_tlv_recovery_time_stamp_t recovery_time_stamp;
} ogs_pfcp_heartbeat_request_t;
typedef struct ogs_pfcp_heartbeat_response_s {
ogs_pfcp_tlv_recovery_time_stamp_t recovery_time_stamp;
} ogs_pfcp_heartbeat_response_t;
typedef struct ogs_pfcp_association_setup_request_s {
ogs_pfcp_tlv_node_id_t node_id;
ogs_pfcp_tlv_recovery_time_stamp_t recovery_time_stamp;
ogs_pfcp_tlv_up_function_features_t up_function_features;
ogs_pfcp_tlv_cp_function_features_t cp_function_features;
ogs_pfcp_tlv_user_plane_ip_resource_information_t user_plane_ip_resource_information;
} ogs_pfcp_association_setup_request_t;
typedef struct ogs_pfcp_association_setup_response_s {
ogs_pfcp_tlv_node_id_t node_id;
ogs_pfcp_tlv_cause_t cause;
ogs_pfcp_tlv_recovery_time_stamp_t recovery_time_stamp;
ogs_pfcp_tlv_up_function_features_t up_function_features;
ogs_pfcp_tlv_cp_function_features_t cp_function_features;
ogs_pfcp_tlv_user_plane_ip_resource_information_t user_plane_ip_resource_information;
} ogs_pfcp_association_setup_response_t;
typedef struct ogs_pfcp_association_update_request_s {
ogs_pfcp_tlv_node_id_t node_id;
ogs_pfcp_tlv_up_function_features_t up_function_features;
ogs_pfcp_tlv_cp_function_features_t cp_function_features;
ogs_pfcp_tlv_pfcp_association_release_request_t pfcp_association_release_request;
ogs_pfcp_tlv_graceful_release_period_t graceful_release_period;
ogs_pfcp_tlv_user_plane_ip_resource_information_t user_plane_ip_resource_information;
} ogs_pfcp_association_update_request_t;
typedef struct ogs_pfcp_association_update_response_s {
ogs_pfcp_tlv_node_id_t node_id;
ogs_pfcp_tlv_cause_t cause;
ogs_pfcp_tlv_up_function_features_t up_function_features;
ogs_pfcp_tlv_cp_function_features_t cp_function_features;
} ogs_pfcp_association_update_response_t;
typedef struct ogs_pfcp_association_release_request_s {
ogs_pfcp_tlv_node_id_t node_id;
} ogs_pfcp_association_release_request_t;
typedef struct ogs_pfcp_association_release_response_s {
ogs_pfcp_tlv_node_id_t node_id;
ogs_pfcp_tlv_cause_t cause;
} ogs_pfcp_association_release_response_t;
typedef struct ogs_pfcp_version_not_supported_response_s {
ogs_pfcp_tlv_cause_t cause;
ogs_pfcp_tlv_offending_ie_t offending_ie;
} ogs_pfcp_version_not_supported_response_t;
typedef struct ogs_pfcp_node_report_request_s {
ogs_pfcp_tlv_node_id_t node_id;
ogs_pfcp_tlv_node_report_type_t node_report_type;
ogs_pfcp_tlv_user_plane_path_failure_report_t user_plane_path_failure_report;
} ogs_pfcp_node_report_request_t;
typedef struct ogs_pfcp_node_report_response_s {
ogs_pfcp_tlv_node_id_t node_id;
ogs_pfcp_tlv_cause_t cause;
ogs_pfcp_tlv_offending_ie_t offending_ie;
} ogs_pfcp_node_report_response_t;
typedef struct ogs_pfcp_session_set_deletion_request_s {
ogs_pfcp_tlv_node_id_t node_id;
ogs_pfcp_tlv_fq_csidp_t sgw_c_fq_csid;
} ogs_pfcp_session_set_deletion_request_t;
typedef struct ogs_pfcp_session_set_deletion_response_s {
ogs_pfcp_tlv_node_id_t node_id;
ogs_pfcp_tlv_cause_t cause;
ogs_pfcp_tlv_offending_ie_t offending_ie;
} ogs_pfcp_session_set_deletion_response_t;
typedef struct ogs_pfcp_session_establishment_request_s {
ogs_pfcp_tlv_node_id_t node_id;
ogs_pfcp_tlv_f_seid_t cp_f_seid;
ogs_pfcp_tlv_create_pdr_t create_pdr;
ogs_pfcp_tlv_create_pdr_t create_pdr1;
ogs_pfcp_tlv_create_far_t create_far;
ogs_pfcp_tlv_create_far_t create_far1;
ogs_pfcp_tlv_create_urr_t create_urr;
ogs_pfcp_tlv_create_qer_t create_qer;
ogs_pfcp_tlv_create_bar_t create_bar;
ogs_pfcp_tlv_pdn_typep_t pdn_type;
ogs_pfcp_tlv_fq_csidp_t sgw_c_fq_csid;
ogs_pfcp_tlv_user_plane_inactivity_timer_t user_plane_inactivity_timer;
} ogs_pfcp_session_establishment_request_t;
typedef struct ogs_pfcp_session_establishment_response_s {
ogs_pfcp_tlv_node_id_t node_id;
ogs_pfcp_tlv_cause_t cause;
ogs_pfcp_tlv_offending_ie_t offending_ie;
ogs_pfcp_tlv_f_seid_t up_f_seid;
ogs_pfcp_tlv_created_pdr_t created_pdr;
ogs_pfcp_tlv_load_control_informationp_t load_control_information;
ogs_pfcp_tlv_overload_control_informationp_t overload_control_information;
ogs_pfcp_tlv_fq_csidp_t sgw_u_fq_csid;
ogs_pfcp_tlv_failed_rule_id_t failed_rule_id;
} ogs_pfcp_session_establishment_response_t;
typedef struct ogs_pfcp_session_modification_request_s {
ogs_pfcp_tlv_f_seid_t cp_f_seid;
ogs_pfcp_tlv_remove_pdr_t remove_pdr;
ogs_pfcp_tlv_remove_far_t remove_far;
ogs_pfcp_tlv_remove_urr_t remove_urr;
ogs_pfcp_tlv_remove_qer_t remove_qer;
ogs_pfcp_tlv_remove_bar_t remove_bar;
ogs_pfcp_tlv_create_pdr_t create_pdr;
ogs_pfcp_tlv_create_pdr_t create_pdr1;
ogs_pfcp_tlv_create_far_t create_far;
ogs_pfcp_tlv_create_far_t create_far1;
ogs_pfcp_tlv_create_urr_t create_urr;
ogs_pfcp_tlv_create_qer_t create_qer;
ogs_pfcp_tlv_create_bar_t create_bar;
ogs_pfcp_tlv_update_pdr_t update_pdr;
ogs_pfcp_tlv_update_pdr_t update_pdr1;
ogs_pfcp_tlv_update_far_t update_far;
ogs_pfcp_tlv_update_urr_t update_urr;
ogs_pfcp_tlv_update_qer_t update_qer;
ogs_pfcp_tlv_update_bar_session_modification_request_t update_bar;
ogs_pfcp_tlv_pfcpsmreq_flags_t pfcpsmreq_flags;
ogs_pfcp_tlv_query_urr_t query_urr;
ogs_pfcp_tlv_fq_csidp_t pgw_c_fq_csid;
ogs_pfcp_tlv_user_plane_inactivity_timer_t user_plane_inactivity_timer;
} ogs_pfcp_session_modification_request_t;
typedef struct ogs_pfcp_session_modification_response_s {
ogs_pfcp_tlv_cause_t cause;
ogs_pfcp_tlv_offending_ie_t offending_ie;
ogs_pfcp_tlv_created_pdr_t created_pdr;
ogs_pfcp_tlv_load_control_informationp_t load_control_information;
ogs_pfcp_tlv_overload_control_informationp_t overload_control_information;
ogs_pfcp_tlv_usage_report_in_session_modification_response_t usage_report;
ogs_pfcp_tlv_failed_rule_id_t failed_rule_id;
} ogs_pfcp_session_modification_response_t;
typedef struct ogs_pfcp_session_deletion_request_s {
} ogs_pfcp_session_deletion_request_t;
typedef struct ogs_pfcp_session_report_request_s {
ogs_pfcp_tlv_report_type_t report_type;
ogs_pfcp_tlv_downlink_data_report_t downlink_data_report;
ogs_pfcp_tlv_usage_report_session_report_request_t usage_report;
ogs_pfcp_tlv_error_indication_report_t error_indication_report;
ogs_pfcp_tlv_load_control_informationp_t load_control_information;
ogs_pfcp_tlv_overload_control_informationp_t overload_control_information;
} ogs_pfcp_session_report_request_t;
typedef struct ogs_pfcp_session_report_response_s {
ogs_pfcp_tlv_cause_t cause;
ogs_pfcp_tlv_offending_ie_t offending_ie;
ogs_pfcp_tlv_update_bar_pfcp_session_report_response_t update_bar;
ogs_pfcp_tlv_pfcpsrrsp_flags_t pfcpsrrsp_flags;
} ogs_pfcp_session_report_response_t;
typedef struct ogs_pfcp_message_s {
ogs_pfcp_header_t h;
union {
ogs_pfcp_heartbeat_request_t pfcp_heartbeat_request;
ogs_pfcp_heartbeat_response_t pfcp_heartbeat_response;
ogs_pfcp_association_setup_request_t pfcp_association_setup_request;
ogs_pfcp_association_setup_response_t pfcp_association_setup_response;
ogs_pfcp_association_update_request_t pfcp_association_update_request;
ogs_pfcp_association_update_response_t pfcp_association_update_response;
ogs_pfcp_association_release_request_t pfcp_association_release_request;
ogs_pfcp_association_release_response_t pfcp_association_release_response;
ogs_pfcp_version_not_supported_response_t pfcp_version_not_supported_response;
ogs_pfcp_node_report_request_t pfcp_node_report_request;
ogs_pfcp_node_report_response_t pfcp_node_report_response;
ogs_pfcp_session_set_deletion_request_t pfcp_session_set_deletion_request;
ogs_pfcp_session_set_deletion_response_t pfcp_session_set_deletion_response;
ogs_pfcp_session_establishment_request_t pfcp_session_establishment_request;
ogs_pfcp_session_establishment_response_t pfcp_session_establishment_response;
ogs_pfcp_session_modification_request_t pfcp_session_modification_request;
ogs_pfcp_session_modification_response_t pfcp_session_modification_response;
ogs_pfcp_session_deletion_request_t pfcp_session_deletion_request;
ogs_pfcp_session_report_request_t pfcp_session_report_request;
ogs_pfcp_session_report_response_t pfcp_session_report_response;
};
} ogs_pfcp_message_t;
int ogs_pfcp_parse_msg(ogs_pfcp_message_t *pfcp_message, ogs_pkbuf_t *pkbuf);
ogs_pkbuf_t *ogs_pfcp_build_msg(ogs_pfcp_message_t *pfcp_message);
#ifdef __cplusplus
}
#endif
#endif /* OGS_PFCP_MESSAGE_H */

Binary file not shown.

View File

@ -0,0 +1,16 @@
* Install python-pip
user@host ~/Documents/git/open5gs/lib/gtp/support$ \
sudo apt-get install python-pip
* Install python-docx
user@host ~/Documents/git/open5gs/lib/gtp/support$ \
sudo pip install python-docx
* Change the format of standard specification
from 29244-f40.doc to 29274-f40.docx
using Microsoft Office 2007+
* Generate TLV support files
user@host ~/Documents/git/open5gs/lib/pfcp/support$ \
python pfcp-tlv.py -f 29244-f40.docx -o ..

244
lib/pfcp/support/cache/tlv-group-list.py vendored Normal file
View File

@ -0,0 +1,244 @@
ies = []
ies.append({ "ie_type" : "Application ID", "ie_value" : "Application ID", "presence" : "M", "instance" : "0", "comment" : "This IE shall identify the Application ID for which PFDs shall be provisioned in the UP function."})
ies.append({ "ie_type" : "PFD context", "ie_value" : "PFD", "presence" : "C", "instance" : "0", "comment" : "This IE shall be present if the PFD needs to be provisioned in the UP function. When present, it shall describe the PFD to be provisioned in the UP function.Several IEs with the same IE type may be present to provision multiple PFDs for this Application ID. When this IE is absent, the UP function shall delete all the PFDs received and stored earlier in the UP function for this Application ID."})
group_list["Application ID's PFDs"] = { "type" : "58", "ies" : ies }
ies = []
ies.append({ "ie_type" : "PFD contents", "ie_value" : "PFD Contents", "presence" : "M", "instance" : "0", "comment" : "This IE shall describe the PFD to be provisioned in the UP function. Several IEs with the same IE type may be present to provision multiple contents for this PFD."})
group_list["PFD context"] = { "type" : "59", "ies" : ies }
ies = []
ies.append({ "ie_type" : "Packet Detection Rule ID", "ie_value" : "PDR ID", "presence" : "M", "instance" : "0", "comment" : "This IE shall uniquely identify the PDR among all the PDRs configured for that PFCP session."})
ies.append({ "ie_type" : "Precedence", "ie_value" : "Precedence", "presence" : "M", "instance" : "0", "comment" : "This IE shall indicate the PDRs precedence to be applied by the UP function among all PDRs of the PFCP session, when looking for a PDR matching an incoming packet."})
ies.append({ "ie_type" : "PDI", "ie_value" : "PDI", "presence" : "M", "instance" : "0", "comment" : "This IE shall contain the PDI against which incoming packets will be matched. See Table 7.5.2.2-2."})
ies.append({ "ie_type" : "Outer Header Removal", "ie_value" : "Outer Header Removal", "presence" : "C", "instance" : "0", "comment" : "This IE shall be present if the UP function is required to remove one or more outer header(s) from the packets matching this PDR."})
ies.append({ "ie_type" : "FAR ID", "ie_value" : "FAR ID", "presence" : "C", "instance" : "0", "comment" : "This IE shall be present if the Activate Predefined Rules IE is not included or if it is included but it does not result in activating a predefined FAR.When present this IE shall contain the FAR ID to be associated to the PDR."})
ies.append({ "ie_type" : "URR ID", "ie_value" : "URR ID", "presence" : "C", "instance" : "0", "comment" : "This IE shall be present if a measurement action shall be applied to packets matching this PDR.When present, this IE shall contain the URR IDs to be associated to the PDR. Several IEs within the same IE type may be present to represent a list of URRs to be associated to the PDR."})
ies.append({ "ie_type" : "QER ID", "ie_value" : "QER ID", "presence" : "C", "instance" : "0", "comment" : "This IE shall be present if a QoS enforcement action shall be applied to packets matching this PDR.When present, this IE shall contain the QER IDs to be associated to the PDR. Several IEs within the same IE type may be present to represent a list of QERs to be associated to the PDR."})
ies.append({ "ie_type" : "Activate Predefined Rules", "ie_value" : "Activate Predefined Rules", "presence" : "C", "instance" : "0", "comment" : "This IE shall be present if Predefined Rule(s) shall be activated for this PDR. When present this IE shall contain one Predefined Rules name.Several IEs with the same IE type may be present to represent multiple Activate Predefined Rules names."})
group_list["Create PDR"] = { "type" : "1", "ies" : ies }
ies = []
ies.append({ "ie_type" : "Source Interface", "ie_value" : "Source Interface", "presence" : "M", "instance" : "0", "comment" : "This IE shall identify the source interface of the incoming packet."})
ies.append({ "ie_type" : "F-TEID", "ie_value" : "Local F-TEID", "presence" : "O", "instance" : "0", "comment" : "If present, this IE shall identify the local F-TEID to match for an incoming packet. The CP function shall set the CHOOSE (CH) bit to 1 if the UP function supports the allocation of F-TEID and the CP function requests the UP function to assign a local F-TEID to the PDR."})
ies.append({ "ie_type" : "Network Instance", "ie_value" : "Network Instance", "presence" : "O", "instance" : "0", "comment" : "If present, this IE shall identify the Network instance to match for the incoming packet. See NOTE 1, NOTE2."})
ies.append({ "ie_type" : "UE IP Address", "ie_value" : "UE IP address", "presence" : "O", "instance" : "0", "comment" : "If present, this IE shall identify the source or destination IP address to match for the incoming packet. "})
ies.append({ "ie_type" : "SDF Filter", "ie_value" : "SDF Filter", "presence" : "O", "instance" : "0", "comment" : "If present, this IE shall identify the SDF filter to match for the incoming packet. "})
ies.append({ "ie_type" : "Application ID", "ie_value" : "Application ID", "presence" : "O", "instance" : "0", "comment" : "If present, this IE shall identify the Application ID to match for the incoming packet. "})
group_list["PDI"] = { "type" : "2", "ies" : ies }
ies = []
ies.append({ "ie_type" : "FAR ID", "ie_value" : "FAR ID", "presence" : "M", "instance" : "0", "comment" : "This IE shall uniquely identify the FAR among all the FARs configured for that PFCP session."})
ies.append({ "ie_type" : "Apply Action", "ie_value" : "Apply Action", "presence" : "M", "instance" : "0", "comment" : "This IE shall indicate the action to apply to the packets, See subclauses 5.2.1 and 5.2.3."})
ies.append({ "ie_type" : "Forwarding Parameters", "ie_value" : "Forwarding Parameters", "presence" : "C", "instance" : "0", "comment" : "This IE shall be present when the Apply-Action requests the packets to be forwarded. It may be present otherwise. When present, this IE shall contain the forwarding instructions to be applied by the UP function when the Apply-Action requests the packets to be forwarded. See table 7.5.2.3-2."})
ies.append({ "ie_type" : "Duplicating Parameters", "ie_value" : "Duplicating Parameters", "presence" : "C", "instance" : "0", "comment" : "This IE shall be present when the Apply-Action requests the packets to be duplicated. It may be present otherwise. When present, this IE shall contain the forwarding instructions to be applied by the UP function for the traffic to be duplicated, when the Apply-Action requests the packets to be duplicated. See table 7.5.2.3-3."})
ies.append({ "ie_type" : "BAR ID", "ie_value" : "BAR ID", "presence" : "O", "instance" : "0", "comment" : "When present, this IE shall contain the BAR ID of the BAR defining the buffering instructions to be applied by the UP function when the Apply Action requests the packets to be buffered. See table 7.5.2.6-1."})
group_list["Create FAR"] = { "type" : "3", "ies" : ies }
ies = []
ies.append({ "ie_type" : "Destination Interface", "ie_value" : "Destination Interface", "presence" : "M", "instance" : "0", "comment" : "This IE shall identify the destination interface of the outgoing packet."})
ies.append({ "ie_type" : "Network Instance", "ie_value" : "Network Instance", "presence" : "O", "instance" : "0", "comment" : "When present, this IE shall identify the Network instance towards which to send the outgoing packet. See NOTE 1."})
ies.append({ "ie_type" : "Redirect Information", "ie_value" : "Redirect Information", "presence" : "C", "instance" : "0", "comment" : "This IE shall be present if the UP function is required to enforce traffic redirection towards a redirect destination provided by the CP function. "})
ies.append({ "ie_type" : "Outer Header Creation", "ie_value" : "Outer Header Creation", "presence" : "C", "instance" : "0", "comment" : "This IE shall be present if the UP function is required to add one or more outer header(s) to the outgoing packet. If present, it shall contain the F-TEID of the remote GTP-U peer when adding a GTP-U/UDP/IP header, or the Destination IP address and Port Number when adding a UDP/IP header."})
ies.append({ "ie_type" : "Transport Level Marking", "ie_value" : "Transport Level Marking", "presence" : "C", "instance" : "0", "comment" : "This IE shall be present if the UP function is required to mark the IP header with the DSCP marking as defined by IETFRFC2474[22]. When present, it shall contain the value of the DSCP in the TOS/Traffic Class field set based on the QCI, and optionally the ARP priority level, of the associated EPS bearer, as described in sub-clause 4.7.3 of 3GPPTS23.214[2]."})
ies.append({ "ie_type" : "Forwarding Policy", "ie_value" : "Forwarding Policy", "presence" : "C", "instance" : "0", "comment" : "This IE shall be present if a specific forwarding policy is required to be applied to the packets. It shall be present if the Destination Interface IE is set to SGi-LAN. It may be present if the Destination Interface is set to Core. When present, it shall contain an Identifier of the Forwarding Policy locally configured in the UP function."})
ies.append({ "ie_type" : "Header Enrichment", "ie_value" : "Header Enrichment", "presence" : "O", "instance" : "0", "comment" : "This IE may be present if the UP function indicated support of Header Enrichment of UL traffic. When present, it shall contain information for header enrichment."})
group_list["Forwarding Parameters"] = { "type" : "4", "ies" : ies }
ies = []
ies.append({ "ie_type" : "Destination Interface", "ie_value" : "Destination Interface", "presence" : "M", "instance" : "0", "comment" : "This IE shall identify the destination interface of the outgoing packet."})
ies.append({ "ie_type" : "Outer Header Creation", "ie_value" : "Outer Header Creation", "presence" : "C", "instance" : "0", "comment" : "This IE shall be present if the UP function is required to add one or more outer header(s) to the outgoing packet. If present, it shall contain the F-TEID of the remote GTP-U peer."})
ies.append({ "ie_type" : "Transport Level Marking", "ie_value" : "Transport Level marking", "presence" : "C", "instance" : "0", "comment" : "This IE shall be present if the UP function is required to mark the IP header with the DSCP marking as defined by IETFRFC2474[22]. When present, it shall contain the value of the DSCP in the TOS/Traffic Class field. "})
ies.append({ "ie_type" : "Forwarding Policy", "ie_value" : "Forwarding Policy", "presence" : "C", "instance" : "0", "comment" : "This IE shall be present if a specific forwarding policy is required to be applied to the packets. When present, it shall contain an Identifier of the Forwarding Policy locally configured in the UP function."})
group_list["Duplicating Parameters"] = { "type" : "5", "ies" : ies }
ies = []
ies.append({ "ie_type" : "URR ID", "ie_value" : "URR ID", "presence" : "M", "instance" : "0", "comment" : "This IE shall uniquely identify the URR among all the URRs configured for this PFCP session."})
ies.append({ "ie_type" : "Measurement Method", "ie_value" : "Measurement Method", "presence" : "M", "instance" : "0", "comment" : "This IE shall indicate the method for measuring the network resources usage, i.e. whether the data volume, duration (i.e. time), combined volume/duration, or event shall be measured."})
ies.append({ "ie_type" : "Reporting Triggers", "ie_value" : "Reporting Triggers", "presence" : "M", "instance" : "0", "comment" : "This IE shall indicate the trigger(s) for reporting network resources usage to the CP function, e.g. periodic reporting or reporting upon reaching a threshold, or envelope closure."})
ies.append({ "ie_type" : "Measurement Period", "ie_value" : "Measurement Period", "presence" : "C", "instance" : "0", "comment" : "This IE shall be present if periodic reporting is required. When present, it shall indicate the period for generating and reporting usage reports. "})
ies.append({ "ie_type" : "Volume Threshold", "ie_value" : "Volume Threshold", "presence" : "C", "instance" : "0", "comment" : "This IE shall be present if volume-based measurement is used and reporting is required upon reaching a volume threshold. When present, it shall indicate the traffic volume value after which the UP function shall report network resources usage to the CP function for this URR."})
ies.append({ "ie_type" : "Volume Quota", "ie_value" : "Volume Quota", "presence" : "C", "instance" : "0", "comment" : "This IE shall be present if volume-based measurement is used and the CP function needs to provision a Volume Quota in the UP function (see subclause 5.2.2.2) When present, it shall indicate the Volume Quota value."})
ies.append({ "ie_type" : "Time Threshold", "ie_value" : "Time Threshold", "presence" : "C", "instance" : "0", "comment" : "This IE shall be present if time-based measurement is used and reporting is required upon reaching a time threshold. When present, it shall indicate the time usage after which the UP function shall report network resources usage to the CP function for this URR."})
ies.append({ "ie_type" : "Time Quota", "ie_value" : "Time Quota", "presence" : "C", "instance" : "0", "comment" : "This IE shall be present if time-based measurement is used and the CP function needs to provision a Time Quota in the UP function (see subclause 5.2.2.2) When present, it shall indicate the Time Quota value"})
ies.append({ "ie_type" : "Quota Holding Time", "ie_value" : "Quota Holding Time", "presence" : "C", "instance" : "0", "comment" : "This IE shall be present, for a time, volume or event-based measurement, if reporting is required and packets are no longer permitted to pass on when no packets are received during a given inactivity period. When present, it shall contain the duration of the inactivity period."})
ies.append({ "ie_type" : "Dropped DL Traffic Threshold", "ie_value" : "Dropped DL Traffic Threshold", "presence" : "C", "instance" : "0", "comment" : "This IE shall be present if reporting is required when the DL traffic being dropped exceeds a threshold. When present, it shall contain the threshold of the DL traffic being dropped."})
ies.append({ "ie_type" : "Monitoring Time", "ie_value" : "Monitoring Time", "presence" : "O", "instance" : "0", "comment" : "When present, this IE shall contain the time at which the UP function shall re-apply the volume or time threshold. "})
ies.append({ "ie_type" : "Subsequent Volume Threshold", "ie_value" : "Subsequent Volume Threshold", "presence" : "O", "instance" : "0", "comment" : "This IE may be present if the Monitoring Time IE is present and volume-based measurement is used. When present, it shall indicate the traffic volume value after which the UP function shall report network resources usage to the CP function for this URR for the period after the Monitoring Time."})
ies.append({ "ie_type" : "Subsequent Time Threshold", "ie_value" : "Subsequent Time Threshold", "presence" : "O", "instance" : "0", "comment" : "This IE may be present if the Monitoring Time IE is present and time-based measurement is used. When present, it shall indicate the time usage after which the UP function shall report network resources usage to the CP function for this URR for the period after the Monitoring Time."})
ies.append({ "ie_type" : "Subsequent Volume Quota", "ie_value" : "Subsequent Volume Quota", "presence" : "O", "instance" : "0", "comment" : "This IE may be present if Monitoring Time IE is present and volume-based measurement is used (see subclause 5.2.2.2). When present, it shall indicate the Volume Quota value which the UP function shall use for this URR for the period after the Monitoring Time."})
ies.append({ "ie_type" : "Subsequent Time Quota", "ie_value" : "Subsequent Time Quota", "presence" : "O", "instance" : "0", "comment" : "This IE may be present if Monitoring Time IE is present and time-based measurement is used (see subclause 5.2.2.2) When present, it shall indicate the Time Quota value which the UP function shall use for this URR for the period after the Monitoring Time."})
ies.append({ "ie_type" : "Inactivity Detection Time", "ie_value" : "Inactivity Detection Time", "presence" : "C", "instance" : "0", "comment" : "This IE shall be present if time-based measurement is used and the time measurement need to be suspended when no packets are received during a given inactivity period. When present, it shall contain the duration of the inactivity period."})
ies.append({ "ie_type" : "Linked URR ID", "ie_value" : "Linked URR ID", "presence" : "C", "instance" : "0", "comment" : "This IE shall be present if linked usage reporting is required. When present, this IE shall contain the linked URR ID which is related with this URR (see subclause 5.2.2.4). "})
ies.append({ "ie_type" : "Measurement Information", "ie_value" : "Measurement Information", "presence" : "C", "instance" : "0", "comment" : "This IE shall be included if any of the following flag is set to 1.Applicable flags are:- Measurement Before QoS Enforcement Flag: this flag shall be set to 1 if the traffic usage before any QoS Enforcement is requested to be measured. - Inactive Measurement Flag: this flag shall be set to 1 if the measurement shall be paused (inactive). The measurement shall be performed (active) if the bit is set to 0 or if the Measurement Information IE is not present in the Create URR IE.- Reduced Application Detection Information Flag: this flag may be set to 1, if the Reporting Triggers request to report the start or stop of application, to request the UP function to only report the Application ID in the Application Detection Information, e.g. for envelope reporting."})
ies.append({ "ie_type" : "Time Quota Mechanism", "ie_value" : "Time Quota Mechanism", "presence" : "C", "instance" : "0", "comment" : "This IE shall be present if time-based measurement based on CTP or DTP is used."})
ies.append({ "ie_type" : "Aggregated URRs", "ie_value" : "Aggregated URRs", "presence" : "C", "instance" : "0", "comment" : "This IE shall be included if the URR is used to support a Credit Pool.Several IEs with the same IE type may be present to provide multiple aggregated URRs."})
group_list["Create URR"] = { "type" : "6", "ies" : ies }
ies = []
ies.append({ "ie_type" : "QER ID", "ie_value" : "QER ID", "presence" : "M", "instance" : "0", "comment" : "This IE shall uniquely identify the QER among all the QER configured for that PFCP session"})
ies.append({ "ie_type" : "QER Correlation ID", "ie_value" : "QER Correlation ID", "presence" : "C", "instance" : "0", "comment" : "This IE shall be present if the UP function is required to correlate the QERs of several PFCP sessions, for APN-AMBR enforcement of multiple UEs PDN connections to the same APN."})
ies.append({ "ie_type" : "Gate Status", "ie_value" : "Gate Status", "presence" : "M", "instance" : "0", "comment" : "This IE shall indicate whether the packets are allowed to be forwarded (the gate is open) or shall be discarded (the gate is closed) in the uplink and/or downlink directions."})
ies.append({ "ie_type" : "MBR", "ie_value" : "Maximum Bitrate", "presence" : "C", "instance" : "0", "comment" : "This IE shall be present if an MBR enforcement action shall be applied to packets matching this PDR. When present, this IE shall indicate the uplink and/or downlink maximum bit rate to be enforced for packets matching the PDR.This IE may be set to the value of: - the APN-AMBR, for a QER that is referenced by all the PDRs of the non-GBR bearers of a PDN connection; - the TDF session MBR, for a QER that is referenced by all the PDRs of a TDF session;- the bearer MBR, for a QER that is referenced by all the PDRs of a bearer;- the SDF MBR, for a QER that is referenced by all the PDRs of a SDF."})
ies.append({ "ie_type" : "GBR", "ie_value" : "Guaranteed Bitrate", "presence" : "C", "instance" : "0", "comment" : "This IE shall be present if a GBR has been authorized to packets matching this PDR. When present, this IE shall indicate the authorized uplink and/or downlink guaranteed bit rate.This IE may be set to the value of: - the aggregate GBR, for a QER that is referenced by all the PDRs of a GBR bearer;- the SDF GBR, for a QER that is referenced by all the PDRs of a SDF."})
ies.append({ "ie_type" : "Packet Rate", "ie_value" : "Packet Rate", "presence" : "C", "instance" : "0", "comment" : "This IE shall be present if a Packet Rate enforcement action (in terms of number of packets per time interval) shall be applied to packets matching this PDR. When present, this IE shall indicate the uplink and/or downlink maximum packet rate to be enforced for packets matching the PDR.This IE may be set to the value of: - downlink packet rate for Serving PLMN Rate Control, for a QER that is referenced by all PDRs of the UE belonging to the PDN connection using CIoT EPS Optimizations as described in 3GPPTS23.401[2])- uplink and/or downlink packet rate for APN Rate Control, for a QER that is referenced by all the PDRs of the UE belonging to PDN connections to the same APN using CIoT EPS Optimizations as described in 3GPPTS23.401[2])."})
ies.append({ "ie_type" : "DL Flow Level Marking", "ie_value" : "DL Flow Level Marking", "presence" : "C", "instance" : "0", "comment" : "This IE shall be set if the UP function is required to mark the packets for QoS purposes: - by the TDF-C, for DL flow level marking for application indication (see subclause 5.4.5); - by the PGW-C, for setting the GTP-U Service Class Indicator extension header for service indication towards GERAN (see subclause 5.4.12)."})
ies.append({ "ie_type" : "QFI", "ie_value" : "QoS flow identifier", "presence" : "C", "instance" : "0", "comment" : "This IE shall be present if the QoS flow identifier shall be included by the UPF."})
ies.append({ "ie_type" : "RQI", "ie_value" : "Reflective QoS", "presence" : "C", "instance" : "0", "comment" : "This IE shall be present if the UP function is required to set Reflective QoS Identifier to request reflective QoS for uplink traffic."})
group_list["Create QER"] = { "type" : "7", "ies" : ies }
ies = []
ies.append({ "ie_type" : "BAR ID", "ie_value" : "BAR ID", "presence" : "M", "instance" : "0", "comment" : "This IE shall uniquely identify the BAR provisioned for that PFCP session."})
ies.append({ "ie_type" : "Downlink Data Notification Delay", "ie_value" : "Downlink Data Notification Delay", "presence" : "C", "instance" : "0", "comment" : "This IE shall be present if the UP function indicated support of the Downlink Data Notification Delay parameter (see subclause 8.2.28) and the UP function has to delay the notification to the CP function about the arrival of DL data packets. When present, it shall contain the delay the UP function shall apply between receiving a downlink data packet and notifying the CP function about it, when the Apply Action parameter requests to buffer the packets and notify the CP function."})
group_list["Create BAR"] = { "type" : "85", "ies" : ies }
ies = []
ies.append({ "ie_type" : "Packet Detection Rule ID", "ie_value" : "PDR ID", "presence" : "M", "instance" : "0", "comment" : ""})
ies.append({ "ie_type" : "F-TEID", "ie_value" : "Local F-TEID", "presence" : "C", "instance" : "0", "comment" : "If the UP function allocates the F-TEID, this IE shall be present and shall contain the local F-TEID to be used for this PDR."})
group_list["Created PDR"] = { "type" : "8", "ies" : ies }
ies = []
ies.append({ "ie_type" : "Sequence Number", "ie_value" : "Load Control Sequence Number", "presence" : "M", "instance" : "0", "comment" : "See subclause 6.2.3.3.2 for the description and use of this parameter."})
ies.append({ "ie_type" : "Metricp", "ie_value" : "Load Metric", "presence" : "M", "instance" : "0", "comment" : "See subclause 6.2.3.3.2 for the description and use of this parameter."})
group_list["Load Control Informationp"] = { "type" : "51", "ies" : ies }
ies = []
ies.append({ "ie_type" : "Sequence Number", "ie_value" : "Overload Control Sequence Number", "presence" : "M", "instance" : "0", "comment" : "See subclause 6.2.4.3.2 for the description and use of this parameter."})
ies.append({ "ie_type" : "Metricp", "ie_value" : "Overload Reduction Metric", "presence" : "M", "instance" : "0", "comment" : "See subclause 6.2.4.3.2 for the description and use of this parameter."})
ies.append({ "ie_type" : "Timer", "ie_value" : "Period of Validity", "presence" : "M", "instance" : "0", "comment" : "See subclause 6.2.4.3.2 for the description and use of this parameter."})
ies.append({ "ie_type" : "OCI Flags", "ie_value" : "Overload Control Information Flags", "presence" : "C", "instance" : "0", "comment" : "This IE shall be included if any of flag in this IE is set. "})
group_list["Overload Control Informationp"] = { "type" : "54", "ies" : ies }
ies = []
ies.append({ "ie_type" : "Packet Detection Rule ID", "ie_value" : "PDR ID", "presence" : "M", "instance" : "0", "comment" : "This IE shall uniquely identify the PDR among all the PDRs configured for that PFCP session."})
ies.append({ "ie_type" : "Outer Header Removal", "ie_value" : "Outer Header Removal", "presence" : "C", "instance" : "0", "comment" : "This IE shall be present if it needs to be changed."})
ies.append({ "ie_type" : "Precedence", "ie_value" : "Precedence", "presence" : "C", "instance" : "0", "comment" : "This IE shall be present if there is a change in the PDRs precedence to be applied by the UP function among all PDRs of the PFCP session, when looking for a PDR matching an incoming packet."})
ies.append({ "ie_type" : "PDI", "ie_value" : "PDI", "presence" : "C", "instance" : "0", "comment" : "This IE shall be present if there is a change within the PDI against which incoming packets will be matched. When present, this IE shall replace the PDI previously stored in the UP function for this PDR. See Table 7.5.2.2-2."})
ies.append({ "ie_type" : "FAR ID", "ie_value" : "FAR ID", "presence" : "C", "instance" : "0", "comment" : "This IE shall be present if it needs to be changed"})
ies.append({ "ie_type" : "URR ID", "ie_value" : "URR ID", "presence" : "C", "instance" : "0", "comment" : "This IE shall be present if a measurement action shall be applied or no longer applied to packets matching this PDR.When present, this IE shall contain the list of all the URR IDs to be associated to the PDR."})
ies.append({ "ie_type" : "QER ID", "ie_value" : "QER ID", "presence" : "C", "instance" : "0", "comment" : "This IE shall be present if a QoS enforcement action shall be applied or no longer applied to packets matching this PDR.When present, this IE shall contain the list of all the QER IDs to be associated to the PDR."})
ies.append({ "ie_type" : "Activate Predefined Rules", "ie_value" : "Activate Predefined Rules", "presence" : "C", "instance" : "0", "comment" : "This IE shall be present if new Predefined Rule(s) needs to be activated for the PDR. When present this IE shall contain one Predefined Rules name.Several IEs with the same IE type may be present to represent multiple Activate Predefined Rules names."})
ies.append({ "ie_type" : "Deactivate Predefined Rules", "ie_value" : "Deactivate Predefined Rules", "presence" : "C", "instance" : "0", "comment" : "This IE shall be present if Predefined Rule(s) needs to be deactivated for the PDR. When present this IE shall contain one Predefined Rules name.Several IEs with the same IE type may be present to represent multiple Activate Predefined Rules names."})
group_list["Update PDR"] = { "type" : "9", "ies" : ies }
ies = []
ies.append({ "ie_type" : "FAR ID", "ie_value" : "FAR ID", "presence" : "M", "instance" : "0", "comment" : "This IE shall identify the FAR to be updated."})
ies.append({ "ie_type" : "Apply Action", "ie_value" : "Apply Action", "presence" : "C", "instance" : "0", "comment" : "This IE shall be present if it is changed."})
ies.append({ "ie_type" : "Update Forwarding Parameters", "ie_value" : "Update Forwarding parameters", "presence" : "C", "instance" : "0", "comment" : "This IE shall be present if it is changed.See table 7.5.4.3-2."})
ies.append({ "ie_type" : "Update Duplicating Parameters", "ie_value" : "Update Duplicating Parameters", "presence" : "C", "instance" : "0", "comment" : "This IE shall be present if it is changed. See table 7.5.4.3-3."})
ies.append({ "ie_type" : "BAR ID", "ie_value" : "BAR ID", "presence" : "C", "instance" : "0", "comment" : "This IE shall be present if the BAR ID associated to the FAR needs to be modified. See Table 7.5.4.11-1."})
group_list["Update FAR"] = { "type" : "10", "ies" : ies }
ies = []
ies.append({ "ie_type" : "Destination Interface", "ie_value" : "Destination Interface", "presence" : "C", "instance" : "0", "comment" : "This IE shall only be provided if it is changed. When present, it shall indicate the destination interface of the outgoing packet."})
ies.append({ "ie_type" : "Network Instance", "ie_value" : "Network instance", "presence" : "C", "instance" : "0", "comment" : "This IE shall only be provided if it is changed."})
ies.append({ "ie_type" : "Redirect Information", "ie_value" : "Redirect Information", "presence" : "C", "instance" : "0", "comment" : "This IE shall be present if the instructions regarding the redirection of traffic by the UP function need to be modified."})
ies.append({ "ie_type" : "Outer Header Creation", "ie_value" : "Outer Header Creation", "presence" : "C", "instance" : "0", "comment" : "This IE shall only be provided if it is changed"})
ies.append({ "ie_type" : "Transport Level Marking", "ie_value" : "Transport Level Marking", "presence" : "C", "instance" : "0", "comment" : "This IE shall only be provided if it is changed"})
ies.append({ "ie_type" : "Forwarding Policy", "ie_value" : "Forwarding Policy", "presence" : "C", "instance" : "0", "comment" : "This IE shall only be provided if it is changed"})
ies.append({ "ie_type" : "Header Enrichment", "ie_value" : "Header Enrichment", "presence" : "C", "instance" : "0", "comment" : "This IE shall only be provided if it is changed"})
ies.append({ "ie_type" : "PFCPSMReq-Flags", "ie_value" : "SxSMReq-Flags", "presence" : "C", "instance" : "0", "comment" : "This IE shall be included if at least one of the flags is set to 1. - SNDEM (Send End Marker Packets): this IE shall be present if the CP function modifies the F-TEID of the downstream node in the Outer Header Creation IE and the CP function requests the UP function to construct and send GTP-U End Marker messages towards the old F-TEID of the downstream node. "})
group_list["Update Forwarding Parameters"] = { "type" : "11", "ies" : ies }
ies = []
ies.append({ "ie_type" : "Destination Interface", "ie_value" : "Destination Interface", "presence" : "C", "instance" : "0", "comment" : "This IE shall only be provided if it is changed. When present, it shall indicate the destination interface of the outgoing packet."})
ies.append({ "ie_type" : "Outer Header Creation", "ie_value" : "Outer Header Creation", "presence" : "C", "instance" : "0", "comment" : "This IE shall only be provided if it is changed."})
ies.append({ "ie_type" : "Transport Level Marking", "ie_value" : "Transport Level Marking", "presence" : "C", "instance" : "0", "comment" : "This IE shall only be provided if it is changed."})
ies.append({ "ie_type" : "Forwarding Policy", "ie_value" : "Forwarding Policy", "presence" : "C", "instance" : "0", "comment" : "This IE shall only be provided if it is changed."})
group_list["Update Duplicating Parameters"] = { "type" : "105", "ies" : ies }
ies = []
ies.append({ "ie_type" : "URR ID", "ie_value" : "URR ID", "presence" : "M", "instance" : "0", "comment" : "This IE shall uniquely identify the URR among all the URRs configured for that PFCP session"})
ies.append({ "ie_type" : "Measurement Method", "ie_value" : "Measurement Method", "presence" : "C", "instance" : "0", "comment" : "This IE shall be present if the measurement method needs to be modified. When present, this IE shall indicate the method for measuring the network resources usage, i.e. whether the data volume, duration (i.e. time), combined volume/duration, or event shall be measured."})
ies.append({ "ie_type" : "Reporting Triggers", "ie_value" : "Reporting Triggers", "presence" : "C", "instance" : "0", "comment" : "This IE shall be present if the reporting triggers needs to be modified. When present, this IE shall indicate the trigger(s) for reporting network resources usage to the CP function, e.g. periodic reporting or reporting upon reaching a threshold, or envelope closure."})
ies.append({ "ie_type" : "Measurement Period", "ie_value" : "Measurement Period", "presence" : "C", "instance" : "0", "comment" : "This IE shall be present if the Measurement Period needs to be modified. When present, it shall indicate the period for generating and reporting usage reports. "})
ies.append({ "ie_type" : "Volume Threshold", "ie_value" : "Volume Threshold", "presence" : "C", "instance" : "0", "comment" : "This IE shall be present if the Volume Threshold needs to be modified. When present, it shall indicate the traffic volume value after which the UP function shall report network resources usage to the CP function for this URR."})
ies.append({ "ie_type" : "Volume Quota", "ie_value" : "Volume Quota", "presence" : "C", "instance" : "0", "comment" : "This IE shall be present if the Volume Quota needs to be modified. When present, it shall indicate the Volume Quota value."})
ies.append({ "ie_type" : "Time Threshold", "ie_value" : "Time Threshold", "presence" : "C", "instance" : "0", "comment" : "This IE shall be present if the Time Threshold needs to be modified. When present, it shall indicate the time usage after which the UP function shall report network resources usage to the CP function for this URR."})
ies.append({ "ie_type" : "Time Quota", "ie_value" : "Time Quota", "presence" : "C", "instance" : "0", "comment" : "This IE shall be present if the Time Quota needs to be modified. When present, it shall indicate the Time Quota value."})
ies.append({ "ie_type" : "Quota Holding Time", "ie_value" : "Quota Holding Time", "presence" : "C", "instance" : "0", "comment" : "This IE shall be present if the Quota Holding Time needs to be modified. When present, it shall contain the duration of the Quota Holding Time."})
ies.append({ "ie_type" : "Dropped DL Traffic Threshold", "ie_value" : "Dropped DL Traffic Threshold", "presence" : "C", "instance" : "0", "comment" : "This IE shall be present if the Dropped DL Threshold needs to be modified. When present, it shall contain the threshold of the DL traffic being dropped."})
ies.append({ "ie_type" : "Monitoring Time", "ie_value" : "Monitoring Time", "presence" : "C", "instance" : "0", "comment" : "This IE shall be present if the Monitoring Time needs to be modified. When present, this IE shall contain the time at which the UP function shall re-apply the volume or time threshold. "})
ies.append({ "ie_type" : "Subsequent Volume Threshold", "ie_value" : "Subsequent Volume Threshold", "presence" : "C", "instance" : "0", "comment" : "This IE shall be present if the Subsequent Volume Threshold needs to be modified and volume-based measurement is used. When present, it shall indicate the traffic volume value after which the UP function shall report network resources usage to the CP function for this URR for the period after the Monitoring Time."})
ies.append({ "ie_type" : "Subsequent Time Threshold", "ie_value" : "Subsequent Time Threshold", "presence" : "C", "instance" : "0", "comment" : "This IE shall be present if the Subsequent Time Threshold needs to be modified. When present, it shall indicate the time usage value after which the UP function shall report network resources usage to the CP function for this URR for the period after the Monitoring Time."})
ies.append({ "ie_type" : "Subsequent Volume Quota", "ie_value" : "Subsequent Volume Quota", "presence" : "C", "instance" : "0", "comment" : "This IE shall be present if the Subsequent Volume Quota needs to be modified. When present, it shall indicate the Volume Quota value which the UP function shall use for this URR for the period after the Monitoring Time."})
ies.append({ "ie_type" : "Subsequent Time Quota", "ie_value" : "Subsequent Time Quota", "presence" : "C", "instance" : "0", "comment" : "This IE shall be present if the Subsequent Time Quota needs to be modified. When present, it shall indicate the Time Quota value which the UP function shall use for this URR for the period after the Monitoring Time."})
ies.append({ "ie_type" : "Inactivity Detection Time", "ie_value" : "Inactivity Detection Time", "presence" : "C", "instance" : "0", "comment" : "This IE shall be present if the Inactivity Detection Time needs to be modified. When present, it shall indicate the duration of the inactivity period after which time measurement needs to be suspended when no packets are received during this inactivity period. "})
ies.append({ "ie_type" : "Linked URR ID", "ie_value" : "Linked URR ID", "presence" : "C", "instance" : "0", "comment" : "This IE shall be present if linked usage reporting is required. When present, this IE shall contain the linked URR ID which is related with this URR (see subclause 5.2.2.4). "})
ies.append({ "ie_type" : "Measurement Information", "ie_value" : "Measurement Information", "presence" : "C", "instance" : "0", "comment" : "This IE shall be included if any of the following flag is set to 1.Applicable flags are:- Inactive Measurement Flag: this flag shall be set to 1 if the measurement shall be paused (inactive). The measurement shall be performed (active) if the bit is set to 0 or if the Measurement Information IE is not present in the Update URR IE. - Reduced Application Detection Information Flag: this flag may be set to 1, if the Reporting Triggers request to report the start or stop of application, to request the UP function to only report the Application ID in the Application Detection Information, e.g. for envelope reporting."})
ies.append({ "ie_type" : "Time Quota Mechanism", "ie_value" : "Time Quota Mechanism", "presence" : "C", "instance" : "0", "comment" : "This IE shall be present if time-based measurement based on CTP or DTP needs to be modified."})
ies.append({ "ie_type" : "Aggregated URRs", "ie_value" : "Aggregated URRs", "presence" : "C", "instance" : "0", "comment" : "This IE shall be included if the Aggregated URRs IE needs to be modified. See Table 7.5.2.4-1.Several IEs with the same IE type may be present to provision multiple aggregated URRs.When present, this IE shall provide the complete list of the aggregated URRs."})
group_list["Update URR"] = { "type" : "13", "ies" : ies }
ies = []
ies.append({ "ie_type" : "QER ID", "ie_value" : "QER ID", "presence" : "M", "instance" : "0", "comment" : "This IE shall uniquely identify the QER among all the QRs configured for that PFCP session"})
ies.append({ "ie_type" : "QER Correlation ID", "ie_value" : "QER Correlation ID", "presence" : "C", "instance" : "0", "comment" : "This IE shall be present if the QER correlation ID in this QER needs to be modified.See NOTE 1."})
ies.append({ "ie_type" : "Gate Status", "ie_value" : "Gate Status", "presence" : "C", "instance" : "0", "comment" : "This IE shall be present if the Gate Status needs to be modified. When present, it shall indicate whether the packets are allowed to be forwarded (the gate is open) or shall be discarded (the gate is closed) in the uplink and/or downlink directions.See NOTE 1."})
ies.append({ "ie_type" : "MBR", "ie_value" : "Maximum Bitrate", "presence" : "C", "instance" : "0", "comment" : "This IE shall be present if an MBR enforcement action applied to packets matching this PDR need to be modified. When present, this IE shall indicate the uplink and/or downlink maximum bit rate to be enforced for packets matching the PDR.This IE may be set to the value of: - the APN-AMBR, for a QER that is referenced by all the PDRs of the non-GBR bearers of a PDN connection; - the TDF session MBR, for a QER that is referenced by all the PDRs of a TDF session;- the bearer MBR, for a QER that is referenced by all the PDRs of a bearer;- the SDF MBR, for a QER that is referenced by all the PDRs of a SDF.See NOTE 1."})
ies.append({ "ie_type" : "GBR", "ie_value" : "Guaranteed Bitrate", "presence" : "C", "instance" : "0", "comment" : "This IE shall be present if a GBR authorization to packets matching this PDR needs to be modified. When present, this IE shall indicate the authorized uplink and/or downlink guaranteed bit rate.This IE may be set to the value of: - the aggregate GBR, for a QER that is referenced by all the PDRs of a GBR bearer;- the SDF GBR, for a QER that is referenced by all the PDRs of a SDF.See NOTE 1."})
ies.append({ "ie_type" : "Packet Rate", "ie_value" : "Packet Rate", "presence" : "C", "instance" : "0", "comment" : "This IE shall be present if a Packet Rate enforcement action (in terms of number of packets per time interval) need to be modified for packets matching this PDR. "})
ies.append({ "ie_type" : "DL Flow Level Marking", "ie_value" : "DL Flow Level Marking", "presence" : "C", "instance" : "0", "comment" : "This IE shall be set if the DL Flow Level Marking IE needs to be modified.See NOTE 1."})
ies.append({ "ie_type" : "QFI", "ie_value" : "QoS flow identifier", "presence" : "C", "instance" : "0", "comment" : "This IE shall be present if it needs to be modified."})
ies.append({ "ie_type" : "RQI", "ie_value" : "Reflective QoS", "presence" : "C", "instance" : "0", "comment" : "This IE shall be present if it needs to be modified."})
group_list["Update QER"] = { "type" : "14", "ies" : ies }
ies = []
ies.append({ "ie_type" : "Packet Detection Rule ID", "ie_value" : "PDR ID", "presence" : "M", "instance" : "0", "comment" : "This IE shall identify the PDR to be deleted."})
group_list["Remove PDR"] = { "type" : "15", "ies" : ies }
ies = []
ies.append({ "ie_type" : "FAR ID", "ie_value" : "FAR ID", "presence" : "M", "instance" : "0", "comment" : "This IE shall identify the FAR to be deleted."})
group_list["Remove FAR"] = { "type" : "16", "ies" : ies }
ies = []
ies.append({ "ie_type" : "URR ID", "ie_value" : "URR ID", "presence" : "M", "instance" : "0", "comment" : "This IE shall identify the URR to be deleted."})
group_list["Remove URR"] = { "type" : "17", "ies" : ies }
ies = []
ies.append({ "ie_type" : "QER ID", "ie_value" : "QER ID", "presence" : "M", "instance" : "0", "comment" : "This IE shall identify the QER to be deleted."})
group_list["Remove QER"] = { "type" : "18", "ies" : ies }
ies = []
ies.append({ "ie_type" : "URR ID", "ie_value" : "URR ID", "presence" : "M", "instance" : "0", "comment" : "This IE shall identify the URR being queried."})
group_list["Query URR"] = { "type" : "77", "ies" : ies }
ies = []
ies.append({ "ie_type" : "BAR ID", "ie_value" : "BAR ID", "presence" : "M", "instance" : "0", "comment" : "This IE shall identify the BAR Rule to be modified."})
ies.append({ "ie_type" : "Downlink Data Notification Delay", "ie_value" : "Downlink Data Notification Delay", "presence" : "C", "instance" : "0", "comment" : "This IE shall be present if the UP function indicated support of the Downlink Data Notification Delay parameter (see subclause 8.2.28) and the Downlink Data Notification Delay needs to be modified.When present, it shall contain the delay the UP function shall apply between receiving a downlink data packet and notifying the CP function about it, when the Apply Action parameter requests to buffer the packets and notify the CP function."})
group_list["Update BAR Session Modification Request"] = { "type" : "86", "ies" : ies }
ies = []
ies.append({ "ie_type" : "BAR ID", "ie_value" : "BAR ID", "presence" : "M", "instance" : "0", "comment" : "This IE shall identify the BAR to be deleted."})
group_list["Remove BAR"] = { "type" : "87", "ies" : ies }
ies = []
ies.append({ "ie_type" : "URR ID", "ie_value" : "URR ID", "presence" : "M", "instance" : "0", "comment" : "This IE shall identify the URR for which usage is reported."})
ies.append({ "ie_type" : "UR-SEQN", "ie_value" : "UR-SEQN", "presence" : "M", "instance" : "0", "comment" : "This IE shall uniquely identify the Usage Report for the URR (see subclause 5.2.2.3)."})
ies.append({ "ie_type" : "Usage Report Trigger", "ie_value" : "Usage Report Trigger", "presence" : "M", "instance" : "0", "comment" : "This IE shall identify the trigger for this report."})
ies.append({ "ie_type" : "Start Time", "ie_value" : "Start Time", "presence" : "C", "instance" : "0", "comment" : "This IE shall be present, except if the Usage Report Trigger indicates Start of Traffic or Stop of Traffic.When present, this IE shall provide the timestamp when the collection of the information in this report was started."})
ies.append({ "ie_type" : "End Time", "ie_value" : "End Time", "presence" : "C", "instance" : "0", "comment" : "This IE shall be present, except if the Usage Report Trigger indicates Start of Traffic or Stop of Traffic.When present, this IE shall provide the timestamp when the collection of the information in this report was generated."})
ies.append({ "ie_type" : "Volume Measurement", "ie_value" : "Volume Measurement", "presence" : "C", "instance" : "0", "comment" : "This IE shall be present if a volume measurement needs to be reported."})
ies.append({ "ie_type" : "Duration Measurement", "ie_value" : "Duration Measurement", "presence" : "C", "instance" : "0", "comment" : "This IE shall be present if a duration measurement needs to be reported."})
ies.append({ "ie_type" : "Time of First Packet", "ie_value" : "Time of First Packet", "presence" : "C", "instance" : "0", "comment" : "This IE shall be present if available for this URR."})
ies.append({ "ie_type" : "Time of Last Packet", "ie_value" : "Time of Last Packet", "presence" : "C", "instance" : "0", "comment" : "This IE shall be present if available for this URR."})
ies.append({ "ie_type" : "Usage Information", "ie_value" : "Usage Information", "presence" : "C", "instance" : "0", "comment" : "This IE shall be present if the UP function reports Usage Reports before and after a Monitoring Time or before and after QoS enforcement. When present, it shall indicate whether the usage is reported for the period before or after that time, or before or after QoS enforcement."})
group_list["Usage Report in Session Modification Response"] = { "type" : "78", "ies" : ies }
ies = []
ies.append({ "ie_type" : "URR ID", "ie_value" : "URR ID", "presence" : "M", "instance" : "0", "comment" : "This IE shall identify the URR for which usage is reported."})
ies.append({ "ie_type" : "UR-SEQN", "ie_value" : "UR-SEQN", "presence" : "M", "instance" : "0", "comment" : "This IE shall uniquely identify the Usage Report for the URR (see subclause 5.2.2.3)."})
ies.append({ "ie_type" : "Usage Report Trigger", "ie_value" : "Usage Report Trigger", "presence" : "M", "instance" : "0", "comment" : "This IE shall identify the trigger for this report."})
ies.append({ "ie_type" : "Start Time", "ie_value" : "Start Time", "presence" : "C", "instance" : "0", "comment" : "This IE shall be present, except if the Usage Report Trigger indicates Start of Traffic or Stop of Traffic.When present, this IE shall provide the timestamp when the collection of the information in this report was started."})
ies.append({ "ie_type" : "End Time", "ie_value" : "End Time", "presence" : "C", "instance" : "0", "comment" : "This IE shall be present, except if the Usage Report Trigger indicates Start of Traffic or Stop of Traffic.When present, this IE shall provide the timestamp when the collection of the information in this report was generated."})
ies.append({ "ie_type" : "Volume Measurement", "ie_value" : "Volume Measurement", "presence" : "C", "instance" : "0", "comment" : "This IE shall be present if a volume needs to be reported."})
ies.append({ "ie_type" : "Duration Measurement", "ie_value" : "Duration Measurement", "presence" : "C", "instance" : "0", "comment" : "This IE shall be present if a duration measurement needs to be reported."})
ies.append({ "ie_type" : "Time of First Packet", "ie_value" : "Time of First Packet", "presence" : "C", "instance" : "0", "comment" : "This IE shall be present if available for this URR."})
ies.append({ "ie_type" : "Time of Last Packet", "ie_value" : "Time of Last Packet", "presence" : "C", "instance" : "0", "comment" : "This IE shall be present if available for this URR."})
ies.append({ "ie_type" : "Usage Information", "ie_value" : "Usage Information", "presence" : "C", "instance" : "0", "comment" : "This IE shall be present if the UP function reports Usage Reports before and after a Monitoring Time, or before and after QoS enforcement. When present, it shall indicate whether the usage is reported for the period before or after that time, or before or after QoS enforcement."})
group_list["Usage Report Session Deletion Response"] = { "type" : "79", "ies" : ies }
ies = []
ies.append({ "ie_type" : "Packet Detection Rule ID", "ie_value" : "PDR ID", "presence" : "M", "instance" : "0", "comment" : "This IE shall identify the PDR for which downlink data packets have been received at the UP function. More than one IE with this type may be included to represent multiple PDRs having received downlink data packets."})
ies.append({ "ie_type" : "Downlink Data Service Information", "ie_value" : "Downlink Data Service Information", "presence" : "C", "instance" : "0", "comment" : "This IE shall be included for an PFCP session with an IP PDN type, if the UP function supports the Paging Policy Differentiation feature (see subclause 4.9 of 3GPPTS23.401[14]). When present, for each PDR and for each packet that triggers a Downlink Data Notification, the UP function shall copy, into the Paging Policy Indication value within this IE, the value of the DSCP in TOS (IPv4) or TC (IPv6) information received in the IP payload of the GTP-U packet from the PGW (see IETFRFC2474[13]).One IE with this type shall be included per PDR ID reported in the message. When multiple PDR ID IEs are present in the message, the Downlink Data Service Information IEs shall be reported according to the order of the PDR ID IEs."})
group_list["Downlink Data Report"] = { "type" : "83", "ies" : ies }
ies = []
ies.append({ "ie_type" : "URR ID", "ie_value" : "URR ID", "presence" : "M", "instance" : "0", "comment" : "This IE shall identify the URR for which usage is reported."})
ies.append({ "ie_type" : "UR-SEQN", "ie_value" : "UR-SEQN", "presence" : "M", "instance" : "0", "comment" : "This IE shall uniquely identify the Usage Report for the URR (see subclause 5.2.2.3)."})
ies.append({ "ie_type" : "Usage Report Trigger", "ie_value" : "Usage Report Trigger", "presence" : "M", "instance" : "0", "comment" : "This IE shall identify the trigger for this report."})
ies.append({ "ie_type" : "Start Time", "ie_value" : "Start Time", "presence" : "C", "instance" : "0", "comment" : "This IE shall be present, except if the Usage Report Trigger indicates Start of Traffic or Stop of Traffic.When present, this IE shall provide the timestamp when the collection of the information in this report was started."})
ies.append({ "ie_type" : "End Time", "ie_value" : "End Time", "presence" : "C", "instance" : "0", "comment" : "This IE shall be present, except if the Usage Report Trigger indicates Start of Traffic or Stop of Traffic.When present, this IE shall provide the timestamp when the collection of the information in this report was generated."})
ies.append({ "ie_type" : "Volume Measurement", "ie_value" : "Volume Measurement", "presence" : "C", "instance" : "0", "comment" : "This IE shall be present if a volume measurement needs to be reported."})
ies.append({ "ie_type" : "Duration Measurement", "ie_value" : "Duration Measurement", "presence" : "C", "instance" : "0", "comment" : "This IE shall be present if a duration measurement needs to be reported."})
ies.append({ "ie_type" : "Application Detection Information", "ie_value" : "Application Detection Information", "presence" : "C", "instance" : "0", "comment" : "This IE shall be present if application detection information needs to be reported."})
ies.append({ "ie_type" : "UE IP Address", "ie_value" : "UE IP address", "presence" : "C", "instance" : "0", "comment" : "This IE shall be present if the start or stop of an application has been detected and no UE IP address was provisioned in the PDI. See NOTE 1."})
ies.append({ "ie_type" : "Network Instance", "ie_value" : "Network Instance", "presence" : "C", "instance" : "0", "comment" : "This IE shall be present if the start or stop of an application has been detected, no UE IP address was provisioned in the PDI and multiple PDNs with overlapping IP addresses are used in the UP function. See NOTE 1."})
ies.append({ "ie_type" : "Time of First Packet", "ie_value" : "Time of First Packet", "presence" : "C", "instance" : "0", "comment" : "This IE shall be present if available for this URR."})
ies.append({ "ie_type" : "Time of Last Packet", "ie_value" : "Time of Last Packet", "presence" : "C", "instance" : "0", "comment" : "This IE shall be present if available for this URR."})
ies.append({ "ie_type" : "Usage Information", "ie_value" : "Usage Information", "presence" : "C", "instance" : "0", "comment" : "This IE shall be present if the UP function reports Usage Reports before and after a Monitoring Time, or before and after QoS enforcement. When present, it shall indicate whether the usage is reported for the period before or after that time, or before or after QoS enforcement."})
group_list["Usage Report Session Report Request"] = { "type" : "80", "ies" : ies }
ies = []
ies.append({ "ie_type" : "Application ID", "ie_value" : "Application ID", "presence" : "M", "instance" : "0", "comment" : "This IE shall identify the Application ID for which a start or stop of traffic is reported."})
ies.append({ "ie_type" : "Application Instance ID", "ie_value" : "Application Instance ID", "presence" : "C", "instance" : "0", "comment" : "When present, this IE shall identify the Application Instance Identifier for which a start or stop of traffic is reported. It shall be present, when reporting the start of an application, if the Reduced Application Detection Information flag was not set in the Measurement Information and if the flow information for the detected application is deducible. It shall be present, when reporting the stop of an application, if the Reduced Application Detection Information flag was not set in the Measurement Information and if it was provided when reporting the start of the application."})
ies.append({ "ie_type" : "Flow Information", "ie_value" : "Flow Information", "presence" : "C", "instance" : "0", "comment" : "When present, this IE shall contain the flow information for the detected application. It shall be present, when reporting the start of an application, if the Reduced Application Detection Information flag was not set in the Measurement Information and if the flow information for the detected application is deducible."})
group_list["Application Detection Information"] = { "type" : "68", "ies" : ies }
ies = []
ies.append({ "ie_type" : "F-TEID", "ie_value" : "Remote F-TEID", "presence" : "M", "instance" : "0", "comment" : "This IE shall identify the remote F-TEID of the GTP-U bearer for which an Error Indication has been received at the UP function. More than one IE with this type may be included to represent multiple remote F-TEID for which an Error Indication has been received."})
group_list["Error Indication Report"] = { "type" : "99", "ies" : ies }
ies = []
ies.append({ "ie_type" : "BAR ID", "ie_value" : "BAR ID", "presence" : "M", "instance" : "0", "comment" : "This IE shall identify the BAR Rule to be modified."})
ies.append({ "ie_type" : "Downlink Data Notification Delay", "ie_value" : "Downlink Data Notification Delay", "presence" : "C", "instance" : "0", "comment" : "This IE shall be present if the UP function indicated support of the Downlink Data Notification Delay parameter (see subclause 8.2.25) and the Downlink Data Notification Delay needs to be modified.When present, it shall contain the delay the UP function shall apply between receiving a downlink data packet and notifying the CP function about it, when the Apply Action parameter requests to buffer the packets and notify the CP function."})
ies.append({ "ie_type" : "DL Buffering Duration", "ie_value" : "DL Buffering Duration", "presence" : "C", "instance" : "0", "comment" : "This IE shall be present if the UP function indicated support of the DL Buffering Duration parameter (see subclause 8.2.25) and extended buffering of downlink data packet is required in the UP function. When present, this IE shall indicate the duration during which the UP function shall buffer the downlink data packets without sending any further notification to the CP function about the arrival of DL data packets."})
ies.append({ "ie_type" : "DL Buffering Suggested Packet Count", "ie_value" : "DL Buffering Suggested Packet Count", "presence" : "O", "instance" : "0", "comment" : "This IE may be present if extended buffering of downlink data packet is required in the UP function. When present, this IE shall indicate the maximum number of downlink data packets suggested to be buffered in the UP function."})
group_list["Update BAR PFCP Session Report Response"] = { "type" : "12", "ies" : ies }

3
lib/pfcp/support/cache/tlv-msg-1.py vendored Normal file
View File

@ -0,0 +1,3 @@
ies = []
ies.append({ "ie_type" : "Recovery Time Stamp", "ie_value" : "Recovery Time Stamp", "presence" : "M", "instance" : "0", "comment" : "This IE shall contain the time stamp when the node was started see clause 19A of 3GPPTS23.007[24]."})
msg_list[key]["ies"] = ies

4
lib/pfcp/support/cache/tlv-msg-10.py vendored Normal file
View File

@ -0,0 +1,4 @@
ies = []
ies.append({ "ie_type" : "Node ID", "ie_value" : "Node ID", "presence" : "M", "instance" : "0", "comment" : "This IE shall contain the unique identifier of the sending Node."})
ies.append({ "ie_type" : "Cause", "ie_value" : "Cause", "presence" : "M", "instance" : "0", "comment" : "This IE shall indicate the acceptance or the rejection of the corresponding request message."})
msg_list[key]["ies"] = ies

4
lib/pfcp/support/cache/tlv-msg-11.py vendored Normal file
View File

@ -0,0 +1,4 @@
ies = []
ies.append({ "ie_type" : "Cause", "ie_value" : "Cause", "presence" : "M", "instance" : "0", "comment" : "This IE shall indicate the acceptance or the rejection of the corresponding request message."})
ies.append({ "ie_type" : "Offending IE", "ie_value" : "Offending IE", "presence" : "C", "instance" : "0", "comment" : "This IE shall be included if the rejection is due to an conditional or mandatory IE missing or faulty."})
msg_list[key]["ies"] = ies

5
lib/pfcp/support/cache/tlv-msg-12.py vendored Normal file
View File

@ -0,0 +1,5 @@
ies = []
ies.append({ "ie_type" : "Node ID", "ie_value" : "Node ID", "presence" : "M", "instance" : "0", "comment" : "This IE shall contain the unique identifier of the sending Node."})
ies.append({ "ie_type" : "Node Report Type", "ie_value" : "Node Report Type", "presence" : "M", "instance" : "0", "comment" : "This IE shall indicate the type of the report."})
ies.append({ "ie_type" : "User Plane Path Failure Report", "ie_value" : "User Plane Path Failure Report", "presence" : "C", "instance" : "0", "comment" : "This IE shall be present if the Node Report Type indicates a User Plane Path Failure Report."})
msg_list[key]["ies"] = ies

5
lib/pfcp/support/cache/tlv-msg-13.py vendored Normal file
View File

@ -0,0 +1,5 @@
ies = []
ies.append({ "ie_type" : "Node ID", "ie_value" : "Node ID", "presence" : "M", "instance" : "0", "comment" : "This IE shall contain the unique identifier of the sending Node."})
ies.append({ "ie_type" : "Cause", "ie_value" : "Cause", "presence" : "M", "instance" : "0", "comment" : "This IE shall indicate the acceptance or the rejection of the corresponding request message."})
ies.append({ "ie_type" : "Offending IE", "ie_value" : "Offending IE", "presence" : "C", "instance" : "0", "comment" : "This IE shall be included if the rejection cause is due to a conditional or mandatory IE missing or faulty."})
msg_list[key]["ies"] = ies

4
lib/pfcp/support/cache/tlv-msg-14.py vendored Normal file
View File

@ -0,0 +1,4 @@
ies = []
ies.append({ "ie_type" : "Node ID", "ie_value" : "Node ID", "presence" : "M", "instance" : "0", "comment" : "This IE shall contain the node identity of the originating node of the message."})
ies.append({ "ie_type" : "FQ-CSIDp", "ie_value" : "SGW-C FQ-CSID", "presence" : "C", "instance" : "0", "comment" : "This IE shall be included according to the requirements in clause 23 of 3GPP TS 23.007 [24]."})
msg_list[key]["ies"] = ies

5
lib/pfcp/support/cache/tlv-msg-15.py vendored Normal file
View File

@ -0,0 +1,5 @@
ies = []
ies.append({ "ie_type" : "Node ID", "ie_value" : "Node ID", "presence" : "M", "instance" : "0", "comment" : "This IE shall contain the unique identifier of the sending node."})
ies.append({ "ie_type" : "Cause", "ie_value" : "Cause", "presence" : "M", "instance" : "0", "comment" : "This IE shall indicate the acceptance or the rejection of the corresponding request message."})
ies.append({ "ie_type" : "Offending IE", "ie_value" : "Offending IE", "presence" : "C", "instance" : "0", "comment" : "This IE shall be included if the rejection is due to an conditional or mandatory IE missing or faulty."})
msg_list[key]["ies"] = ies

3
lib/pfcp/support/cache/tlv-msg-2.py vendored Normal file
View File

@ -0,0 +1,3 @@
ies = []
ies.append({ "ie_type" : "Recovery Time Stamp", "ie_value" : "Recovery Time Stamp", "presence" : "M", "instance" : "0", "comment" : "This IE shall contain the time stamp when the node was started see clause 19A of 3GPPTS23.007[24]."})
msg_list[key]["ies"] = ies

7
lib/pfcp/support/cache/tlv-msg-5.py vendored Normal file
View File

@ -0,0 +1,7 @@
ies = []
ies.append({ "ie_type" : "Node ID", "ie_value" : "Node ID", "presence" : "M", "instance" : "0", "comment" : "This IE shall contain the unique identifier of the sending Node."})
ies.append({ "ie_type" : "Recovery Time Stamp", "ie_value" : "Recovery Time Stamp", "presence" : "M", "instance" : "0", "comment" : "This IE shall contain the time stamp when the node was started, see clause 19A of 3GPPTS23.007[24]."})
ies.append({ "ie_type" : "UP Function Features", "ie_value" : "UP Function Features", "presence" : "C", "instance" : "0", "comment" : "This IE shall be present if the UP function sends this message and the UP function supports at least one UP feature defined in this IE. When present, this IE shall indicate the features the UP function supports."})
ies.append({ "ie_type" : "CP Function Features", "ie_value" : "CP Function Features", "presence" : "C", "instance" : "0", "comment" : "This IE shall be present if the CP function sends this message and the CP function supports at least one CP feature defined in this IE. When present, this IE shall indicate the features the CP function supports."})
ies.append({ "ie_type" : "User Plane IP Resource Information", "ie_value" : "User Plane IP Resource Information", "presence" : "O", "instance" : "0", "comment" : "This IE may be present if the UP function sends this message.When present, this IE shall contain an IPv4 and/or an IPv6 address, together with a TEID range that the CP function shall use to allocate GTP-U F-TEID in the UP function. Several IEs with the same IE type may be present to represent multiple User Plane IP Resources."})
msg_list[key]["ies"] = ies

14
lib/pfcp/support/cache/tlv-msg-50.py vendored Normal file
View File

@ -0,0 +1,14 @@
ies = []
ies.append({ "ie_type" : "Node ID", "ie_value" : "Node ID", "presence" : "M", "instance" : "0", "comment" : "This IE shall contain the unique identifier of the sending Node."})
ies.append({ "ie_type" : "F-SEID", "ie_value" : "CP F-SEID", "presence" : "M", "instance" : "0", "comment" : "This IE shall contain the unique identifier allocated by the CP function identifying the session."})
ies.append({ "ie_type" : "Create PDR", "ie_value" : "Create PDR", "presence" : "O", "instance" : "0", "comment" : "This IE shall be present for at least one PDR to be associated to the PFCP session.Several IEs with the same IE type may be present to represent multiple PDRs.See Table 7.5.2.2-1."})
ies.append({ "ie_type" : "Create PDR", "ie_value" : "Create PDR", "presence" : "M", "instance" : "1", "comment" : "This IE shall be present for at least one PDR to be associated to the PFCP session.Several IEs with the same IE type may be present to represent multiple PDRs.See Table 7.5.2.2-1."})
ies.append({ "ie_type" : "Create FAR", "ie_value" : "Create FAR", "presence" : "O", "instance" : "0", "comment" : "This IE shall be present for at least one FAR to be associated to the PFCP session.Several IEs with the same IE type may be present to represent multiple FARs.See Table 7.5.2.3-1."})
ies.append({ "ie_type" : "Create FAR", "ie_value" : "Create FAR", "presence" : "M", "instance" : "1", "comment" : "This IE shall be present for at least one FAR to be associated to the PFCP session.Several IEs with the same IE type may be present to represent multiple FARs.See Table 7.5.2.3-1."})
ies.append({ "ie_type" : "Create URR", "ie_value" : "Create URR", "presence" : "C", "instance" : "0", "comment" : "This IE shall be present if a measurement action shall be applied to packets matching one or more PDR(s) of this PFCP session. Several IEs within the same IE type may be present to represent multiple URRs.See Table 7.5.2.4-1."})
ies.append({ "ie_type" : "Create QER", "ie_value" : "Create QER", "presence" : "C", "instance" : "0", "comment" : "This IE shall be present if a QoS enforcement action shall be applied to packets matching one or more PDR(s) of this PFCP session.Several IEs within the same IE type may be present to represent multiple QERs.See Table 7.5.2.5-1."})
ies.append({ "ie_type" : "Create BAR", "ie_value" : "Create BAR", "presence" : "O", "instance" : "0", "comment" : "When present, this IE shall contain the buffering instructions to be applied by the UP function to any FAR of this PFCP session set with the Apply Action requesting the packets to be buffered and with a BAR ID IE referring to this BAR. See table 7.5.2.6-1."})
ies.append({ "ie_type" : "PDN Typep", "ie_value" : "PDN Type", "presence" : "C", "instance" : "0", "comment" : "This IE shall be present if the PFCP session is setup for an individual PDN connection or PDU session (see subclause 5.2.1). When present, this IE shall indicate whether this is an IP or non-IP PDN connection/PDU session. "})
ies.append({ "ie_type" : "FQ-CSIDp", "ie_value" : "SGW-C FQ-CSID", "presence" : "C", "instance" : "0", "comment" : "This IE shall be included according to the requirements in clause23 of 3GPPTS 23.007[24]."})
ies.append({ "ie_type" : "User Plane Inactivity Timer", "ie_value" : "User Plane Inactivity Timer", "presence" : "O", "instance" : "0", "comment" : "This IE may be present to request the UP function to send a User Plane Inactivity Report when no user plane packets are received for this PFCP session for a duration exceeding the User Plane Inactivity Timer. When present, it shall contain the duration of the inactivity period after which a User Plane Inactivity Report shall be generated."})
msg_list[key]["ies"] = ies

11
lib/pfcp/support/cache/tlv-msg-51.py vendored Normal file
View File

@ -0,0 +1,11 @@
ies = []
ies.append({ "ie_type" : "Node ID", "ie_value" : "Node ID", "presence" : "M", "instance" : "0", "comment" : "This IE shall contain the unique identifier of the sending Node."})
ies.append({ "ie_type" : "Cause", "ie_value" : "Cause", "presence" : "M", "instance" : "0", "comment" : "This IE shall indicate the acceptance or the rejection of the corresponding request message."})
ies.append({ "ie_type" : "Offending IE", "ie_value" : "Offending IE", "presence" : "C", "instance" : "0", "comment" : "This IE shall be included if the rejection is due to a conditional or mandatory IE missing or faulty."})
ies.append({ "ie_type" : "F-SEID", "ie_value" : "UP F-SEID", "presence" : "C", "instance" : "0", "comment" : "This IE shall be present if the cause is set to Request accepted (success). When present, it shall contain the unique identifier allocated by the UP function identifing the session."})
ies.append({ "ie_type" : "Created PDR", "ie_value" : "Created PDR", "presence" : "C", "instance" : "0", "comment" : "This IE shall be present if the cause is set to success and the UP function was requested to allocate the local F-TEID for the PDR. When present, this IE shall contain the PDR information associated to the PFCP session. There may be several instances of this IE.See table 7.5.3.2-1."})
ies.append({ "ie_type" : "Load Control Informationp", "ie_value" : "Load Control Information", "presence" : "O", "instance" : "0", "comment" : "The UP function may include this IE if it supports the load control feature and the feature is activated in the network.See Table 7.5.3.3-1."})
ies.append({ "ie_type" : "Overload Control Informationp", "ie_value" : "Overload Control Information", "presence" : "O", "instance" : "0", "comment" : "During an overload condition, the UP function may include this IE if it supports the overload control feature and the feature is activated in the network.See Table 7.5.3.4-1."})
ies.append({ "ie_type" : "FQ-CSIDp", "ie_value" : "SGW-U FQ-CSID", "presence" : "C", "instance" : "0", "comment" : "This IE shall be included according to the requirements in clause 23 of 3GPPTS23.007[24]."})
ies.append({ "ie_type" : "Failed Rule ID", "ie_value" : "Failed Rule ID", "presence" : "C", "instance" : "0", "comment" : "This IE shall be included if the Cause IE indicates a rejection due to a rule creation or modification failure. "})
msg_list[key]["ies"] = ies

28
lib/pfcp/support/cache/tlv-msg-52.py vendored Normal file
View File

@ -0,0 +1,28 @@
ies = []
ies.append({ "ie_type" : "F-SEID", "ie_value" : "CP F-SEID", "presence" : "C", "instance" : "0", "comment" : "This IE shall be present if the CP function decides to change its F-SEID for the PFCP session. The UP function shall use the new CP F-SEID for subsequent PFCP Session related messages for this PFCP Session. See Note 2."})
ies.append({ "ie_type" : "Remove PDR", "ie_value" : "Remove PDR", "presence" : "C", "instance" : "0", "comment" : "When present, this IE shall contain the PDR Rule which is requested to be removed. See Table 7.5.4-8. Several IEs within the same IE type may be present to represent a list of PDRs to remove."})
ies.append({ "ie_type" : "Remove FAR", "ie_value" : "Remove FAR", "presence" : "C", "instance" : "0", "comment" : "When present, this IE shall contain the FAR Rule which is requested to be removed. See Table 7.5.4-9.Several IEs within the same IE type may be present to represent a list of FARs to remove."})
ies.append({ "ie_type" : "Remove URR", "ie_value" : "Remove URR", "presence" : "C", "instance" : "0", "comment" : "When present, this shall contain the URR Rule which is requested to be removed. See Table 7.5.4-10.Several IEs within the same IE type may be present to represent a list of URRs to remove."})
ies.append({ "ie_type" : "Remove QER", "ie_value" : "Remove QER", "presence" : "C", "instance" : "0", "comment" : "When present, this IE shall contain the QER Rule which is requested to be removed. See Table 7.5.4-11. Several IEs within the same IE type may be present to represent a list of QERs to remove."})
ies.append({ "ie_type" : "Remove BAR", "ie_value" : "Remove BAR", "presence" : "C", "instance" : "0", "comment" : "When present, this IE shall contain the BAR Rule which is requested to be removed. See Table 7.5.4.12-1."})
type_list["Create PDR"]["max_instance"] = "1"
ies.append({ "ie_type" : "Create PDR", "ie_value" : "Create PDR", "presence" : "O", "instance" : "0", "comment" : "This IE shall be present if the CP function requests the UP function to create a new PDR.See Table 7.5.2.2-1. Several IEs within the same IE type may be present to represent a list of PDRs to create."})
ies.append({ "ie_type" : "Create PDR", "ie_value" : "Create PDR", "presence" : "C", "instance" : "1", "comment" : "This IE shall be present if the CP function requests the UP function to create a new PDR.See Table 7.5.2.2-1. Several IEs within the same IE type may be present to represent a list of PDRs to create."})
type_list["Create FAR"]["max_instance"] = "1"
ies.append({ "ie_type" : "Create FAR", "ie_value" : "Create FAR", "presence" : "O", "instance" : "0", "comment" : "This IE shall be present if the CP function requests the UP function to create a new FAR.See Table 7.5.2.3-1.Several IEs within the same IE type may be present to represent a list of FARs to create."})
ies.append({ "ie_type" : "Create FAR", "ie_value" : "Create FAR", "presence" : "C", "instance" : "1", "comment" : "This IE shall be present if the CP function requests the UP function to create a new FAR.See Table 7.5.2.3-1.Several IEs within the same IE type may be present to represent a list of FARs to create."})
ies.append({ "ie_type" : "Create URR", "ie_value" : "Create URR", "presence" : "C", "instance" : "0", "comment" : "This IE shall be present if the CP function requests the UP function to create a new URR. See Table 7.5.2.4-1. Several IEs within the same IE type may be present to represent a list of URRs to create."})
ies.append({ "ie_type" : "Create QER", "ie_value" : "Create QER", "presence" : "C", "instance" : "0", "comment" : "This IE shall be present if the CP function requests the UP function to create a new QER. See Table 7.5.2.5-1. Several IEs within the same IE type may be present to represent a list of QERs to create."})
ies.append({ "ie_type" : "Create BAR", "ie_value" : "Create BAR", "presence" : "C", "instance" : "0", "comment" : "This IE shall be present if the CP function requests the UP function to create a new BAR. See Table 7.5.2.2-1."})
type_list["Update PDR"]["max_instance"] = "1"
ies.append({ "ie_type" : "Update PDR", "ie_value" : "Update PDR", "presence" : "O", "instance" : "0", "comment" : "This IE shall be present if a PDR previously created for the PFCP session need to be modified. See Table 7.5.4.6-1. Several IEs within the same IE type may be present to represent a list of PDRs to update."})
ies.append({ "ie_type" : "Update PDR", "ie_value" : "Update PDR", "presence" : "C", "instance" : "1", "comment" : "This IE shall be present if a PDR previously created for the PFCP session need to be modified. See Table 7.5.4.6-1. Several IEs within the same IE type may be present to represent a list of PDRs to update."})
ies.append({ "ie_type" : "Update FAR", "ie_value" : "Update FAR", "presence" : "C", "instance" : "0", "comment" : "This IE shall be present if a FAR previously created for the PFCP session need to be modified. See Table 7.5.4.7-1. Several IEs within the same IE type may be present to represent a list of FARs to update."})
ies.append({ "ie_type" : "Update URR", "ie_value" : "Update URR", "presence" : "C", "instance" : "0", "comment" : "This IE shall be present if URR(s) previously created for the PFCP session need to be modified.Several IEs within the same IE type may be present to represent a list of modified URRs. Previously URRs that are not modified shall not be included. See Table 7.5.4.8-1."})
ies.append({ "ie_type" : "Update QER", "ie_value" : "Update QER", "presence" : "C", "instance" : "0", "comment" : "This IE shall be present if QER(s) previously created for the PFCP session need to be modified. Several IEs within the same IE type may be present to represent a list of modified QERs. Previously created QERs that are not modified shall not be included.See Table 7.5.4.9-1."})
ies.append({ "ie_type" : "Update BAR Session Modification Request", "ie_value" : "Update BAR", "presence" : "C", "instance" : "0", "comment" : "This IE shall be present if a BAR previously created for the PFCP session needs to be modified. A previously created BAR that is not modified shall not be included.See Table 7.5.4.3-3."})
ies.append({ "ie_type" : "PFCPSMReq-Flags", "ie_value" : "PFCPSMReq-Flags", "presence" : "C", "instance" : "0", "comment" : "This IE shall be included if at least one of the flags is set to 1. - DROBU (Drop Buffered Packets): the CP function shall set this flag if the UP function is requested to drop the packets currently buffered for this PFCP session (see NOTE 1).- QAURR (Query All URRs): the CP function shall set this flag if the CP function requests immediate usage report(s) for all the URRs previously provisioned for this PFCP session (see NOTE 3). "})
ies.append({ "ie_type" : "Query URR", "ie_value" : "Query URR", "presence" : "C", "instance" : "0", "comment" : "This IE shall be present if the CP function requests immediate usage report(s) to the UP function. Several IEs within the same IE type may be present to represent a list of URRs for which an immediate report is requested.See Table 7.5.4.10-1. See NOTE 3."})
ies.append({ "ie_type" : "FQ-CSIDp", "ie_value" : "PGW-C FQ-CSID", "presence" : "C", "instance" : "0", "comment" : "This IE shall be included according to the requirements in clause 23 of 3GPPTS23.007[24]."})
ies.append({ "ie_type" : "User Plane Inactivity Timer", "ie_value" : "User Plane Inactivity Timer", "presence" : "C", "instance" : "0", "comment" : "This IE shall be present if it needs to be changed."})
msg_list[key]["ies"] = ies

9
lib/pfcp/support/cache/tlv-msg-53.py vendored Normal file
View File

@ -0,0 +1,9 @@
ies = []
ies.append({ "ie_type" : "Cause", "ie_value" : "Cause", "presence" : "M", "instance" : "0", "comment" : "This IE shall indicate the acceptance or the rejection of the corresponding request message."})
ies.append({ "ie_type" : "Offending IE", "ie_value" : "Offending IE", "presence" : "C", "instance" : "0", "comment" : "This IE shall be included if the rejection is due to an conditional or mandatory IE missing or faulty."})
ies.append({ "ie_type" : "Created PDR", "ie_value" : "Created PDR", "presence" : "C", "instance" : "0", "comment" : "This IE shall be present if the cause is set to success, new PDR(s) were requested to be created and the UP function was requested to allocate the local F-TEID for the PDR(s).When present, this IE shall contain the PDR information associated to the PFCP session. See Table 7.5.3-2."})
ies.append({ "ie_type" : "Load Control Informationp", "ie_value" : "Load Control Information", "presence" : "O", "instance" : "0", "comment" : "The UP function may include this IE if it supports the load control feature and the feature is activated in the network.See Table 7.5.3-3."})
ies.append({ "ie_type" : "Overload Control Informationp", "ie_value" : "Overload Control Information", "presence" : "O", "instance" : "0", "comment" : "During an overload condition, the UP function may include this IE if it supports the overload control feature and the feature is activated in the network."})
ies.append({ "ie_type" : "Usage Report in Session Modification Response", "ie_value" : "Usage Report", "presence" : "C", "instance" : "0", "comment" : "This IE shall be present if the Query URR IE was present in the PFCP Session Modification Request and traffic usage measurements for that URR are available at the UP function. Several IEs within the same IE type may be present to represent a list of Usage Reports."})
ies.append({ "ie_type" : "Failed Rule ID", "ie_value" : "Failed Rule ID", "presence" : "C", "instance" : "0", "comment" : "This IE shall be included if the Cause IE indicates a rejection due to a rule creation or modification failure."})
msg_list[key]["ies"] = ies

2
lib/pfcp/support/cache/tlv-msg-54.py vendored Normal file
View File

@ -0,0 +1,2 @@
ies = []
msg_list[key]["ies"] = ies

1
lib/pfcp/support/cache/tlv-msg-55.py vendored Normal file
View File

@ -0,0 +1 @@
ies = []

8
lib/pfcp/support/cache/tlv-msg-56.py vendored Normal file
View File

@ -0,0 +1,8 @@
ies = []
ies.append({ "ie_type" : "Report Type", "ie_value" : "Report Type", "presence" : "M", "instance" : "0", "comment" : "This IE shall indicate the type of the report."})
ies.append({ "ie_type" : "Downlink Data Report", "ie_value" : "Downlink Data Report", "presence" : "C", "instance" : "0", "comment" : "This IE shall be present if the Report Type indicates a Downlink Data Report. "})
ies.append({ "ie_type" : "Usage Report Session Report Request", "ie_value" : "Usage Report", "presence" : "C", "instance" : "0", "comment" : "This IE shall be present if the Report Type indicates a Usage Report. Several IEs within the same IE type may be present to represent a list of Usage Reports."})
ies.append({ "ie_type" : "Error Indication Report", "ie_value" : "Error Indication Report", "presence" : "C", "instance" : "0", "comment" : "This IE shall be present if the Report Type indicates an Error Indication Report. "})
ies.append({ "ie_type" : "Load Control Informationp", "ie_value" : "Load Control Information", "presence" : "O", "instance" : "0", "comment" : "The UP function may include this IE if it supports the load control feature and the feature is activated in the network.See Table 7.5.3.3-1."})
ies.append({ "ie_type" : "Overload Control Informationp", "ie_value" : "Overload Control Information", "presence" : "O", "instance" : "0", "comment" : "During an overload condition, the UP function may include this IE if it supports the overload control feature and the feature is activated in the network.See Table 7.5.3.4-1."})
msg_list[key]["ies"] = ies

6
lib/pfcp/support/cache/tlv-msg-57.py vendored Normal file
View File

@ -0,0 +1,6 @@
ies = []
ies.append({ "ie_type" : "Cause", "ie_value" : "Cause", "presence" : "M", "instance" : "0", "comment" : "This IE shall indicate the acceptance or the rejection of the corresponding request message."})
ies.append({ "ie_type" : "Offending IE", "ie_value" : "Offending IE", "presence" : "C", "instance" : "0", "comment" : "This IE shall be included if the rejection is due to an conditional or mandatory IE missing or faulty."})
ies.append({ "ie_type" : "Update BAR PFCP Session Report Response", "ie_value" : "Update BAR", "presence" : "C", "instance" : "0", "comment" : "This IE shall be present if a BAR previously created for the PFCP session needs to be modified. A previously created BAR that is not modified shall not be included. See Table 7.5.9.2-1."})
ies.append({ "ie_type" : "PFCPSRRsp-Flags", "ie_value" : "PFCPSRRsp-Flags", "presence" : "C", "instance" : "0", "comment" : "This IE shall be included if at least one of the flags is set to 1."})
msg_list[key]["ies"] = ies

8
lib/pfcp/support/cache/tlv-msg-6.py vendored Normal file
View File

@ -0,0 +1,8 @@
ies = []
ies.append({ "ie_type" : "Node ID", "ie_value" : "Node ID", "presence" : "M", "instance" : "0", "comment" : "This IE shall contain the unique identifier of the sending Node."})
ies.append({ "ie_type" : "Cause", "ie_value" : "Cause", "presence" : "M", "instance" : "0", "comment" : "This IE shall indicate the acceptance or the rejection of the corresponding request message."})
ies.append({ "ie_type" : "Recovery Time Stamp", "ie_value" : "Recovery Time Stamp", "presence" : "M", "instance" : "0", "comment" : "This IE shall contain the time stamp when the node was started, see clause 19A of 3GPPTS23.007[24]."})
ies.append({ "ie_type" : "UP Function Features", "ie_value" : "UP Function Features", "presence" : "C", "instance" : "0", "comment" : "This IE shall be present if the UP function sends this message and the UP function supports at least one UP feature defined in this IE. When present, this IE shall indicate the features the UP function supports."})
ies.append({ "ie_type" : "CP Function Features", "ie_value" : "CP Function Features", "presence" : "C", "instance" : "0", "comment" : "This IE shall be present if the CP function sends this message and the CP function supports at least one CP feature defined in this IE. When present, this IE indicates the features the CP function supports."})
ies.append({ "ie_type" : "User Plane IP Resource Information", "ie_value" : "User Plane IP Resource Information", "presence" : "O", "instance" : "0", "comment" : "This IE may be present if the UP function sends this message.When present, this IE shall contain an IPv4 and/or an IPv6 address, together with a TEID range that the CP function shall use to allocate GTP-U F-TEID in the UP function. Several IEs with the same IE type may be present to represent multiple User Plane IP Resources."})
msg_list[key]["ies"] = ies

8
lib/pfcp/support/cache/tlv-msg-7.py vendored Normal file
View File

@ -0,0 +1,8 @@
ies = []
ies.append({ "ie_type" : "Node ID", "ie_value" : "Node ID", "presence" : "M", "instance" : "0", "comment" : "This IE shall contain the unique identifier of the sending Node."})
ies.append({ "ie_type" : "UP Function Features", "ie_value" : "UP Function Features", "presence" : "O", "instance" : "0", "comment" : "If present, this IE shall indicate the supported Features when the sending node is the UP function."})
ies.append({ "ie_type" : "CP Function Features", "ie_value" : "CP Function Features", "presence" : "O", "instance" : "0", "comment" : "If present, this IE shall indicate the supported Features when the sending node is the CP function."})
ies.append({ "ie_type" : "PFCP Association Release Request", "ie_value" : "PFCP Association Release Request", "presence" : "C", "instance" : "0", "comment" : "This IE shall be present if the UP function requests the CP function to release the PFCP association."})
ies.append({ "ie_type" : "Graceful Release Period", "ie_value" : "Graceful Release Period", "presence" : "C", "instance" : "0", "comment" : "This IE shall be present if the UP function requests a graceful release of the PFCP association."})
ies.append({ "ie_type" : "User Plane IP Resource Information", "ie_value" : "User Plane IP Resource Information", "presence" : "O", "instance" : "0", "comment" : "This IE may be present if the UP function sends this message.When present, this IE shall contain an IPv4 and/or an IPv6 address, together with a TEID range that the CP function shall use to allocate GTP-U F-TEID in the UP function.Several IEs with the same IE type may be present to represent multiple User Plane IP Resources. "})
msg_list[key]["ies"] = ies

6
lib/pfcp/support/cache/tlv-msg-8.py vendored Normal file
View File

@ -0,0 +1,6 @@
ies = []
ies.append({ "ie_type" : "Node ID", "ie_value" : "Node ID", "presence" : "M", "instance" : "0", "comment" : "This IE shall contain the unique identifier of the sending Node."})
ies.append({ "ie_type" : "Cause", "ie_value" : "Cause", "presence" : "M", "instance" : "0", "comment" : "This IE shall indicate the acceptance or the rejection of the corresponding request message."})
ies.append({ "ie_type" : "UP Function Features", "ie_value" : "UP Function Features", "presence" : "O", "instance" : "0", "comment" : "If present, this IE shall indicate the supported Features when the sending node is the UP function."})
ies.append({ "ie_type" : "CP Function Features", "ie_value" : "CP Function Features", "presence" : "O", "instance" : "0", "comment" : "If present, this IE shall indicate the supported Features when the sending node is the CP function."})
msg_list[key]["ies"] = ies

3
lib/pfcp/support/cache/tlv-msg-9.py vendored Normal file
View File

@ -0,0 +1,3 @@
ies = []
ies.append({ "ie_type" : "Node ID", "ie_value" : "Node ID", "presence" : "M", "instance" : "0", "comment" : "This IE shall contain the unique identifier of the sending Node."})
msg_list[key]["ies"] = ies

23
lib/pfcp/support/cache/tlv-msg-list.py vendored Normal file
View File

@ -0,0 +1,23 @@
msg_list["PFCP Heartbeat Request"] = { "type" : "1" }
msg_list["PFCP Heartbeat Response"] = { "type" : "2" }
msg_list["PFCP PFD Management Request"] = { "type" : "3" }
msg_list["PFCP PFD Management Response"] = { "type" : "4" }
msg_list["PFCP Association Setup Request"] = { "type" : "5" }
msg_list["PFCP Association Setup Response"] = { "type" : "6" }
msg_list["PFCP Association Update Request"] = { "type" : "7" }
msg_list["PFCP Association Update Response"] = { "type" : "8" }
msg_list["PFCP Association Release Request"] = { "type" : "9" }
msg_list["PFCP Association Release Response"] = { "type" : "10" }
msg_list["PFCP Version Not Supported Response"] = { "type" : "11" }
msg_list["PFCP Node Report Request"] = { "type" : "12" }
msg_list["PFCP Node Report Response"] = { "type" : "13" }
msg_list["PFCP Session Set Deletion Request"] = { "type" : "14" }
msg_list["PFCP Session Set Deletion Response"] = { "type" : "15" }
msg_list["PFCP Session Establishment Request"] = { "type" : "50" }
msg_list["PFCP Session Establishment Response"] = { "type" : "51" }
msg_list["PFCP Session Modification Request"] = { "type" : "52" }
msg_list["PFCP Session Modification Response"] = { "type" : "53" }
msg_list["PFCP Session Deletion Request"] = { "type" : "54" }
msg_list["PFCP Session Deletion Response"] = { "type" : "55" }
msg_list["PFCP Session Report Request"] = { "type" : "56" }
msg_list["PFCP Session Report Response"] = { "type" : "57" }

124
lib/pfcp/support/cache/tlv-type-list.py vendored Normal file
View File

@ -0,0 +1,124 @@
type_list["Create PDR"] = { "type" : "1", "max_instance" : "0" }
type_list["PDI"] = { "type" : "2", "max_instance" : "0" }
type_list["Create FAR"] = { "type" : "3", "max_instance" : "0" }
type_list["Forwarding Parameters"] = { "type" : "4", "max_instance" : "0" }
type_list["Duplicating Parameters"] = { "type" : "5", "max_instance" : "0" }
type_list["Create URR"] = { "type" : "6", "max_instance" : "0" }
type_list["Create QER"] = { "type" : "7", "max_instance" : "0" }
type_list["Created PDR"] = { "type" : "8", "max_instance" : "0" }
type_list["Update PDR"] = { "type" : "9", "max_instance" : "0" }
type_list["Update FAR"] = { "type" : "10", "max_instance" : "0" }
type_list["Update Forwarding Parameters"] = { "type" : "11", "max_instance" : "0" }
type_list["Update BAR PFCP Session Report Response"] = { "type" : "12", "max_instance" : "0" }
type_list["Update URR"] = { "type" : "13", "max_instance" : "0" }
type_list["Update QER"] = { "type" : "14", "max_instance" : "0" }
type_list["Remove PDR"] = { "type" : "15", "max_instance" : "0" }
type_list["Remove FAR"] = { "type" : "16", "max_instance" : "0" }
type_list["Remove URR"] = { "type" : "17", "max_instance" : "0" }
type_list["Remove QER"] = { "type" : "18", "max_instance" : "0" }
type_list["Cause"] = { "type" : "19", "max_instance" : "0" }
type_list["Source Interface"] = { "type" : "20", "max_instance" : "0" }
type_list["F-TEID"] = { "type" : "21", "max_instance" : "0" }
type_list["Network Instance"] = { "type" : "22", "max_instance" : "0" }
type_list["SDF Filter"] = { "type" : "23", "max_instance" : "0" }
type_list["Application ID"] = { "type" : "24", "max_instance" : "0" }
type_list["Gate Status"] = { "type" : "25", "max_instance" : "0" }
type_list["MBR"] = { "type" : "26", "max_instance" : "0" }
type_list["GBR"] = { "type" : "27", "max_instance" : "0" }
type_list["QER Correlation ID"] = { "type" : "28", "max_instance" : "0" }
type_list["Precedence"] = { "type" : "29", "max_instance" : "0" }
type_list["Transport Level Marking"] = { "type" : "30", "max_instance" : "0" }
type_list["Volume Threshold"] = { "type" : "31", "max_instance" : "0" }
type_list["Time Threshold"] = { "type" : "32", "max_instance" : "0" }
type_list["Monitoring Time"] = { "type" : "33", "max_instance" : "0" }
type_list["Subsequent Volume Threshold"] = { "type" : "34", "max_instance" : "0" }
type_list["Subsequent Time Threshold"] = { "type" : "35", "max_instance" : "0" }
type_list["Inactivity Detection Time"] = { "type" : "36", "max_instance" : "0" }
type_list["Reporting Triggers"] = { "type" : "37", "max_instance" : "0" }
type_list["Redirect Information"] = { "type" : "38", "max_instance" : "0" }
type_list["Report Type"] = { "type" : "39", "max_instance" : "0" }
type_list["Offending IE"] = { "type" : "40", "max_instance" : "0" }
type_list["Forwarding Policy"] = { "type" : "41", "max_instance" : "0" }
type_list["Destination Interface"] = { "type" : "42", "max_instance" : "0" }
type_list["UP Function Features"] = { "type" : "43", "max_instance" : "0" }
type_list["Apply Action"] = { "type" : "44", "max_instance" : "0" }
type_list["Downlink Data Service Information"] = { "type" : "45", "max_instance" : "0" }
type_list["Downlink Data Notification Delay"] = { "type" : "46", "max_instance" : "0" }
type_list["DL Buffering Duration"] = { "type" : "47", "max_instance" : "0" }
type_list["DL Buffering Suggested Packet Count"] = { "type" : "48", "max_instance" : "0" }
type_list["PFCPSMReq-Flags"] = { "type" : "49", "max_instance" : "0" }
type_list["PFCPSRRsp-Flags"] = { "type" : "50", "max_instance" : "0" }
type_list["Load Control Informationp"] = { "type" : "51", "max_instance" : "0" }
type_list["Sequence Number"] = { "type" : "52", "max_instance" : "0" }
type_list["Metricp"] = { "type" : "53", "max_instance" : "0" }
type_list["Overload Control Informationp"] = { "type" : "54", "max_instance" : "0" }
type_list["Timer"] = { "type" : "55", "max_instance" : "0" }
type_list["Packet Detection Rule ID"] = { "type" : "56", "max_instance" : "0" }
type_list["F-SEID"] = { "type" : "57", "max_instance" : "0" }
type_list["Application ID's PFDs"] = { "type" : "58", "max_instance" : "0" }
type_list["PFD context"] = { "type" : "59", "max_instance" : "0" }
type_list["Node ID"] = { "type" : "60", "max_instance" : "0" }
type_list["PFD contents"] = { "type" : "61", "max_instance" : "0" }
type_list["Measurement Method"] = { "type" : "62", "max_instance" : "0" }
type_list["Usage Report Trigger"] = { "type" : "63", "max_instance" : "0" }
type_list["Measurement Period"] = { "type" : "64", "max_instance" : "0" }
type_list["FQ-CSIDp"] = { "type" : "65", "max_instance" : "0" }
type_list["Volume Measurement"] = { "type" : "66", "max_instance" : "0" }
type_list["Duration Measurement"] = { "type" : "67", "max_instance" : "0" }
type_list["Application Detection Information"] = { "type" : "68", "max_instance" : "0" }
type_list["Time of First Packet"] = { "type" : "69", "max_instance" : "0" }
type_list["Time of Last Packet"] = { "type" : "70", "max_instance" : "0" }
type_list["Quota Holding Time"] = { "type" : "71", "max_instance" : "0" }
type_list["Dropped DL Traffic Threshold"] = { "type" : "72", "max_instance" : "0" }
type_list["Volume Quota"] = { "type" : "73", "max_instance" : "0" }
type_list["Time Quota"] = { "type" : "74", "max_instance" : "0" }
type_list["Start Time"] = { "type" : "75", "max_instance" : "0" }
type_list["End Time"] = { "type" : "76", "max_instance" : "0" }
type_list["Query URR"] = { "type" : "77", "max_instance" : "0" }
type_list["Usage Report in Session Modification Response"] = { "type" : "78", "max_instance" : "0" }
type_list["Usage Report Session Deletion Response"] = { "type" : "79", "max_instance" : "0" }
type_list["Usage Report Session Report Request"] = { "type" : "80", "max_instance" : "0" }
type_list["URR ID"] = { "type" : "81", "max_instance" : "0" }
type_list["Linked URR ID"] = { "type" : "82", "max_instance" : "0" }
type_list["Downlink Data Report"] = { "type" : "83", "max_instance" : "0" }
type_list["Outer Header Creation"] = { "type" : "84", "max_instance" : "0" }
type_list["Create BAR"] = { "type" : "85", "max_instance" : "0" }
type_list["Update BAR Session Modification Request"] = { "type" : "86", "max_instance" : "0" }
type_list["Remove BAR"] = { "type" : "87", "max_instance" : "0" }
type_list["BAR ID"] = { "type" : "88", "max_instance" : "0" }
type_list["CP Function Features"] = { "type" : "89", "max_instance" : "0" }
type_list["Usage Information"] = { "type" : "90", "max_instance" : "0" }
type_list["Application Instance ID"] = { "type" : "91", "max_instance" : "0" }
type_list["Flow Information"] = { "type" : "92", "max_instance" : "0" }
type_list["UE IP Address"] = { "type" : "93", "max_instance" : "0" }
type_list["Packet Rate"] = { "type" : "94", "max_instance" : "0" }
type_list["Outer Header Removal"] = { "type" : "95", "max_instance" : "0" }
type_list["Recovery Time Stamp"] = { "type" : "96", "max_instance" : "0" }
type_list["DL Flow Level Marking"] = { "type" : "97", "max_instance" : "0" }
type_list["Header Enrichment"] = { "type" : "98", "max_instance" : "0" }
type_list["Error Indication Report"] = { "type" : "99", "max_instance" : "0" }
type_list["Measurement Information"] = { "type" : "100", "max_instance" : "0" }
type_list["Node Report Type"] = { "type" : "101", "max_instance" : "0" }
type_list["User Plane Path Failure Report"] = { "type" : "102", "max_instance" : "0" }
type_list["Remote GTP-U Peer"] = { "type" : "103", "max_instance" : "0" }
type_list["UR-SEQN"] = { "type" : "104", "max_instance" : "0" }
type_list["Update Duplicating Parameters"] = { "type" : "105", "max_instance" : "0" }
type_list["Activate Predefined Rules"] = { "type" : "106", "max_instance" : "0" }
type_list["Deactivate Predefined Rules"] = { "type" : "107", "max_instance" : "0" }
type_list["FAR ID"] = { "type" : "108", "max_instance" : "0" }
type_list["QER ID"] = { "type" : "109", "max_instance" : "0" }
type_list["OCI Flags"] = { "type" : "110", "max_instance" : "0" }
type_list["PFCP Association Release Request"] = { "type" : "111", "max_instance" : "0" }
type_list["Graceful Release Period"] = { "type" : "112", "max_instance" : "0" }
type_list["PDN Typep"] = { "type" : "113", "max_instance" : "0" }
type_list["Failed Rule ID"] = { "type" : "114", "max_instance" : "0" }
type_list["Time Quota Mechanism"] = { "type" : "115", "max_instance" : "0" }
type_list["User Plane IP Resource Information"] = { "type" : "116", "max_instance" : "0" }
type_list["User Plane Inactivity Timer"] = { "type" : "117", "max_instance" : "0" }
type_list["Aggregated URRs"] = { "type" : "118", "max_instance" : "0" }
type_list["Multiplier"] = { "type" : "119", "max_instance" : "0" }
type_list["Aggregated URR ID"] = { "type" : "120", "max_instance" : "0" }
type_list["Subsequent Volume Quota"] = { "type" : "121", "max_instance" : "0" }
type_list["Subsequent Time Quota"] = { "type" : "122", "max_instance" : "0" }
type_list["RQI"] = { "type" : "123", "max_instance" : "0" }
type_list["QFI"] = { "type" : "124", "max_instance" : "0" }

View File

@ -0,0 +1,810 @@
# Copyright (C) 2019 by Sukchan Lee <acetcom@gmail.com>
# This file is part of Open5GS.
# This program is free software: you can redistribute it and/or modify
# it under the terms of the GNU Affero General Public License as published by
# the Free Software Foundation, either version 3 of the License, or
# (at your option) any later version.
#
# This program is distributed in the hope that it will be useful,
# but WITHOUT ANY WARRANTY; without even the implied warranty of
# MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
# GNU General Public License for more details.
#
# You should have received a copy of the GNU General Public License
# along with this program. If not, see <https://www.gnu.org/licenses/>.
from docx import Document
import re, os, sys, string
import datetime
import getopt
import getpass
version = "0.1.0"
msg_list = {}
type_list = {}
group_list = {}
verbosity = 0
filename = ""
outdir = './'
cachedir = './cache/'
FAIL = '\033[91m'
INFO = '\033[93m'
ENDC = '\033[0m'
def d_print(string):
if verbosity > 0:
sys.stdout.write(string)
def d_info(string):
sys.stdout.write(INFO + string + ENDC + "\n")
def d_error(string):
sys.stderr.write(FAIL + string + ENDC + "\n")
sys.exit(0)
def write_file(f, string):
f.write(string)
d_print(string)
def output_header_to_file(f):
now = datetime.datetime.now()
f.write("""/*
* Copyright (C) 2019 by Sukchan Lee <acetcom@gmail.com>
*
* This file is part of Open5GS.
*
* This program is free software: you can redistribute it and/or modify
* it under the terms of the GNU Affero General Public License as published by
* the Free Software Foundation, either version 3 of the License, or
* (at your option) any later version.
*
* This program is distributed in the hope that it will be useful,
* but WITHOUT ANY WARRANTY; without even the implied warranty of
* MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
* GNU General Public License for more details.
*
* You should have received a copy of the GNU General Public License
* along with this program. If not, see <https://www.gnu.org/licenses/>.
*/
""")
f.write("/*******************************************************************************\n")
f.write(" * This file had been created by pfcp-tlv.py script v%s\n" % (version))
f.write(" * Please do not modify this file but regenerate it via script.\n")
f.write(" * Created on: %s by %s\n * from %s\n" % (str(now), getpass.getuser(), filename))
f.write(" ******************************************************************************/\n\n")
def usage():
print "Python generating TLV build/parser for PFCP v%s" % (version)
print "Usage: python pfcp-tlv.py [options]"
print "Available options:"
print "-d Enable script debug"
print "-f [file] Input file to parse"
print "-o [dir] Output files to given directory"
print "-c [dir] Cache files to given directory"
print "-h Print this help and return"
def v_upper(v):
return re.sub('3GPP', '', re.sub('\'', '_', re.sub('/', '_', re.sub('-', '_', re.sub(' ', '_', v)))).upper())
def v_lower(v):
return re.sub('3gpp', '', re.sub('\'', '_', re.sub('/', '_', re.sub('-', '_', re.sub(' ', '_', v)))).lower())
def get_cells(cells):
#instance = cells[4].text.encode('ascii', 'ignore')
#if instance.isdigit() is not True:
# return None
instance = "0" # PFCP has no instance
note = cells[0].text.encode('ascii', 'ignore')
if note.find('NOTE') != -1:
return None
comment = cells[2].text.encode('ascii', 'ignore')
comment = re.sub('\n|\"|\'|\\\\', '', comment);
#print comment
ie_type = re.sub('\s*$', '', re.sub('\'\s*\n*\s*\(NOTE.*\)*', '', cells[-1].text.encode('ascii', 'ignore')))
#if ie_type.find('Usage Report') != -1:
if ie_type == 'Usage Report':
if comment.find('Report Type') != -1:
ie_type = "Usage Report Session Report Request"
elif comment.find('Query URR') != -1:
ie_type = "Usage Report in Session Modification Response"
elif comment.find('provisioned ') != -1:
ie_type = "Usage Report Session Deletion Response"
else:
assert False, "Unknown IE type : [Usage Report]"
if ie_type == 'Update BAR':
if comment.find('7.5.4.3-3') != -1:
ie_type = "Update BAR Session Modification Request"
elif comment.find('7.5.9.2-1') != -1:
ie_type = "Update BAR PFCP Session Report Response"
else:
assert False, "Unknown IE type : [Update BAR]"
if ie_type == 'Metric' or ie_type == 'FQ-CSID' or ie_type == 'PDN Type':
ie_type = ie_type + 'p'
elif ie_type == 'Load Control Information' or ie_type == 'Overload Control Information':
ie_type = ie_type + 'p'
if ie_type.find('PFD Contents') != -1:
ie_type = 'PFD contents'
elif ie_type.find('PFD') != -1:
ie_type = 'PFD context'
elif ie_type.find('PDR ID') != -1:
ie_type = 'Packet Detection Rule ID'
elif ie_type.find('UE IP address') != -1:
ie_type = 'UE IP Address'
elif ie_type.find('SxSMReq-Flags') != -1:
ie_type = 'PFCPSMReq-Flags'
elif ie_type.find('PFCPSRRsp-Flags2') != -1:
ie_type = 'PFCPSRRsp-Flags'
elif ie_type.find('IPv4 Configuration Parameters (IP4CP)') != -1:
ie_type = 'IP4CP'
if ie_type not in type_list.keys():
assert False, "Unknown IE type : [" \
+ cells[-1].text + "]" + "(" + ie_type + ")"
presence = cells[1].text.encode('ascii', 'ignore')
ie_value = re.sub('\s*\n*\s*\([^\)]*\)*', '', cells[0].text).encode('ascii', 'ignore')
if ie_value[len(ie_value)-1] == ' ':
ie_value = ie_value[:len(ie_value)-1]
# 0402: ?
#print ie_type
if ie_type == 'Create PDR' or ie_type == 'Create FAR' or ie_type == 'Update PDR':
instance = "1"
print ie_type + ' ' + type_list[ie_type]["max_instance"] + '\n'
if int(instance) > int(type_list[ie_type]["max_instance"]):
type_list[ie_type]["max_instance"] = instance
write_file(f, "type_list[\"" + ie_type + "\"][\"max_instance\"] = \"" + instance + "\"\n")
print "CCCCCCCCCCCCCCCCCCCCCCCCCCCC\n"
return { "ie_type" : ie_type, "ie_value" : ie_value, "presence" : presence, "instance" : instance, "comment" : comment }
def write_cells_to_file(name, cells):
write_file(f, name + ".append({ \"ie_type\" : \"" + cells["ie_type"] + \
"\", \"ie_value\" : \"" + cells["ie_value"] + \
"\", \"presence\" : \"" + cells["presence"] + \
"\", \"instance\" : \"" + cells["instance"] + \
"\", \"comment\" : \"" + cells["comment"] + "\"})\n")
try:
opts, args = getopt.getopt(sys.argv[1:], "df:ho:c:", ["debug", "file", "help", "output", "cache"])
except getopt.GetoptError as err:
# print help information and exit:
usage()
sys.exit(2)
for o, a in opts:
if o in ("-d", "--debug"):
verbosity = 1
if o in ("-f", "--file"):
filename = a
if o in ("-o", "--output"):
outdir = a
if outdir.rfind('/') != len(outdir):
outdir += '/'
if o in ("-c", "--cache"):
cache = a
if cachedir.rfind('/') != len(cachedir):
cachedir += '/'
if o in ("-h", "--help"):
usage()
sys.exit(2)
if os.path.isfile(filename) and os.access(filename, os.R_OK):
file = open(filename, 'r')
else:
d_error("Cannot find file : " + filename)
d_info("[Message List]")
cachefile = cachedir + 'tlv-msg-list.py'
if os.path.isfile(cachefile) and os.access(cachefile, os.R_OK):
execfile(cachefile)
print "Read from " + cachefile
else:
document = Document(filename)
f = open(cachefile, 'w')
msg_table = ""
for i, table in enumerate(document.tables):
cell = table.rows[0].cells[0]
if cell.text.find('Message Type value') != -1:
msg_table = table
d_print("Table Index = %d\n" % i)
#print("Table Index = %d\n" % i)
for row in msg_table.rows[2:-4]:
key = row.cells[1].text.encode('ascii', 'ignore')
type = row.cells[0].text.encode('ascii', 'ignore')
if type.isdigit() is False:
continue
if int(type) in range(128, 160):
continue
if int(type) in range(231, 240):
continue
if key.find('Reserved') != -1:
continue
key = re.sub('\s*\n*\s*\([^\)]*\)*', '', key)
msg_list[key] = { "type": type }
#print("msg type =" + type)
write_file(f, "msg_list[\"" + key + "\"] = { \"type\" : \"" + type + "\" }\n")
f.close()
d_info("[IE Type List]")
cachefile = cachedir + 'tlv-type-list.py'
if os.path.isfile(cachefile) and os.access(cachefile, os.R_OK):
execfile(cachefile)
print "Read from " + cachefile
else:
document = Document(filename)
f = open(cachefile, 'w')
ie_table = ""
for i, table in enumerate(document.tables):
cell = table.rows[0].cells[0]
if cell.text.find('IE Type value') != -1:
ie_table = table
d_print("Table Index = %d\n" % i)
for row in ie_table.rows[1:-1]:
key = row.cells[1].text.encode('ascii', 'ignore')
if key.find('Reserved') != -1:
continue
if key.find('MM Context') != -1:
continue
#elif key.find('Recovery') != -1:
# key = 'Recovery'
elif key.find('Trusted WLAN Mode Indication') != -1:
key = 'TWMI'
elif key.find('LDN') != -1:
key = 'LDN'
elif key.find('APCO') != -1:
key = 'APCO'
elif key.find('Remote UE IP information') != -1:
key = 'Remote UE IP Information'
elif key.find('Procedure Transaction ID') != -1:
key = 'PTI'
else:
#key = re.sub('.*\(', '', row.cells[1].text.encode('ascii', 'ignore'))
key = re.sub('\(', '', key)
key = re.sub('\)', '', key)
key = re.sub('\s*$', '', key)
type = row.cells[0].text.encode('ascii', 'ignore')
if key == 'Metric' or key == 'FQ-CSID' or key == 'PDN Type':
key = key + 'p'
elif key == 'Load Control Information' or key == 'Overload Control Information':
key = key + 'p'
# 0402: here is active !
#if key == 'Create PDR' or key == 'Create FAR' or key == 'Update PDR':
# type_list[key] = { "type": type , "max_instance" : "1" }
#else:
type_list[key] = { "type": type , "max_instance" : "0" }
write_file(f, "type_list[\"" + key + "\"] = { \"type\" : \"" + type)
write_file(f, "\", \"max_instance\" : \"0\" }\n")
f.close()
#type_list['MM Context'] = { "type": "107", "max_instance" : "0" }
d_info("[Group IE List]")
cachefile = cachedir + 'tlv-group-list.py'
if os.path.isfile(cachefile) and os.access(cachefile, os.R_OK):
execfile(cachefile)
print "Read from " + cachefile
else:
document = Document(filename)
f = open(cachefile, 'w')
for i, table in enumerate(document.tables):
if table.rows[0].cells[0].text.find('Octet') != -1 and \
table.rows[0].cells[1].text.find('Outer Header to be created') == -1 and \
table.rows[0].cells[2].text.find('IE Type') != -1:
d_print("Table Index = %d\n" % i)
row = table.rows[0];
if len(re.findall('\d+', row.cells[2].text)) == 0:
continue;
ie_type = re.findall('\d+', row.cells[2].text)[0].encode('ascii', 'ignore')
ie_name = re.sub('\s*IE Type.*', '', row.cells[2].text.encode('ascii', 'ignore'))
if (int(ie_type) == 78):
ie_name = "Usage Report in Session Modification Response"
elif (int(ie_type) == 79):
ie_name = "Usage Report Session Deletion Response"
elif (int(ie_type) == 80):
ie_name = "Usage Report Session Report Request"
elif (int(ie_type) == 86):
ie_name = "Update BAR Session Modification Request"
elif (int(ie_type) == 12):
ie_name = "Update BAR PFCP Session Report Response"
if ie_name == 'PFD':
ie_name = 'PFD context'
if ie_name == 'Load Control Information' or ie_name == 'Overload Control Information':
ie_name = ie_name + 'p'
if ie_name not in group_list.keys():
ies = []
write_file(f, "ies = []\n")
for row in table.rows[4:]:
cells = get_cells(row.cells)
if cells is None:
continue
#if cells["ie_type"] == 'Create PDR' or cells["ie_type"] == 'Create FAR' or cells["ie_type"] == 'Update PDR':
# cells["instance"] = str(int(cells["instance"])+1)
# print 'Hahahaha-----------------------\n'
ies_is_added = True
for ie in ies:
if (cells["ie_type"], cells["instance"]) == (ie["ie_type"], ie["instance"]):
ies_is_added = False
if ies_is_added is True:
ies.append(cells)
write_cells_to_file("ies", cells)
group_list[ie_name] = { "type" : ie_type, "ies" : ies }
write_file(f, "group_list[\"" + ie_name + "\"] = { \"type\" : \"" + ie_type + "\", \"ies\" : ies }\n")
else:
group_list_is_added = False
added_ies = group_list[ie_name]["ies"]
write_file(f, "added_ies = group_list[\"" + ie_name + "\"][\"ies\"]\n")
for row in table.rows[4:]:
cells = get_cells(row.cells)
if cells is None:
continue
ies_is_added = True
for ie in group_list[ie_name]["ies"]:
if (cells["ie_type"], cells["instance"]) == (ie["ie_type"], ie["instance"]):
ies_is_added = False
for ie in ies:
if (cells["ie_type"], cells["instance"]) == (ie["ie_type"], ie["instance"]):
ies_is_added = False
if ies_is_added is True:
added_ies.append(cells)
write_cells_to_file("added_ies", cells)
group_list_is_added = True
if group_list_is_added is True:
group_list[ie_name] = { "type" : ie_type, "ies" : added_ies }
write_file(f, "group_list[\"" + ie_name + "\"] = { \"type\" : \"" + ie_type + "\", \"ies\" : added_ies }\n")
f.close()
msg_list["PFCP Heartbeat Request"]["table"] = 6
msg_list["PFCP Heartbeat Response"]["table"] = 7
msg_list["PFCP Association Setup Request"]["table"] = 12
msg_list["PFCP Association Setup Response"]["table"] = 13
msg_list["PFCP Association Update Request"]["table"] = 14
msg_list["PFCP Association Update Response"]["table"] = 15
msg_list["PFCP Association Release Request"]["table"] = 16
msg_list["PFCP Association Release Response"]["table"] = 17
msg_list["PFCP Version Not Supported Response"]["table"] = 11
msg_list["PFCP Node Report Request"]["table"] = 18
msg_list["PFCP Node Report Response"]["table"] = 20
msg_list["PFCP Session Set Deletion Request"]["table"] = 21
msg_list["PFCP Session Set Deletion Response"]["table"] = 22
msg_list["PFCP Session Establishment Request"]["table"] = 23
msg_list["PFCP Session Establishment Response"]["table"] = 33
msg_list["PFCP Session Modification Request"]["table"] = 37
msg_list["PFCP Session Modification Response"]["table"] = 51
msg_list["PFCP Session Deletion Request"]["table"] = 53
msg_list["PFCP Session Deletion Response"]["table"] = 54
msg_list["PFCP Session Report Request"]["table"] = 56
msg_list["PFCP Session Report Response"]["table"] = 57
for key in msg_list.keys():
if "table" in msg_list[key].keys():
d_info("[" + key + "]")
cachefile = cachedir + "tlv-msg-" + msg_list[key]["type"] + ".py"
if os.path.isfile(cachefile) and os.access(cachefile, os.R_OK):
execfile(cachefile)
print "Read from " + cachefile
else:
document = Document(filename)
f = open(cachefile, 'w')
ies = []
write_file(f, "ies = []\n")
table = document.tables[msg_list[key]["table"]]
if key.find('Association') != -1:
start_i = 1
elif key.find('Heartbeat') != -1:
start_i = 1
else:
start_i = 2
if key != "PFCP Session Deletion Request": # this msg is null
for row in table.rows[start_i:]:
cells = get_cells(row.cells)
if cells is None:
continue
# 0402
if (cells["ie_type"] == 'Create PDR' or cells["ie_type"] == 'Create FAR' or cells["ie_type"] == 'Update PDR'):
cells["instance"] = '0'
cells["presence"] = 'O'
ies.append(cells)
write_cells_to_file("ies", cells)
cells = get_cells(row.cells)
ies_is_added = True
for ie in ies:
#0403 modify
if (cells["ie_type"], cells["instance"]) == (ie["ie_type"], ie["instance"]):
#if (cells["ie_type"], cells["ie_value"]) == (ie["ie_type"], ie["ie_value"]):
ies_is_added = False
if ies_is_added is True:
ies.append(cells)
write_cells_to_file("ies", cells)
# 0402
#if (cells["ie_type"] == 'Create PDR' or cells["ie_type"] == 'Create FAR' or cells["ie_type"] == 'Update PDR'):
# cells["instance"] = str(int(cells["instance"])+1)
# cells["ie_value"] = cells["ie_value"] + '1'
# cells["presence"] ='O'
# ies.append(cells)
# write_cells_to_file("ies", cells)
msg_list[key]["ies"] = ies
write_file(f, "msg_list[key][\"ies\"] = ies\n")
f.close()
#type_list["Recovery"]["size"] = 1 # Type : 3
#type_list["EBI"]["size"] = 1 # Type : 73
#type_list["RAT Type"]["size"] = 1 # Type : 82
#type_list["PDN Type"]["size"] = 1 # Type : 99
#type_list["Port Number"]["size"] = 2 # Type : 126
#type_list["APN Restriction"]["size"] = 1 # Type : 127
#type_list["Selection Mode"]["size"] = 1 # Type : 128
#type_list["Node Type"]["size"] = 1 # Type : 128
f = open(outdir + 'message.h', 'w')
output_header_to_file(f)
f.write("""#if !defined(OGS_PFCP_INSIDE) && !defined(OGS_PFCP_COMPILATION)
#error "This header cannot be included directly."
#endif
#ifndef OGS_PFCP_MESSAGE_H
#define OGS_PFCP_MESSAGE_H
#ifdef __cplusplus
extern "C" {
#endif
/* 5.1 General format */
#define OGS_PFCP_HEADER_LEN 16
#define OGS_PFCP_SEID_LEN 8
typedef struct ogs_pfcp_header_s {
union {
struct {
ED4(uint8_t version:3;,
uint8_t spare1:3;,
uint8_t mp:1;,
uint8_t seid_p:1;)
};
uint8_t flags;
};
uint8_t type;
uint16_t length;
union {
struct {
uint64_t seid;
/* sqn : 31bit ~ 8bit, spare : 7bit ~ 0bit */
#define OGS_PFCP_XID_TO_SQN(__xid) htonl(((__xid) << 8))
#define OGS_PFCP_SQN_TO_XID(__sqn) (ntohl(__sqn) >> 8)
uint32_t sqn;
};
/* sqn : 31bit ~ 8bit, spare : 7bit ~ 0bit */
uint32_t sqn_only;
};
} __attribute__ ((packed)) ogs_pfcp_header_t;
/* PFCP message type */
""")
tmp = [(k, v["type"]) for k, v in msg_list.items()]
sorted_msg_list = sorted(tmp, key=lambda tup: int(tup[1]))
for (k, v) in sorted_msg_list:
f.write("#define OGS_" + v_upper(k) + "_TYPE " + v + "\n")
f.write("\n")
tmp = [(k, v["type"]) for k, v in type_list.items()]
sorted_type_list = sorted(tmp, key=lambda tup: int(tup[1]))
for (k, v) in sorted_type_list:
f.write("#define OGS_PFCP_" + v_upper(k) + "_TYPE " + v + "\n")
f.write("\n")
f.write("/* Infomration Element TLV Descriptor */\n")
for (k, v) in sorted_type_list:
if k in group_list.keys():
continue
for instance in range(0, int(type_list[k]["max_instance"])+1):
if v_lower(k)=="cause" or v_lower(k)=="sequence_number" or v_lower(k)=="f_teid":
f.write("extern ogs_tlv_desc_t ogs_pfcp_tlv_desc_" + v_lower(k))
else:
f.write("extern ogs_tlv_desc_t ogs_pfcp_tlv_desc_" + v_lower(k))
f.write("_" + str(instance) + ";\n")
f.write("\n")
tmp = [(k, v["type"]) for k, v in group_list.items()]
sorted_group_list = sorted(tmp, key=lambda tup: int(tup[1]), reverse=False)
f.write("/* Group Infomration Element TLV Descriptor */\n")
for (k, v) in sorted_group_list:
for instance in range(0, int(type_list[k]["max_instance"])+1):
f.write("extern ogs_tlv_desc_t ogs_pfcp_tlv_desc_" + v_lower(k))
f.write("_" + str(instance) + ";\n")
f.write("\n")
f.write("/* Message Descriptor */\n")
for (k, v) in sorted_msg_list:
f.write("extern ogs_tlv_desc_t ogs_pfcp_tlv_desc_" + v_lower(k) + ";\n")
f.write("\n")
f.write("/* Structure for Infomration Element */\n")
for (k, v) in sorted_type_list:
if k in group_list.keys():
continue
if "size" in type_list[k]:
if type_list[k]["size"] == 1:
f.write("typedef ogs_tlv_uint8_t ogs_pfcp_tlv_" + v_lower(k) + "_t;\n")
elif type_list[k]["size"] == 2:
f.write("typedef ogs_tlv_uint16_t ogs_pfcp_tlv_" + v_lower(k) + "_t;\n")
elif type_list[k]["size"] == 3:
f.write("typedef ogs_tlv_uint24_t ogs_pfcp_tlv_" + v_lower(k) + "_t;\n")
elif type_list[k]["size"] == 4:
f.write("typedef ogs_tlv_uint32_t ogs_pfcp_tlv_" + v_lower(k) + "_t;\n")
else:
assert False, "Unknown size = %d for key = %s" % (type_list[k]["size"], k)
else:
f.write("typedef ogs_tlv_octet_t ogs_pfcp_tlv_" + v_lower(k) + "_t;\n")
f.write("\n")
#for (k, v) in sorted_group_list:
# f.write("typedef struct _tlv_" + v_lower(k) + "_t ")
# f.write(" tlv_" + v_lower(k) + "_t;\n")
# f.write("\n")
tmp = []
f.write("/* Structure for Group Infomration Element */\n")
for (k, v) in sorted_group_list:
if v_lower(k) == "create_pdr":
tmp.append(k)
continue
if v_lower(k) == "create_far":
tmp.append(k)
continue
if v_lower(k) == "update_far":
tmp.append(k)
continue
if v_lower(k) == "application_id_s_pfds":
tmp.append(k)
continue
f.write("typedef struct ogs_pfcp_tlv_" + v_lower(k) + "_s {\n")
f.write(" ogs_tlv_presence_t presence;\n")
for ies in group_list[k]["ies"]:
f.write(" ogs_pfcp_tlv_" + v_lower(ies["ie_type"]) + "_t " + \
v_lower(ies["ie_value"]))
if ies["ie_type"] == "F-TEID":
if ies["ie_value"] == "S2b-U ePDG F-TEID":
f.write("_" + ies["instance"] + ";")
elif ies["ie_value"] == "S2a-U TWAN F-TEID":
f.write("_" + ies["instance"] + ";")
else:
f.write(";")
f.write(" /* Instance : " + ies["instance"] + " */\n")
else:
f.write(";\n")
f.write("} ogs_pfcp_tlv_" + v_lower(k) + "_t; ;\n")
f.write("\n")
for k in tmp:
f.write("typedef struct ogs_pfcp_tlv_" + v_lower(k) + "_s {\n")
f.write(" tlv_presence_t presence;\n")
for ies in group_list[k]["ies"]:
f.write(" tlv_" + v_lower(ies["ie_type"]) + "_t " + \
v_lower(ies["ie_value"]))
if ies["ie_type"] == "F-TEID":
if ies["ie_value"] == "S2b-U ePDG F-TEID":
f.write("_" + ies["instance"] + ";")
elif ies["ie_value"] == "S2a-U TWAN F-TEID":
f.write("_" + ies["instance"] + ";")
else:
f.write(";")
f.write(" /* Instance : " + ies["instance"] + " */\n")
else:
f.write(";\n")
f.write("} ogs_pfcp_tlv_" + v_lower(k) + "_t; ;\n")
f.write("\n")
f.write("/* Structure for Message */\n")
for (k, v) in sorted_msg_list:
if "ies" in msg_list[k]:
f.write("typedef struct ogs_" + v_lower(k) + "_s {\n")
for ies in msg_list[k]["ies"]:
# 0403 modify
if ies["instance"] != "0":
f.write(" ogs_pfcp_tlv_" + v_lower(ies["ie_type"]) + "_t " + \
v_lower(ies["ie_value"]) + ies["instance"] + ";\n")
else:
f.write(" ogs_pfcp_tlv_" + v_lower(ies["ie_type"]) + "_t " + \
v_lower(ies["ie_value"]) + ";\n")
f.write("} ogs_" + v_lower(k) + "_t;\n")
f.write("\n")
f.write("typedef struct ogs_pfcp_message_s {\n")
f.write(" ogs_pfcp_header_t h;\n")
f.write(" union {\n")
for (k, v) in sorted_msg_list:
if "ies" in msg_list[k]:
f.write(" ogs_" + v_lower(k) + "_t " + v_lower(k) + ";\n");
f.write(" };\n");
f.write("} ogs_pfcp_message_t;\n\n")
f.write("""int ogs_pfcp_parse_msg(ogs_pfcp_message_t *pfcp_message, ogs_pkbuf_t *pkbuf);
ogs_pkbuf_t *ogs_pfcp_build_msg(ogs_pfcp_message_t *pfcp_message);
#ifdef __cplusplus
}
#endif
#endif /* OGS_PFCP_MESSAGE_H */
""")
f.close()
f = open(outdir + 'message.c', 'w')
output_header_to_file(f)
f.write("""#include "ogs-pfcp.h"
""")
for (k, v) in sorted_type_list:
if k in group_list.keys():
continue
for instance in range(0, int(type_list[k]["max_instance"])+1):
if v_lower(k)=="cause" or v_lower(k)=="sequence_number" or v_lower(k)=="f_teid":
f.write("ogs_tlv_desc_t ogs_pfcp_tlv_desc_%s_%d =\n" % (v_lower(k), instance))
else:
f.write("ogs_tlv_desc_t ogs_pfcp_tlv_desc_%s_%d =\n" % (v_lower(k), instance))
f.write("{\n")
if "size" in type_list[k]:
if type_list[k]["size"] == 1:
f.write(" OGS_TLV_UINT8,\n")
elif type_list[k]["size"] == 2:
f.write(" OGS_TLV_UINT16,\n")
elif type_list[k]["size"] == 3:
f.write(" OGS_TLV_UINT24,\n")
elif type_list[k]["size"] == 4:
f.write(" OGS_TLV_UINT32,\n")
else:
assert False, "Unknown size = %d for key = %s" % (type_list[k]["size"], k)
else:
f.write(" OGS_TLV_VAR_STR,\n")
f.write(" \"%s\",\n" % k)
f.write(" OGS_TLV_PFCP_%s_TYPE,\n" % v_upper(k))
if "size" in type_list[k]:
f.write(" %d,\n" % type_list[k]["size"])
else:
f.write(" 0,\n")
f.write(" %d,\n" % instance)
f.write(" sizeof(ogs_pfcp_tlv_%s_t),\n" % v_lower(k))
f.write(" { NULL }\n")
f.write("};\n\n")
for (k, v) in sorted_group_list:
for instance in range(0, int(type_list[k]["max_instance"])+1):
f.write("ogs_tlv_desc_t ogs_pfcp_tlv_desc_%s_%d =\n" % (v_lower(k), instance))
f.write("{\n")
f.write(" OGS_TLV_COMPOUND,\n")
f.write(" \"%s\",\n" % k)
f.write(" OGS_PFCP_%s_TYPE,\n" % v_upper(k))
f.write(" 0,\n")
f.write(" %d,\n" % instance)
f.write(" sizeof(ogs_pfcp_tlv_%s_t),\n" % v_lower(k))
f.write(" {\n")
for ies in group_list[k]["ies"]:
if v_lower(ies["ie_type"])=="cause" or v_lower(ies["ie_type"])=="sequence_number" or v_lower(ies["ie_type"])=="f_teid":
f.write(" &ogs_pfcp_tlv_desc_pfcp%s_%s,\n" % (v_lower(ies["ie_type"]), v_lower(ies["instance"])))
else:
f.write(" &ogs_pfcp_tlv_desc_%s_%s,\n" % (v_lower(ies["ie_type"]), v_lower(ies["instance"])))
f.write(" NULL,\n")
f.write(" }\n")
f.write("};\n\n")
for (k, v) in sorted_msg_list:
if "ies" in msg_list[k]:
f.write("ogs_tlv_desc_t ogs_pfcp_tlv_desc_%s =\n" % v_lower(k))
f.write("{\n")
f.write(" OGS_TLV_MESSAGE,\n")
f.write(" \"%s\",\n" % k)
f.write(" 0, 0, 0, 0, {\n")
for ies in msg_list[k]["ies"]:
if v_lower(ies["ie_type"])=="cause" or v_lower(ies["ie_type"])=="sequence_number" or v_lower(ies["ie_type"])=="f_teid":
f.write(" &ogs_pfcp_tlv_desc_pfcp%s_%s,\n" % (v_lower(ies["ie_type"]), v_lower(ies["instance"])))
else:
f.write(" &ogs_pfcp_tlv_desc_%s_%s,\n" % (v_lower(ies["ie_type"]), v_lower(ies["instance"])))
f.write(" NULL,\n")
f.write("}};\n\n")
f.write("\n")
f.write("""int ogs_pfcp_parse_msg(ogs_pfcp_message_t *pfcp_message, pkbuf_t *pkbuf)
{
int rv = OGS_ERROR;
ogs_pfcp_header_t *h = NULL;
uint16_t size = 0;
ogs_assert(pfcp_message);
ogs_assert(pkbuf);
ogs_assert(pkbuf->len);
h = (ogs_pfcp_header_t *)pkbuf->data;
ogs_assert(h);
memset(pfcp_message, 0, sizeof(ogs_pfcp_message_t));
if (h->seid_p)
size = OGS_PFCP_HEADER_LEN;
else
size = OGS_PFCP_HEADER_LEN-OGS_PFCP_SEID_LEN;
ogs_assert(ogs_pkbuf_pull(pkbuf, size));
memcpy(&pcfp_message->h, pkbuf->data - size, size);
if (h->seid_p) {
pfcp_message->h.seid = be64toh(pfcp_message->h.seid);
} else {
pfcp_message->h.sqn = pfcp_message->h.sqn_only;
pfcp_message->h.sqn_only = pfcp_message->h.sqn_only;
}
if (pkbuf->len == 0)
return OGS_OK;
switch(pfcp_message->h.type)
{
""")
for (k, v) in sorted_msg_list:
if "ies" in msg_list[k]:
f.write(" case OGS_PFCP_%s_TYPE:\n" % v_upper(k))
f.write(" rv = ogs_tlv_parse_msg(&pfcp_message->%s,\n" % v_lower(k))
f.write(" &ogs_pfcp_tlv_desc_%s, pkbuf, TLV_MODE_T2_L2);\n" % v_lower(k))
f.write(" break;\n")
f.write(""" default:
ogs_warn("Not implmeneted(type:%d)", pfcp_message->h.type);
break;
}
return rv;
}
""")
f.write("""ogs_pkbuf_t *ogs_pfcp_build_msg(pfcp_message_t *pfcp_message)
{
ogs_pkbuf_t *pkbuf = NULL;
ogs_assert(pfcp_message);
switch(pfcp_message->h.type)
{
""")
for (k, v) in sorted_msg_list:
if "ies" in msg_list[k]:
f.write(" case OGS_PFCP_%s_TYPE:\n" % v_upper(k))
f.write(" pkbuf = ogs_tlv_build_msg(&tlv_desc_%s,\n" % v_lower(k))
f.write(" &pfcp_message->%s, TLV_MODE_T2_L2);\n" % v_lower(k))
f.write(" break;\n")
f.write(""" default:
ogs_warn("Not implmeneted(type:%d)", pfcp_message->h.type);
break;
}
return pkbuf;
}
""")
f.write("\n")
f.close()