A Bash script that automates the setup of a secure Linux server, including user management, firewall configuration (iptables/nftables), SSH hardening, and system monitoring.
- admin (with sudo access)
- user1 , user2 , user3 (regular users, no sudo)
- Blocks all incoming connections except SSH (on port 2222)
- Allows loopback & ping
- Prevents unauthorized access
- Changes SSH port to 2222
- Disables root login
- Disables password authentication (only key-based login)
- Limits authentication attempts
- Prevents SSH brute-force attacks
- Bans IPs that fail 3 times for 10 minutes
- htop (Process monitoring)
- glances (System-wide resource monitoring)
- net-tools (Networking utilities)