Description:
The N6 PDI (Packet Detection Information) should not include a bogus S1-U interface type. Currently, the source interface type is being set unconditionally, which causes issues when creating PDIs for certain edge types.
Problem:
In src/smf_app/smf_procedure.cpp, the pdi.set(source_interface_type) is called without checking if a valid interface type has been set for the edge. This means the N6 PDI may carry an invalid S1-U interface type.
Solution:
Implement a conditional check using a flag (e.g., have_interface_type) to only set the source interface type in the PDI when it has been explicitly set for valid edge types (N3 3GPP Access and N9).
Suggested Implementation:
bool have_interface_type = false;
if (edge->type == n3_type) {
// TS 29.244 Table 8.2.118-1: 11 = N3 3GPP Access.
// 14 (N3 for data forwarding) is for indirect forwarding tunnels only.
source_interface_type.interface_type_value =
pfcp::_3GPP_INTERFACE_TYPE_N3_3GPP_ACCESS;
have_interface_type = true;
} else if (edge->type == n9_type) {
source_interface_type.interface_type_value = pfcp::_3GPP_INTERFACE_TYPE_N9;
have_interface_type = true;
}
// Later, when setting PDI:
if (have_interface_type) {
pdi.set(source_interface_type);
}
File: src/smf_app/smf_procedure.cpp
Description:
The N6 PDI (Packet Detection Information) should not include a bogus S1-U interface type. Currently, the source interface type is being set unconditionally, which causes issues when creating PDIs for certain edge types.
Problem:
In
src/smf_app/smf_procedure.cpp, thepdi.set(source_interface_type)is called without checking if a valid interface type has been set for the edge. This means the N6 PDI may carry an invalid S1-U interface type.Solution:
Implement a conditional check using a flag (e.g.,
have_interface_type) to only set the source interface type in the PDI when it has been explicitly set for valid edge types (N3 3GPP Access and N9).Suggested Implementation:
File:
src/smf_app/smf_procedure.cpp