Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

The DLFAR of pfcp session est req must includes forwardingParameter #61

Merged
merged 1 commit into from
Sep 26, 2022
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
9 changes: 5 additions & 4 deletions internal/context/datapath.go
Original file line number Diff line number Diff line change
Expand Up @@ -528,11 +528,12 @@ func (dataPath *DataPath) ActivateTunnelAndPDR(smContext *SMContext, precedence
}
}
} else {
ANUPF := dataPath.FirstDPNode
DLPDR := ANUPF.DownLinkTunnel.PDR
DLFAR := DLPDR.FAR
DLFAR.ForwardingParameters = new(ForwardingParameters)
DLFAR.ForwardingParameters.DestinationInterface.InterfaceValue = pfcpType.DestinationInterfaceAccess
if anIP := smContext.Tunnel.ANInformation.IPAddress; anIP != nil {
ANUPF := dataPath.FirstDPNode
DLPDR := ANUPF.DownLinkTunnel.PDR
DLFAR := DLPDR.FAR
DLFAR.ForwardingParameters = new(ForwardingParameters)
DLFAR.ForwardingParameters.DestinationInterface.InterfaceValue = pfcpType.DestinationInterfaceAccess
DLFAR.ForwardingParameters.NetworkInstance = &pfcpType.NetworkInstance{NetworkInstance: smContext.Dnn}
DLFAR.ForwardingParameters.OuterHeaderCreation = new(pfcpType.OuterHeaderCreation)
Expand Down
12 changes: 11 additions & 1 deletion internal/pfcp/message/build.go
Original file line number Diff line number Diff line change
Expand Up @@ -111,7 +111,17 @@ func farToCreateFAR(far *context.FAR) *pfcp.CreateFAR {
createFAR.FARID.FarIdValue = far.FARID

createFAR.ApplyAction = new(pfcpType.ApplyAction)
createFAR.ApplyAction.Forw = true
if far.ForwardingParameters != nil {
createFAR.ApplyAction.Forw = true
} else {
/*
29.244 v15.3 Table 7.5.2.3-1
Farwarding Parameters IE shall be present when the Apply-Action requests the packets to be forwarded.
*/
// FAR without Farwarding Parameters set Apply Action as Drop instead of Forward.
createFAR.ApplyAction.Forw = false
createFAR.ApplyAction.Drop = true
}

if far.BAR != nil {
createFAR.BARID = new(pfcpType.BARID)
Expand Down