mirror of
https://github.com/andwati/telecom-platform.git
synced 2026-10-27 07:02:15 +00:00
feat: Add iptables configuration script for free5GC UPF
- Add shell script to configure UPF (User Plane Function) iptables rules - Flush existing filter, nat, and mangle tables - Configure NAT masquerading on eth0 interface - Set up forwarding rules for uesimtun0 tunnel interface - Enable bidirectional traffic flow between UE tunnel and external network
This commit is contained in:
Executable
+12
@@ -0,0 +1,12 @@
|
||||
#!/bin/bash
|
||||
|
||||
iptables -t filter -F
|
||||
iptables -t nat -F
|
||||
iptables -t mangle -F
|
||||
|
||||
iptables -t nat -A POSTROUTING -o eth0 -j MASQUERADE
|
||||
|
||||
iptables -A FORWARD -i uesimtun0 -o eth0 -j ACCEPT
|
||||
iptables -A FORWARD -i eth0 -o uesimtun0 -m state --state RELATED,ESTABLISHED -j ACCEPT
|
||||
|
||||
echo "UPF iptables rules configured"
|
||||
Reference in New Issue
Block a user