mirror of https://gitee.com/openkylin/libvirt.git
net: use newer iptables syntax
iptables-1.4.18 removed the long deprecated "state" match. Use "conntrack" instead in forwarding rules. Fixes openSUSE bug https://bugzilla.novell.com/811251 #811251.
This commit is contained in:
parent
d0cc811ed0
commit
e669a65903
|
@ -480,8 +480,8 @@ iptablesForwardAllowRelatedIn(iptablesContext *ctx,
|
|||
"--destination", networkstr,
|
||||
"--in-interface", physdev,
|
||||
"--out-interface", iface,
|
||||
"--match", "state",
|
||||
"--state", "ESTABLISHED,RELATED",
|
||||
"--match", "conntrack",
|
||||
"--ctstate", "ESTABLISHED,RELATED",
|
||||
"--jump", "ACCEPT",
|
||||
NULL);
|
||||
} else {
|
||||
|
@ -490,8 +490,8 @@ iptablesForwardAllowRelatedIn(iptablesContext *ctx,
|
|||
action,
|
||||
"--destination", networkstr,
|
||||
"--out-interface", iface,
|
||||
"--match", "state",
|
||||
"--state", "ESTABLISHED,RELATED",
|
||||
"--match", "conntrack",
|
||||
"--ctstate", "ESTABLISHED,RELATED",
|
||||
"--jump", "ACCEPT",
|
||||
NULL);
|
||||
}
|
||||
|
|
Loading…
Reference in New Issue