-
Notifications
You must be signed in to change notification settings - Fork 20
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
feat: Support Traffic Steering for Service Function Chaining #549
base: main
Are you sure you want to change the base?
Conversation
cmd/core/pfcp_session_handlers.go
Outdated
@@ -480,6 +481,16 @@ func composeFarInfo(far *ie.IE, localIp net.IP, farInfo ebpf.FarInfo) (ebpf.FarI | |||
return ebpf.FarInfo{}, fmt.Errorf("IPv6 not supported yet") | |||
} | |||
} | |||
forwardingPolicyIndex := findIEindex(forward, 41) // IE Type Outer Header Creation |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Copy-past typo in comment
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Thanks for picking this up, I have updated the comment.
cmd/ebpf/pdr.go
Outdated
RemoteIP uint32 | ||
LocalIP uint32 | ||
TransportLevelMarking uint16 | ||
ForwardingPolicyIdentifier uint64 |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Is uint64 type actually needed here, if just u32 argument in passed to add_nsh_over_ip4_headers
static __always_inline __u32 add_nsh_over_ip4_headers(struct packet_context *ctx, __u32 path_hdr)
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Correct, uint64 is not need, even other protocols have tags less that uint32. I have updated all the occurrences of ForwardingPolicyIdentifier and tested again.
* Copy-past typo in comment * UInt64 not needed, tags are UInt32
… into traffic_steering
Thanks @pirog-spb for the comments, I have updated the code. |
Checking up on this PR. Will it be better to have a plugin support for features like this? Don't know much about coding but just a thought that came to my mind, so you can keep eupf code separately and the management of the plugins will be handled by individual contributors. What do you think @tariromukute and @pirog-spb ? |
Firstly, thank you for this project!
This pull request introduces support for Traffic Steering within the Service Function Chaining (SFC) framework. This enables the User Plane Function (UPF) to:
The traffic steering implementation enables the N6-LAN for perform Service Function Chaining on the traffic after it leaves the UPF but before the internet. Checkout the OpenN6LAN project.
Key Changes:
Testing:
The changes can be tested by setting up the eUPF and installing FAR rules with forwarding policy identifiers. Please see below. The setup is depicted below, along with the files for setting up the environment for test.
sessions-eupf.yaml
in the docker compose below