feat: support configuring local IP address for N9 interface with N3 address by default #585
Add this suggestion to a batch that can be applied as a single commit.
This suggestion is invalid because no changes were made to the code.
Suggestions cannot be applied while the pull request is closed.
Suggestions cannot be applied while viewing a subset of changes.
Only one suggestion per line can be applied in a batch.
Add this suggestion to a batch that can be applied as a single commit.
Applying suggestions on deleted lines is not supported.
You must change the existing code in this line in order to create a valid suggestion.
Outdated suggestions cannot be applied.
This suggestion has been applied or marked resolved.
Suggestions cannot be applied from pending reviews.
Suggestions cannot be applied on multi-line comments.
Suggestions cannot be applied while the pull request is queued to merge.
Suggestion cannot be applied right now. Please check back later.
Based on #583
Until now, eupf only allowed configuring the local IP address for the N3 interface, which actually ended up being used for both N3 and N9 (GTP-U forwarding towards other uplink UPFs).
However, that limitation becomes a problem under some production scenarios. Some users require running a UPF to forward GTPv1U traffic from network A to network B and viceversa, where those 2 networks are not reachable to each other, only through the UPF host.
This happens for instance when cellular operators don't control/own the entirety of their networks, e.g. a network which runs their NAT under a satellite link with private addresses (eg VPN) which end up at a single host.
As a result, the UPF requires managing at least 2 separate local IP addresses for GTP-U traffic: One (usually private) IP address towards the RAN, and one (usually public, or another private network) IP address towards the Core. As a result, when a PFCP client (an SMF, or osmo-hnbgw, or osmo-s1gw to mention some other examples) tries to setup a session to forward GTPU traffic from network A (RAN) to network B (Core), will result in eUPF forwarding the GTP-U packet to the Core but using the RAN configured IP as the GTPU packet local IP address.
Hence, either local routing will be wrong, or the Core will drop the received packet, or won't know how to route traffic back to it.
This patch allows eupf to be used co-located with 3G osmo-hnbgw [1] and 4G osmo-s1gw [2] under the mentioned network setups, both supporting PFCP to manage a UPF to forward data plane also in GTP1U protocol.
[1] https://osmocom.org/projects/osmohnbgw
[2] https://gitea.osmocom.org/erlang/osmo-s1gw
Related: #577