On Sat, 28 Mar 2020, Philip via Fail2ban-users wrote:

Date: Sat, 28 Mar 2020 06:24:22
From: Philip via Fail2ban-users <fail2ban-users@lists.sourceforge.net>
[--- snipped ---]
I've got a curl statement that sends blocked IP's to an API, just curious if I can also 
send the "found" lines at the same time
(like in the email).

actionban = curl -d '{"ip":"<ip>"}' -H "Content-Type: application/json" -X POST 
http://localhost:80100/api/v1/networkbanip

Phil
[--- snipped ---]

Hello Phil,

        I have not tried it myself, but perhaps some variation on the theme of:-

curl ... --form data="$( grep ... )" ...

        There was an item on this mailing list on the subject of "Rearranging the action_mwl 
output?" from Gary Gapinski on 2020-02-24 which might give you a hint about 
"%(_grep_logs)s;" in your banning action.

        Incidentally, is it really port 80100?

        Hoping this helps,
--
Graham
There are actually more wrecked aeroplanes in the oceans than there are wrecked 
submarines in the sky.

<a href="http://english-1329209197.spampoison.com";>Get free spam bait here.</a>





_______________________________________________
Fail2ban-users mailing list
Fail2ban-users@lists.sourceforge.net
https://lists.sourceforge.net/lists/listinfo/fail2ban-users

Reply via email to