Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Python Import #4

Merged
merged 9 commits into from
Oct 14, 2024
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
111 changes: 33 additions & 78 deletions README.md
Original file line number Diff line number Diff line change
@@ -1,90 +1,45 @@
# Overview

This is a collection of bash/shell scripts to assist in linux server administration
designed to be run by a Unix shell, a command-line interpreter to assist in
automating, management and reporting tasks.
Script to provide html reporting of a system status.
Provides an offline/regular report to lessen the need to install resource heavy software like webadmin on a server

# Prerequisites
<br></br>
**Bash (the Bourne Again SHell) - version 5.1+**

**Linux/Unix System**

> [!IMPORTANT]
> Other versions of bash are not tested/support, for testing you can utilise [Shell Check](https://www.shellcheck.net/)
>
> The scripts have not been designed to work with non-unix/linux systems
The main focus of the script is to be secure, simple and focus on using less resources as possible
while still providing a good amount of information for server administration

**The scripts are very basic and easy to use/customise**
<i>The scripts were previous written in bash/shell script, this is still available in the inital release of this project.</i>

<br></br>
## **SURE - System Utilization and Risk Evaluation**
<br></br>
<!-- SPACE -->
### :basecamp: System Audit Report
<!-- SPACE -->

A script to provide a basic audit of the system. Can be run from crontab to provide a daily/weekly report as needed.
Provides a basic snapshot of the server with the following information -

<!-- SPACE -->
:star: Current Users
:star: Running Procs
:star: Top 10 Memory Usage
:star: Top 10 CPU Usage
:star: Open Files
<!-- SPACE -->
<br></br>
<!-- SPACE -->
### :basecamp: System Security Report
<!-- SPACE -->
# Prerequisites

<!-- SPACE -->
A script to provide a basic security report of the system. Can be run from crontab to provide daily/weekly report as needed.
Provides a basic snapshot of the following information from the server -
<!-- SPACE -->
Requires a Linux/Unix System and Python 3, please see the `COMMANDS` section of the script for commands utilising in the reporting.

<!-- SPACE -->
:star: failog report
:star: No Owner Files
:star: Set GID Files
:star: Set UID Files
:star: World Writeable Files
:star: Open Ports
:star: Current Services
<!-- SPACE -->
# Configuration

> LOG_FILE = ""
This should be the directory and file name for the log output and errors

<br></br>
## **ALERT - Auth Log and Event Reporting Tool**
<br></br>
<!-- SPACE -->
### :basecampy: Auth Log Report
<!-- SPACE -->
> OUTPUT_HTML = ""
Directory and file name for the HTML output to be generated too

<!-- SPACE -->
A script to generate a HTML report of the current server auth requests for the past 3 hours
Provides a regular report for the each 3 hours of the `auth.log` on the server to audit server
connection attempts and logins.
Can be run via the crontab to produce the html report
:star: a script snipplet is available to provide an admin with a copy of the `auth.log` from the
log file directory
<!-- SPACE -->
<br></br>
<!-- SPACE -->
### :basecampy: System Status Report
<!-- SPACE -->
> LAST_RUN_FILE = ""
The directory and lock file name to use for tracking the last run time

<!-- SPACE -->
A script to generate a HTML report of the server stats for the administrator or operators
The html report generates includes the following information and can be run via the crontab
<!-- SPACE -->
> MAIL_CONFIG = ""
>
This is configuration for the mail settings
>
`Enabled`
TRUE would enable to use of mailing the output.
FALSE would disable the option of mailing the outputted HTML file.
>
`recipient`
This should be the email to send the html out/stats file to.
>
`Subject`
This is the subject line of the email/stats email if enabled.
>
`mail_command`
You can set the default mail command here.

<!-- SPACE -->
:star: Current Open Ports
:star: Current Connections
:star: System Log Entries from the past 2 hours
:star: System Critical Entry's (Priority 2)
:star: System Alert Entry's (Priority 1)
:star: System Emergency Entry's (Priority 0)
<!-- SPACE -->
> [!IMPORTANT]
> It is not recommend to change the `COMMANDS` section unless you are able to configure the out correctly.
> We do not provide support for customising this section of the script
114 changes: 0 additions & 114 deletions authlog_report.sh

This file was deleted.

Loading