Skip to content

Commit

Permalink
Merge pull request #5700 from mailcow/staging
Browse files Browse the repository at this point in the history
[Netfilter] fix mailcow isolation rule for iptables
  • Loading branch information
DerLinkman authored Feb 2, 2024
2 parents c9e9628 + 57e67ea commit 20c9064
Showing 1 changed file with 2 additions and 2 deletions.
4 changes: 2 additions & 2 deletions data/Dockerfiles/netfilter/modules/IPTables.py
Original file line number Diff line number Diff line change
Expand Up @@ -219,7 +219,7 @@ def create_mailcow_isolation_rule(self, _interface:str, _dports:list, _allow:str

# insert mailcow isolation rule
rule = iptc.Rule()
rule.in_interface = f'! {_interface}'
rule.in_interface = f'!{_interface}'
rule.out_interface = _interface
rule.protocol = 'tcp'
rule.create_target("DROP")
Expand All @@ -234,7 +234,7 @@ def create_mailcow_isolation_rule(self, _interface:str, _dports:list, _allow:str
if _allow != "":
rule = iptc.Rule()
rule.src = _allow
rule.in_interface = f'! {_interface}'
rule.in_interface = f'!{_interface}'
rule.out_interface = _interface
rule.protocol = 'tcp'
rule.create_target("ACCEPT")
Expand Down

0 comments on commit 20c9064

Please sign in to comment.