Prevent opening of system ports
This commit is contained in:
parent
9d58822f1a
commit
ca7e03bd66
1 changed files with 2 additions and 1 deletions
3
main.py
3
main.py
|
@ -74,7 +74,8 @@ def apply_port_changes():
|
|||
print(f"Excluding allocation \"{label}\" from forwarding, found \"pf_exclude\" in the description")
|
||||
continue
|
||||
|
||||
rules.append(create_rule(label, node_internal_ip, alloc["port"]))
|
||||
if int(alloc["port"]) > 1024:
|
||||
rules.append(create_rule(label, node_internal_ip, alloc["port"]))
|
||||
|
||||
run(router.async_apply_port_forwarding_rules(rules))
|
||||
|
||||
|
|
Loading…
Reference in a new issue