An open API service indexing awesome lists of open source software.

https://github.com/nulldev/fail2ban-log-viewer

:mag_right: A Bash script to print out the Fail2Ban log in a organized way.
https://github.com/nulldev/fail2ban-log-viewer

bash command-line console fail2ban linux log nulldev terminal

Last synced: 27 days ago
JSON representation

:mag_right: A Bash script to print out the Fail2Ban log in a organized way.

Awesome Lists containing this project

README

          

# Fail2Ban Log Viewer

[![Build Status](https://travis-ci.org/NullDev/Fail2Ban-Log-Viewer.svg?branch=master)](https://travis-ci.org/NullDev/Fail2Ban-Log-Viewer) [![GitHub license](https://img.shields.io/badge/license-MIT-blue.svg)](https://raw.githubusercontent.com/NullDev/Fail2Ban-Log-Viewer/master/LICENSE)

A script to print out the Fail2Ban log in a organized way.

## To get it working:

- Upload the script somewhere
- Log in to your SSH terminal
- make it executable with
`chmod +x fail2ban.sh`
- and finally launch it with
`./fail2ban.sh`

That's it.

## Features:

- Display Hostname and IP
- Display IP and Auth Method used (For example SSH or Nginx Auth)
- Allows a user specified path inside the script
- Fallback path if user specified path fails
- Auto-Search feature if Fallback path and user path fail
- Purge/Clear the Fail2Ban.log after displaying

Example: `./fail2ban.sh --clear` or `./fail2ban.sh -c`

- Use new path if file was found
- Check if Fail2Ban is installed
- Able to pass CLI Argument `-p` or `--path` to use a custom path for the log file at start.

Example: `./fail2ban.sh -p /your/log/path.log` or `./fail2ban.sh --path /your/log/path.log`

- Able to handle unknown CLI Arguments, aswell as `--help`, `-h` or `-?`

Example: `./fail2ban.sh --help`, `./fail2ban.sh -h` or `./fail2ban.sh -?`

- CLI Argument `--force` or `-f` which forces the start and doesn't prompt for input
- More comming soon!

### Screenshots:




       Main       





       Help