Here is the script :
http://tinyurl.com/global-netbsd102
sha256 : 79b9d0e6d614add3cfce2e763b3a5a88b40c98621f1faf4d438082b16be30b20
Last Updates :
- Added poweroff and reboot on main menu.
- Fixed the sudo script
- Just added curl installation for first execution.
Necessary for checking internet connectivity.
Had forgotten it, sorry
Here is the script, plain and simple.
No commits. I'll see about that later, for now I'm moving forward.
The script is a bit messy, not clean at all...
I'll tidy it up later. Right now, I'm adding as many features as possible.
The checks are designed to verify if you haven't used other features upstream (for example, if you set up SSH and change the port, the script will check if you haven't forgotten to change the port in the firewall, etc...).
It's somewhat tailored to my needs, which may include standard desktop computer features (internet access via wifi... office software, etc.).
I'm about to add CMS and other web services soon.
Currently, it is divided into 8 parts:
Network :
--- Check Internet Connection
--- Restart DHCP Service
--- Enable IP forwarding
--- Disable IP forwarding
--- Switch from Ethernet to Wifi
--- Connect to a Wifi Network
--- Switch (back) from Wifi to Ethernet
Security :
--- Firewall
------ Configure NPF
------ View NPF Status and Active Rules
--- Configure SSH
--- Fail2ban
------ Configure Fail2ban
------ Show status
------ Open fail2ban log
------ Archive fail2ban log
------ Show banned IP
------ Unban an IP
--- Anti-virus
------ Install ClamAV with securiteinfo/sanesecurity databases
------ Update SaneSecurity ClamAV databases
------ Run a full antivirus scan
------ Run an antivirus scan of /home
------ Show ClamAV scan log
------ Archive ClamAV log file
------ Clear ClamAV log file
--- Set up OVPN VPN
Users and Access Rights Menu
--- Display list of users
--- Create a user
--- Check user existence
--- Delete a user
--- Display list of groups
--- Create a group
--- Check group existence
--- Delete a group
--- Add user to a group
--- Remove user from a group
--- Install sudo and add user to sudo group
Programs
--- Install desktop applications
--- Install usual utilities
Web Server
(I'll start it soon)
Disk Management
--- Format a USB device to FFSv1
--- Format a USB device to FFSv2
--- Format a USB device to NTFS
--- Format a USB device to exFAT (working but not perfect)
--- Securely erase a USB device
--- Mount a USB device to /media/dkX
--- Unmount a USB device mounted to /media/dkX
--- Burn .iso to a USB device
--- Burn .iso to a CD
--- Rebuild locate index
Services
--- OpenSSH File Server
------ Configure a SFTP file server with OpenSSH
------ Create a SFTP user
------ List SFTP users
------ Delete a SFTP user
------ Change password for a SFTP user
------ Disable a SFTP user account
------ List SFTP disabled users
------ Re-eanble a SFTP user account
Desktop Environment
--- Install XFCE4/Slim desktop environment