neels has uploaded this change for review. ( https://gerrit.osmocom.org/c/osmo-upf/+/30493 ) Change subject: nft: rewrite source IP in outgoing GTP-U ...................................................................... nft: rewrite source IP in outgoing GTP-U Change-Id: I6d293c1dc69d1bab714564f48e3f85b769501d13 --- M src/osmo-upf/upf_nft.c 1 file changed, 4 insertions(+), 0 deletions(-) git pull ssh://gerrit.osmocom.org:29418/osmo-upf refs/changes/93/30493/1 diff --git a/src/osmo-upf/upf_nft.c b/src/osmo-upf/upf_nft.c index 695ec20..a8ca90d 100644 --- a/src/osmo-upf/upf_nft.c +++ b/src/osmo-upf/upf_nft.c @@ -136,6 +136,10 @@ /* Match on the TEID in the header */ OSMO_STRBUF_PRINTF(sb, " @ih,32,32 0x%08x", from_peer->teid_local); + /* Change outgoing address to local IP on outgoing interface */ + OSMO_STRBUF_PRINTF(sb, " ip saddr set "); + OSMO_STRBUF_APPEND(sb, osmo_sockaddr_to_str_buf2, to_peer->addr_local); + /* Change destination address to to_peer */ OSMO_STRBUF_PRINTF(sb, " ip daddr set "); OSMO_STRBUF_APPEND(sb, osmo_sockaddr_to_str_buf2, to_peer->addr_remote); -- To view, visit https://gerrit.osmocom.org/c/osmo-upf/+/30493 To unsubscribe, or for help writing mail filters, visit https://gerrit.osmocom.org/settings Gerrit-Project: osmo-upf Gerrit-Branch: master Gerrit-Change-Id: I6d293c1dc69d1bab714564f48e3f85b769501d13 Gerrit-Change-Number: 30493 Gerrit-PatchSet: 1 Gerrit-Owner: neels <nhofmeyr@sysmocom.de> Gerrit-MessageType: newchange