A CVE (Common Vulnerabilities and Exposures) is a unique identifier for a publicly known security vulnerability. Understanding how CVEs work and implementing a patch management strategy is critical for keeping your server secure.
What Is a CVE?
# CVE format: CVE-YEAR-NUMBER
# Example: CVE-2024-3094 (XZ Utils backdoor)
# Example: CVE-2021-44228 (Log4Shell)
# Key components:
# - CVE ID: Unique identifier
# - Description: What the vulnerability is
# - CVSS Score: Severity rating (0-10)
# - Affected versions: Which software versions are vulnerable
# - References: Links to patches and advisories
CVSS Severity Scores
# CVSS v3.1 severity ratings:
# None: 0.0
# Low: 0.1 - 3.9
# Medium: 4.0 - 6.9
# High: 7.0 - 8.9
# Critical: 9.0 - 10.0
# Patch priority timeline:
# Critical: Patch within hours
# High: Patch within 24-72 hours
# Medium: Patch within 1-2 weeks
# Low: Patch during next maintenance window
Checking for Known Vulnerabilities
# Ubuntu/Debian
sudo apt update
sudo apt list --upgradable
apt changelog nginx | grep CVE
# AlmaLinux/Rocky
sudo dnf updateinfo list security
# Use Lynis for a comprehensive audit
sudo lynis audit system --quick
Automated Patch Management
Ubuntu/Debian
sudo apt install unattended-upgrades
sudo dpkg-reconfigure -plow unattended-upgrades
# Verify it is working
sudo unattended-upgrade --dry-run --debug
AlmaLinux/Rocky
sudo dnf install dnf-automatic
# Configure /etc/dnf/automatic.conf with upgrade_type = security
sudo systemctl enable --now dnf-automatic-install.timer
CVE Monitoring Tools
- NVD — nvd.nist.gov, comprehensive CVE database
- CVE.org — Official CVE list by MITRE
- Vulners — Aggregates CVEs with exploit data
- OSV — osv.dev, open-source vulnerability database
- Trivy — Container and filesystem vulnerability scanner
Best Practices
- Subscribe to security mailing lists for your OS and key software
- Enable automatic security updates for the OS
- Test patches in staging before applying to production
- Keep an inventory of all software and versions
- Have a rollback plan for every patch (snapshots, backups)
- Monitor for zero-day disclosures on security feeds