From 260c30535d71c5ee1d07f843536bd4e9f6163358 Mon Sep 17 00:00:00 2001 From: Alexander Belykh Date: Wed, 6 Jan 2016 17:13:30 +0600 Subject: [PATCH] Escape curly braces in nftables actions --- config/action.d/nftables-common.conf | 8 ++++---- config/action.d/nftables-multiport.conf | 2 +- 2 files changed, 5 insertions(+), 5 deletions(-) diff --git a/config/action.d/nftables-common.conf b/config/action.d/nftables-common.conf index 534eec2f..157f3c77 100644 --- a/config/action.d/nftables-common.conf +++ b/config/action.d/nftables-common.conf @@ -22,13 +22,13 @@ after = nftables-common.local # Notes.: additional expressions for nftables filter rule # Values: nftables expressions # -nftables_mode = dport { } +nftables_mode = dport \{ \} # Option: actionstart # Notes.: command executed once at the start of Fail2Ban. # Values: CMD # -actionstart = add set filter f2b- { type ipv4_addr\; } +actionstart = add set filter f2b- \{ type ipv4_addr\; \} insert rule filter %(nftables_mode)s ip saddr @f2b- # Option: actionstop @@ -50,7 +50,7 @@ actioncheck = list chain filter | grep -q '@f2b-[ \t]' # Tags: See jail.conf(5) man page # Values: CMD # -actionban = add element filter f2b- { } +actionban = add element filter f2b- \{ \} # Option: actionunban # Notes.: command executed when unbanning an IP. Take care that the @@ -58,7 +58,7 @@ actionban = add element filter f2b- { } # Tags: See jail.conf(5) man page # Values: CMD # -actionunban = delete element filter f2b- { } +actionunban = delete element filter f2b- \{ \} [Init] diff --git a/config/action.d/nftables-multiport.conf b/config/action.d/nftables-multiport.conf index 3c6455e2..d1afafb3 100644 --- a/config/action.d/nftables-multiport.conf +++ b/config/action.d/nftables-multiport.conf @@ -17,6 +17,6 @@ before = nftables-common.conf # Notes.: additional expressions for nftables filter rule # Values: nftables expressions # -nftables_mode = dport { } +nftables_mode = dport \{ \} [Init]