Advertisement
Not a member of Pastebin yet?
Sign Up,
it unlocks many cool features!
- #!/usr/sbin/nft -f
- flush ruleset
- table inet filter {
- chain input {
- type filter hook input priority 0; policy drop;
- iifname lo accept
- ct state { related,established } accept
- ct state invalid counter drop
- tcp flags & (fin|syn|rst|ack) != syn ct state new counter drop
- ct state new tcp dport {ssh, http, https, 8388} counter accept #Разрешаешь TCP порты
- ct state new tcp dport {8388} counter accept #Разрешашь UDP порты
- }
- chain forward {
- type filter hook forward priority 0;
- }
- chain output {
- type filter hook output priority 0;
- }
- }
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement