|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
#include "event.h" |
|
|
#include "context.h" |
|
|
#include "gtp-path.h" |
|
|
#include "fd-path.h" |
|
|
#include "gn-build.h" |
|
|
#include "gn-handler.h" |
|
|
#include "n4-handler.h" |
|
|
#include "pfcp-path.h" |
|
|
|
|
|
#include "ipfw/ipfw2.h" |
|
|
|
|
|
void smf_gn_handle_echo_request( |
|
|
ogs_gtp_xact_t *xact, ogs_gtp1_echo_request_t *req) |
|
|
{ |
|
|
ogs_assert(xact); |
|
|
ogs_assert(req); |
|
|
|
|
|
ogs_debug("[PGW] Receiving Echo Request"); |
|
|
|
|
|
ogs_gtp1_send_echo_response(xact, 0); |
|
|
} |
|
|
|
|
|
void smf_gn_handle_echo_response( |
|
|
ogs_gtp_xact_t *xact, ogs_gtp1_echo_response_t *req) |
|
|
{ |
|
|
|
|
|
} |
|
|
|
|
|
uint8_t smf_gn_handle_create_pdp_context_request( |
|
|
smf_sess_t *sess, ogs_gtp_xact_t *xact, |
|
|
ogs_gtp1_create_pdp_context_request_t *req) |
|
|
{ |
|
|
char buf1[OGS_ADDRSTRLEN]; |
|
|
char buf2[OGS_ADDRSTRLEN]; |
|
|
|
|
|
int rv; |
|
|
uint8_t cause_value = 0; |
|
|
uint8_t pfcp_cause; |
|
|
|
|
|
ogs_gtp1_uli_t uli; |
|
|
|
|
|
smf_ue_t *smf_ue = NULL; |
|
|
ogs_eua_t *eua = NULL; |
|
|
smf_bearer_t *bearer = NULL; |
|
|
ogs_gtp1_qos_profile_decoded_t *qos_pdec; |
|
|
uint8_t qci = 9; |
|
|
|
|
|
ogs_assert(sess); |
|
|
ogs_assert(xact); |
|
|
ogs_assert(req); |
|
|
|
|
|
ogs_debug("Create PDP Context Request"); |
|
|
|
|
|
cause_value = OGS_GTP1_CAUSE_REQUEST_ACCEPTED; |
|
|
|
|
|
if (req->imsi.presence == 0) { |
|
|
ogs_error("No IMSI"); |
|
|
cause_value = OGS_GTP1_CAUSE_MANDATORY_IE_MISSING; |
|
|
} |
|
|
if (req->selection_mode.presence == 0) { |
|
|
ogs_error("No Selection Mode"); |
|
|
cause_value = OGS_GTP1_CAUSE_MANDATORY_IE_MISSING; |
|
|
} |
|
|
if (req->tunnel_endpoint_identifier_data_i.presence == 0) { |
|
|
ogs_error("No TEID"); |
|
|
cause_value = OGS_GTP1_CAUSE_MANDATORY_IE_MISSING; |
|
|
} |
|
|
if (req->nsapi.presence == 0) { |
|
|
ogs_error("No NSAPI"); |
|
|
cause_value = OGS_GTP1_CAUSE_MANDATORY_IE_MISSING; |
|
|
} |
|
|
if (req->sgsn_address_for_signalling.presence == 0) { |
|
|
ogs_error("No SGSN Address for signalling"); |
|
|
cause_value = OGS_GTP1_CAUSE_MANDATORY_IE_MISSING; |
|
|
} |
|
|
if (req->sgsn_address_for_user_traffic.presence == 0) { |
|
|
ogs_error("No SGSN Address for user traffic"); |
|
|
cause_value = OGS_GTP1_CAUSE_MANDATORY_IE_MISSING; |
|
|
} |
|
|
if (req->msisdn.presence == 0) { |
|
|
ogs_error("No MSISDN"); |
|
|
cause_value = OGS_GTP1_CAUSE_MANDATORY_IE_MISSING; |
|
|
} |
|
|
if (req->quality_of_service_profile.presence == 0) { |
|
|
ogs_error("No QoS Profile"); |
|
|
cause_value = OGS_GTP1_CAUSE_MANDATORY_IE_MISSING; |
|
|
} |
|
|
if (req->user_location_information.presence == 0) { |
|
|
ogs_error("No User Location Info"); |
|
|
cause_value = OGS_GTP1_CAUSE_MANDATORY_IE_MISSING; |
|
|
} |
|
|
|
|
|
if (!ogs_diam_app_connected(OGS_DIAM_GX_APPLICATION_ID)) { |
|
|
ogs_error("No Gx Diameter Peer"); |
|
|
cause_value = OGS_GTP1_CAUSE_NO_RESOURCES_AVAILABLE; |
|
|
} |
|
|
|
|
|
if (cause_value != OGS_GTP1_CAUSE_REQUEST_ACCEPTED) |
|
|
return cause_value; |
|
|
|
|
|
smf_ue = smf_ue_find_by_id(sess->smf_ue_id); |
|
|
ogs_assert(smf_ue); |
|
|
|
|
|
|
|
|
sess->gtp.v1.nsapi = req->nsapi.u8; |
|
|
|
|
|
sess->gtp.selection_mode = req->selection_mode.u8 & 0x03; |
|
|
if (sess->gtp.selection_mode > 2) |
|
|
sess->gtp.selection_mode = 2; |
|
|
|
|
|
if (req->charging_characteristics.presence) { |
|
|
OGS_TLV_STORE_DATA(&sess->gtp.charging_characteristics, &req->charging_characteristics); |
|
|
} |
|
|
|
|
|
|
|
|
sess->sgw_s5c_teid = req->tunnel_endpoint_identifier_control_plane.u32; |
|
|
rv = ogs_gtp1_gsn_addr_to_ip(req->sgsn_address_for_signalling.data, |
|
|
req->sgsn_address_for_signalling.len, |
|
|
&sess->sgw_s5c_ip); |
|
|
ogs_assert(rv == OGS_OK); |
|
|
ogs_debug(" SGW_S5C_TEID[0x%x] SMF_N4_TEID[0x%x]", |
|
|
sess->sgw_s5c_teid, sess->smf_n4_teid); |
|
|
|
|
|
|
|
|
|
|
|
OGS_TLV_STORE_DATA(&sess->gtp.user_location_information, |
|
|
&req->user_location_information); |
|
|
if (ogs_gtp1_parse_uli(&uli, &req->user_location_information) == 0) |
|
|
return OGS_GTP1_CAUSE_MANDATORY_IE_INCORRECT; |
|
|
|
|
|
switch (uli.geo_loc_type) { |
|
|
case OGS_GTP1_GEO_LOC_TYPE_CGI: |
|
|
ogs_nas_to_plmn_id(&sess->serving_plmn_id, &uli.cgi.nas_plmn_id); |
|
|
break; |
|
|
case OGS_GTP1_GEO_LOC_TYPE_SAI: |
|
|
ogs_nas_to_plmn_id(&sess->serving_plmn_id, &uli.sai.nas_plmn_id); |
|
|
break; |
|
|
case OGS_GTP1_GEO_LOC_TYPE_RAI: |
|
|
ogs_nas_to_plmn_id(&sess->serving_plmn_id, &uli.rai.nas_plmn_id); |
|
|
break; |
|
|
|
|
|
} |
|
|
|
|
|
|
|
|
|
|
|
|
|
|
if (req->msisdn.len == 0 || |
|
|
(req->msisdn.len - 1) > sizeof(smf_ue->msisdn)) { |
|
|
ogs_error("MSISDN wrong size %u > %zu", |
|
|
(req->msisdn.len - 1), sizeof(smf_ue->msisdn)); |
|
|
return OGS_GTP1_CAUSE_MANDATORY_IE_INCORRECT; |
|
|
} |
|
|
smf_ue->msisdn_len = req->msisdn.len - 1; |
|
|
if (smf_ue->msisdn_len > 0) { |
|
|
memcpy(smf_ue->msisdn, |
|
|
(uint8_t*)req->msisdn.data + 1, smf_ue->msisdn_len); |
|
|
ogs_buffer_to_bcd( |
|
|
smf_ue->msisdn, smf_ue->msisdn_len, smf_ue->msisdn_bcd); |
|
|
} |
|
|
|
|
|
|
|
|
if (req->common_flags.presence) { |
|
|
sess->gtp.v1.common_flags = *(ogs_gtp1_common_flags_t*)req->common_flags.data; |
|
|
} |
|
|
|
|
|
|
|
|
sess->session.ambr.downlink = 100000000; |
|
|
sess->session.ambr.uplink = 100000000; |
|
|
|
|
|
|
|
|
OGS_TLV_STORE_DATA(&sess->gtp.v1.qos, &req->quality_of_service_profile); |
|
|
qos_pdec = &sess->gtp.v1.qos_pdec; |
|
|
rv = ogs_gtp1_parse_qos_profile(qos_pdec, &req->quality_of_service_profile); |
|
|
if(rv < 0) |
|
|
return OGS_GTP1_CAUSE_MANDATORY_IE_INCORRECT; |
|
|
|
|
|
|
|
|
|
|
|
|
|
|
ogs_gtp1_qos_profile_to_qci(qos_pdec, &qci); |
|
|
sess->session.qos.index = qci; |
|
|
sess->session.qos.arp.priority_level = qos_pdec->qos_profile.arp; |
|
|
sess->session.qos.arp.pre_emption_capability = 0; |
|
|
sess->session.qos.arp.pre_emption_vulnerability = 0; |
|
|
if (qos_pdec->data_octet6_to_13_present) { |
|
|
sess->session.ambr.downlink = qos_pdec->dec_mbr_kbps_dl * 1000; |
|
|
sess->session.ambr.uplink = qos_pdec->dec_mbr_kbps_ul * 1000; |
|
|
} |
|
|
|
|
|
|
|
|
if (req->apn_ambr.presence) { |
|
|
|
|
|
|
|
|
|
|
|
sess->gtp.v1.peer_supports_apn_ambr = true; |
|
|
if (req->apn_ambr.len >= sizeof(ogs_gtp1_apn_ambr_t)) { |
|
|
ogs_gtp1_apn_ambr_t *ambr = req->apn_ambr.data; |
|
|
sess->session.ambr.uplink = be32toh(ambr->uplink) * 1000; |
|
|
sess->session.ambr.downlink = be32toh(ambr->downlink) * 1000; |
|
|
} |
|
|
} |
|
|
|
|
|
|
|
|
if (req->protocol_configuration_options.presence) { |
|
|
OGS_TLV_STORE_DATA(&sess->gtp.ue_pco, |
|
|
&req->protocol_configuration_options); |
|
|
} |
|
|
|
|
|
|
|
|
if (req->ms_time_zone.presence) { |
|
|
|
|
|
OGS_TLV_STORE_DATA(&sess->gtp.ue_timezone, &req->ms_time_zone); |
|
|
} |
|
|
|
|
|
|
|
|
if (req->imei.presence && req->imei.len > 0) { |
|
|
smf_ue->imeisv_len = req->imei.len; |
|
|
memcpy(smf_ue->imeisv, |
|
|
(uint8_t*)req->imei.data, smf_ue->imeisv_len); |
|
|
ogs_buffer_to_bcd( |
|
|
smf_ue->imeisv, smf_ue->imeisv_len, smf_ue->imeisv_bcd); |
|
|
} |
|
|
|
|
|
|
|
|
eua = req->end_user_address.data; |
|
|
ogs_assert(eua); |
|
|
rv = ogs_gtp1_eua_to_ip(eua, req->end_user_address.len, &sess->session.ue_ip, |
|
|
&sess->ue_session_type); |
|
|
if(rv != OGS_OK) |
|
|
return OGS_GTP1_CAUSE_MANDATORY_IE_INCORRECT; |
|
|
|
|
|
|
|
|
sess->session.session_type = sess->ue_session_type; |
|
|
|
|
|
|
|
|
smf_bearer_remove_all(sess); |
|
|
|
|
|
|
|
|
bearer = smf_bearer_add(sess); |
|
|
ogs_assert(bearer); |
|
|
|
|
|
|
|
|
|
|
|
|
|
|
bearer->ebi = req->nsapi.u8; |
|
|
|
|
|
|
|
|
bearer->sgw_s5u_teid = req->tunnel_endpoint_identifier_data_i.u32; |
|
|
rv = ogs_gtp1_gsn_addr_to_ip(req->sgsn_address_for_user_traffic.data, |
|
|
req->sgsn_address_for_user_traffic.len, |
|
|
&bearer->sgw_s5u_ip); |
|
|
ogs_assert(rv == OGS_OK); |
|
|
ogs_debug(" SGW_S5U_TEID[0x%x] PGW_S5U_TEID[0x%x]", |
|
|
bearer->sgw_s5u_teid, bearer->pgw_s5u_teid); |
|
|
if (qos_pdec->data_octet6_to_13_present) { |
|
|
bearer->qos.gbr.downlink = qos_pdec->dec_gbr_kbps_dl * 1000; |
|
|
bearer->qos.gbr.uplink = qos_pdec->dec_gbr_kbps_ul * 1000; |
|
|
} else { |
|
|
|
|
|
bearer->qos.gbr.downlink = sess->session.ambr.downlink; |
|
|
bearer->qos.gbr.uplink = sess->session.ambr.uplink; |
|
|
} |
|
|
|
|
|
|
|
|
smf_sess_select_upf(sess); |
|
|
|
|
|
|
|
|
ogs_assert(sess->pfcp_node); |
|
|
if (!OGS_FSM_CHECK(&sess->pfcp_node->sm, smf_pfcp_state_associated)) |
|
|
return OGS_GTP1_CAUSE_NO_RESOURCES_AVAILABLE; |
|
|
|
|
|
if ((pfcp_cause = smf_sess_set_ue_ip(sess)) != OGS_PFCP_CAUSE_REQUEST_ACCEPTED) { |
|
|
cause_value = gtp_cause_from_pfcp(pfcp_cause, 1); |
|
|
return cause_value; |
|
|
} |
|
|
|
|
|
ogs_info("UE IMSI[%s] APN[%s] IPv4[%s] IPv6[%s]", |
|
|
smf_ue->imsi_bcd, |
|
|
sess->session.name, |
|
|
sess->ipv4 ? OGS_INET_NTOP(&sess->ipv4->addr, buf1) : "", |
|
|
sess->ipv6 ? OGS_INET6_NTOP(&sess->ipv6->addr, buf2) : ""); |
|
|
|
|
|
return cause_value; |
|
|
} |
|
|
|
|
|
uint8_t smf_gn_handle_delete_pdp_context_request( |
|
|
smf_sess_t *sess, ogs_gtp_xact_t *xact, |
|
|
ogs_gtp1_delete_pdp_context_request_t *req) |
|
|
{ |
|
|
ogs_debug("Delete PDP Context Request"); |
|
|
|
|
|
if (!ogs_diam_app_connected(OGS_DIAM_GX_APPLICATION_ID)) { |
|
|
ogs_error("No Gx Diameter Peer"); |
|
|
return OGS_GTP1_CAUSE_NO_RESOURCES_AVAILABLE; |
|
|
} |
|
|
|
|
|
|
|
|
if (req->protocol_configuration_options.presence) { |
|
|
OGS_TLV_STORE_DATA(&sess->gtp.ue_pco, |
|
|
&req->protocol_configuration_options); |
|
|
} else { |
|
|
|
|
|
|
|
|
|
|
|
|
|
|
OGS_TLV_CLEAR_DATA(&sess->gtp.ue_pco); |
|
|
} |
|
|
|
|
|
ogs_debug(" SGW_S5C_TEID[0x%x] SMF_N4_TEID[0x%x]", |
|
|
sess->sgw_s5c_teid, sess->smf_n4_teid); |
|
|
return OGS_GTP1_CAUSE_REQUEST_ACCEPTED; |
|
|
} |
|
|
|
|
|
void smf_gn_handle_update_pdp_context_request( |
|
|
smf_sess_t *sess, ogs_gtp_xact_t *xact, |
|
|
ogs_gtp1_update_pdp_context_request_t *req) |
|
|
{ |
|
|
int rv; |
|
|
uint8_t cause_value = OGS_GTP1_CAUSE_REQUEST_ACCEPTED; |
|
|
|
|
|
ogs_gtp1_header_t h; |
|
|
ogs_pfcp_pdr_t *pdr = NULL; |
|
|
smf_bearer_t *bearer = NULL; |
|
|
smf_ue_t *smf_ue = NULL; |
|
|
ogs_gtp1_qos_profile_decoded_t *qos_pdec; |
|
|
uint8_t qci; |
|
|
|
|
|
ogs_debug("Update PDP Context Request"); |
|
|
|
|
|
ogs_assert(xact); |
|
|
ogs_assert(req); |
|
|
|
|
|
if (req->nsapi.presence == 0) { |
|
|
ogs_error("No NSAPI"); |
|
|
cause_value = OGS_GTP1_CAUSE_MANDATORY_IE_MISSING; |
|
|
} |
|
|
if (req->tunnel_endpoint_identifier_data_i.presence == 0) { |
|
|
ogs_error("No TEID"); |
|
|
cause_value = OGS_GTP1_CAUSE_MANDATORY_IE_MISSING; |
|
|
} |
|
|
if (req->sgsn_address_for_control_plane.presence == 0) { |
|
|
ogs_error("SGSN Address for signalling"); |
|
|
cause_value = OGS_GTP1_CAUSE_MANDATORY_IE_MISSING; |
|
|
} |
|
|
if (req->sgsn_address_for_user_traffic.presence == 0) { |
|
|
ogs_error("SGSN Address for user traffic"); |
|
|
cause_value = OGS_GTP1_CAUSE_MANDATORY_IE_MISSING; |
|
|
} |
|
|
if (req->quality_of_service_profile.presence == 0) { |
|
|
ogs_error("No QoS Profile"); |
|
|
cause_value = OGS_GTP1_CAUSE_MANDATORY_IE_MISSING; |
|
|
} |
|
|
|
|
|
if (!sess) { |
|
|
ogs_warn("No Context"); |
|
|
cause_value = OGS_GTP1_CAUSE_NON_EXISTENT; |
|
|
} |
|
|
|
|
|
if (cause_value != OGS_GTP1_CAUSE_REQUEST_ACCEPTED) { |
|
|
ogs_gtp1_send_error_message(xact, sess ? sess->sgw_s5c_teid : 0, |
|
|
OGS_GTP1_UPDATE_PDP_CONTEXT_RESPONSE_TYPE, cause_value); |
|
|
return; |
|
|
} |
|
|
|
|
|
ogs_assert(sess); |
|
|
smf_ue = smf_ue_find_by_id(sess->smf_ue_id); |
|
|
ogs_assert(smf_ue); |
|
|
|
|
|
ogs_debug(" SGW_S5C_TEID[0x%x] SMF_N4_TEID[0x%x]", |
|
|
sess->sgw_s5c_teid, sess->smf_n4_teid); |
|
|
|
|
|
bearer = smf_bearer_find_by_ebi(sess, req->nsapi.u8); |
|
|
if (!bearer) { |
|
|
ogs_warn("No bearer with id %u, taking default", req->nsapi.u8); |
|
|
bearer = smf_default_bearer_in_sess(sess); |
|
|
if (!bearer) { |
|
|
ogs_warn("No bearer"); |
|
|
ogs_gtp1_send_error_message(xact, sess->sgw_s5c_teid, |
|
|
OGS_GTP1_UPDATE_PDP_CONTEXT_RESPONSE_TYPE, |
|
|
OGS_GTP1_CAUSE_NON_EXISTENT); |
|
|
return; |
|
|
} |
|
|
} |
|
|
|
|
|
|
|
|
if (req->common_flags.presence) { |
|
|
sess->gtp.v1.common_flags = *(ogs_gtp1_common_flags_t*)req->common_flags.data; |
|
|
} else { |
|
|
|
|
|
sess->gtp.v1.common_flags = (ogs_gtp1_common_flags_t){0}; |
|
|
} |
|
|
|
|
|
|
|
|
if (req->tunnel_endpoint_identifier_control_plane.presence) { |
|
|
sess->sgw_s5c_teid = req->tunnel_endpoint_identifier_control_plane.u32; |
|
|
rv = ogs_gtp1_gsn_addr_to_ip(req->sgsn_address_for_control_plane.data, |
|
|
req->sgsn_address_for_control_plane.len, |
|
|
&sess->sgw_s5c_ip); |
|
|
ogs_assert(rv == OGS_OK); |
|
|
ogs_debug(" Updated SGW_S5C_TEID[0x%x] SMF_N4_TEID[0x%x]", |
|
|
sess->sgw_s5c_teid, sess->smf_n4_teid); |
|
|
} |
|
|
|
|
|
|
|
|
bearer->sgw_s5u_teid = req->tunnel_endpoint_identifier_data_i.u32; |
|
|
rv = ogs_gtp1_gsn_addr_to_ip(req->sgsn_address_for_user_traffic.data, |
|
|
req->sgsn_address_for_user_traffic.len, |
|
|
&bearer->sgw_s5u_ip); |
|
|
ogs_assert(rv == OGS_OK); |
|
|
ogs_debug(" Updated SGW_S5U_TEID[0x%x] PGW_S5U_TEID[0x%x]", |
|
|
bearer->sgw_s5u_teid, bearer->pgw_s5u_teid); |
|
|
|
|
|
|
|
|
|
|
|
OGS_TLV_STORE_DATA(&sess->gtp.v1.qos, &req->quality_of_service_profile); |
|
|
qos_pdec = &sess->gtp.v1.qos_pdec; |
|
|
rv = ogs_gtp1_parse_qos_profile(qos_pdec, &req->quality_of_service_profile); |
|
|
if(rv < 0) { |
|
|
ogs_gtp1_send_error_message(xact, sess->sgw_s5c_teid, |
|
|
OGS_GTP1_UPDATE_PDP_CONTEXT_RESPONSE_TYPE, |
|
|
OGS_GTP1_CAUSE_MANDATORY_IE_INCORRECT); |
|
|
return; |
|
|
} |
|
|
|
|
|
|
|
|
|
|
|
|
|
|
ogs_gtp1_qos_profile_to_qci(qos_pdec, &qci); |
|
|
sess->session.qos.index = qci; |
|
|
sess->session.qos.arp.priority_level = qos_pdec->qos_profile.arp; |
|
|
sess->session.qos.arp.pre_emption_capability = 0; |
|
|
sess->session.qos.arp.pre_emption_vulnerability = 0; |
|
|
if (qos_pdec->data_octet6_to_13_present) { |
|
|
sess->session.ambr.downlink = qos_pdec->dec_mbr_kbps_dl * 1000; |
|
|
sess->session.ambr.uplink = qos_pdec->dec_mbr_kbps_ul * 1000; |
|
|
} |
|
|
|
|
|
|
|
|
if (req->apn_ambr.presence) { |
|
|
|
|
|
|
|
|
|
|
|
sess->gtp.v1.peer_supports_apn_ambr = true; |
|
|
if (req->apn_ambr.len >= sizeof(ogs_gtp1_apn_ambr_t)) { |
|
|
ogs_gtp1_apn_ambr_t *ambr = req->apn_ambr.data; |
|
|
sess->session.ambr.uplink = be32toh(ambr->uplink) * 1000; |
|
|
sess->session.ambr.downlink = be32toh(ambr->downlink) * 1000; |
|
|
} |
|
|
} |
|
|
|
|
|
|
|
|
if (req->protocol_configuration_options.presence) { |
|
|
OGS_TLV_STORE_DATA(&sess->gtp.ue_pco, |
|
|
&req->protocol_configuration_options); |
|
|
} else { |
|
|
|
|
|
|
|
|
|
|
|
|
|
|
OGS_TLV_CLEAR_DATA(&sess->gtp.ue_pco); |
|
|
} |
|
|
|
|
|
memset(&h, 0, sizeof(ogs_gtp2_header_t)); |
|
|
h.type = OGS_GTP1_UPDATE_PDP_CONTEXT_RESPONSE_TYPE; |
|
|
h.teid = sess->sgw_s5c_teid; |
|
|
|
|
|
|
|
|
xact->data = OGS_UINT_TO_POINTER(bearer->id); |
|
|
|
|
|
|
|
|
|
|
|
|
|
|
ogs_list_for_each(&sess->pfcp.pdr_list, pdr) { |
|
|
ogs_pfcp_far_t *far = pdr->far; |
|
|
ogs_assert(far); |
|
|
|
|
|
if (pdr->src_if != OGS_PFCP_INTERFACE_CORE || |
|
|
far->dst_if != OGS_PFCP_INTERFACE_ACCESS) |
|
|
continue; |
|
|
if (!(far->apply_action & OGS_PFCP_APPLY_ACTION_FORW)) |
|
|
continue; |
|
|
|
|
|
if (pdr->id == bearer->dl_pdr->id) { |
|
|
rv = ogs_pfcp_ip_to_outer_header_creation(&bearer->sgw_s5u_ip, |
|
|
&far->outer_header_creation, |
|
|
&far->outer_header_creation_len); |
|
|
ogs_assert(rv == OGS_OK); |
|
|
far->outer_header_creation.teid = bearer->sgw_s5u_teid; |
|
|
} |
|
|
} |
|
|
|
|
|
rv = smf_epc_pfcp_send_all_pdr_modification_request(sess, xact->id, NULL, |
|
|
OGS_PFCP_MODIFY_DL_ONLY|OGS_PFCP_MODIFY_ACTIVATE, |
|
|
OGS_NAS_PROCEDURE_TRANSACTION_IDENTITY_UNASSIGNED, |
|
|
OGS_GTP1_CAUSE_REACTIACTION_REQUESTED); |
|
|
ogs_assert(rv == OGS_OK); |
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
} |
|
|
|