firewall/modules/module-open-ports.sh

14 lines
317 B
Bash
Raw Normal View History

2024-09-30 19:24:26 -06:00
#!/bin/bash
NFT='/usr/bin/nft'
declare -A portConfig
portConfig["https"]="443"
portConfig["http"]="80"
portConfig["AdGuard-3"]="853"
#portConfig["WireGuard"]="25"
portOpenParser() {
$NFT insert rule ip filter input position 0 tcp dport $1 accept
$NFT insert rule ip6 filter input position 0 tcp dport $1 accept
}