Security Hardening

Harden SSL, firewall rules, backups, SSH access, common vulnerabilities, and operational security.

Resource List

AI prompts, scripts, and code that can be copied and reused.

bash

Server Security Initialization Script

Use this resource during the Security Hardening stage. Adapt it to your project requirements and validate the result before production use.

Server Security Initialization Script

A server hardening script for SSH security, firewall rules, package updates, time synchronization, and basic access controls.

How to Use

Adapt the resource to your project background, target users, budget, deployment environment, and security requirements. Validate the result in a test environment before using it in production.

Original Notes

πŸ”§ Script |: 2026-07-02 # Script ## Script bash #!/bin/bash # # root adduser deploy usermod -aG sudo deploy # SSH sed -i 's/PermitRootLogin yes/PermitRootLogin no/' /etc/ssh/sshd_config sed -i 's/#PasswordAuthentication yes/PasswordAuthentication no/' /etc/ssh/sshd_config systemctl restart sshd # ufw default deny incoming ufw default allow outgoing ufw allow 22/tcp ufw allow 80/tcp ufw allow 443/tcp ufw --force enable # Fail2Ban apt install fail2ban -y systemctl enable fail2ban systemctl start fail2ban # apt install unattended-upgrades -y dpkg-reconfigure -plow unattended-upgrades

bash

Certbot SSL Deployment Guide

Use this resource during the Security Hardening stage. Adapt it to your project requirements and validate the result before production use.

Certbot SSL Deployment Guide

A practical guide for issuing, installing, renewing, and validating Let's Encrypt certificates with Certbot.

How to Use

Adapt the resource to your project background, target users, budget, deployment environment, and security requirements. Validate the result in a test environment before using it in production.

Original Notes

πŸ”§ Script |: 2026-07-02 # SSL ## SSL bash # Certbot apt install certbot python3-certbot-nginx -y # (Nginx) certbot --nginx -d example.com -d www.example.com # certbot renew --dry-run # certbot certificates # () # grep Certbot /var/log/letsencrypt/letsencrypt.log