fix
This commit is contained in:
parent
c5f631d934
commit
9866774da8
6
modules/module-rate-limit-ip.sh
Normal file
6
modules/module-rate-limit-ip.sh
Normal file
@ -0,0 +1,6 @@
|
||||
#!/bin/bash
|
||||
NFT='/usr/bin/nft'
|
||||
$NFT add set ip filter rateLimit { type ipv4_addr \; flags dynamic, timeout \; timeout 5m \; }
|
||||
$NFT add set ip6 filter rateLimit { type ipv6_addr \; flags dynamic, timeout \; timeout 5m \; }
|
||||
$NFT add rule filter input ip protocol tcp ct state new, untracked limit rate over 100/minute add @rateLimit { ip saddr }
|
||||
$NFT add rule filter input ip6 protocol tcp ct state new, untracked limit rate over 100/minute add @rateLimit { ip6 saddr }
|
Loading…
Reference in New Issue
Block a user