Skip to content

Commit 7171b9d

Browse files
author
Jens
committed
Create 17-fail2ban.sh
1 parent be6ab45 commit 7171b9d

File tree

1 file changed

+18
-0
lines changed

1 file changed

+18
-0
lines changed

17-fail2ban.sh

Lines changed: 18 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,18 @@
1+
#!/bin/bash
2+
3+
echo '___________ .__.__ __________________ _____ '
4+
echo '\_ _____/____ |__| | \_____ \______ \_____ ____ .__ __ ___/ ____\_ _ __'
5+
echo ' | __) \__ \ | | | / ____/| | _/\__ \ / \ __| |___ | | \ __\\ \/ \/ /'
6+
echo ' | \ / __ \| | |__/ \| | \ / __ \| | \ /__ __/ | | /| | \ / '
7+
echo ' \___ / (____ /__|____/\_______ \______ /(____ /___| / |__| |____/ |__| \/\_/ '
8+
echo ' \/ \/ \/ \/ \/ \/ '
9+
10+
echo "
11+
[sshd]
12+
enabled = true
13+
banaction = ufw
14+
port = ssh
15+
filter = sshd
16+
logpath = %(sshd_log)s
17+
maxretry = 3
18+
" | sudo tee -a /etc/fail2ban/jail.conf

0 commit comments

Comments
 (0)