Skip to content

Instantly share code, notes, and snippets.

View kddlb's full-sized avatar
🤗

Kevin López Brante kddlb

🤗
View GitHub Profile
@kddlb
kddlb / ntfy.conf
Created January 14, 2024 23:02
Fail2Ban action for ntfy.sh
[Definition]
actionstart =
actionstop =
actioncheck =
actionban = lgm=$(printf '%%.10240s\n...' "<matches>"); curl -L 'https://ntfy.sh/<topíc_name>' -H 'Title: IP address <ip> has been banned!' -H 'Tags: globe_with_meridians,hammer' -H 'Content-Type: text/plain' -H 'Actions: view, IPinfo.io, https://ipinfo.io/<ip>; view, AbuseIPDB, https://www.abuseipdb.com/check/<ip>' -d "$lgm"
actionunban =
[Init]
name = ntfy