mirror of https://github.com/fail2ban/fail2ban
`action.d/cloudflare-token.conf`: fixes `actionunban` retrieving of CF-ID from IP:
force adding parameters to URL as query string (add `-G` to curl); closes gh-3952pull/3948/head
parent
e5199aee92
commit
c9b5e845ba
|
@ -50,7 +50,7 @@ actionban = curl -s -X POST "<_cf_api_url>" \
|
|||
# <time> unix timestamp of the ban time
|
||||
# Values: CMD
|
||||
#
|
||||
actionunban = id=$(curl -s -X GET "<_cf_api_url>" \
|
||||
actionunban = id=$(curl -s -G -X GET "<_cf_api_url>" \
|
||||
--data-urlencode "mode=<cfmode>" --data-urlencode "notes=<notes>" --data-urlencode "configuration.target=<cftarget>" --data-urlencode "configuration.value=<ip>" \
|
||||
<_cf_api_prms> \
|
||||
| awk -F"[,:}]" '{for(i=1;i<=NF;i++){if($i~/'id'\042/){print $(i+1)}}}' \
|
||||
|
|
Loading…
Reference in New Issue