mirror of
https://github.com/vdsm/virtual-dsm.git
synced 2026-08-29 04:07:02 +00:00
fix: Restore compatible NAT forwarding rules (#1247)
This commit is contained in:
+1
-13
@@ -964,22 +964,10 @@ configureTables() {
|
||||
warn "$tables_err" && return 1
|
||||
fi
|
||||
|
||||
# Allow newly DNATed connections to the guest
|
||||
# Allow forwarding from dev -> guest
|
||||
if ! iptables -A FORWARD \
|
||||
-i "$DEV" \
|
||||
-o "$BRIDGE" \
|
||||
-d "$ip" \
|
||||
-m conntrack --ctstate NEW --ctstatus DNAT \
|
||||
-m comment --comment "$rule_tag" \
|
||||
-j ACCEPT; then
|
||||
warn "$tables_err" && return 1
|
||||
fi
|
||||
|
||||
# Allow return and related traffic
|
||||
if ! iptables -A FORWARD \
|
||||
-i "$DEV" \
|
||||
-o "$BRIDGE" \
|
||||
-m conntrack --ctstate RELATED,ESTABLISHED \
|
||||
-m comment --comment "$rule_tag" \
|
||||
-j ACCEPT; then
|
||||
warn "$tables_err" && return 1
|
||||
|
||||
Reference in New Issue
Block a user