Guides / Process

What to do when a known exploited CVE hits your server

intermediateUpdated 27 Nov 2026981 words

A scanner reports a CVE from the CISA Known Exploited Vulnerabilities list on one of your servers. Attackers use this bug somewhere; find out whether they can use it on your server, and whether they already have. Work through the steps in order, within the next few hours.

1. Confirm the finding (15 minutes)

Collect the facts before changing anything:

  • Where is it: on the host, in a container image, or in an application directory?
  • Which package, which installed version, which fixed version?
  • Does the fix apply to you? The tracker of your distribution knows about backports: https://security-tracker.debian.org/tracker/<CVE>, https://ubuntu.com/security/<CVE>, https://access.redhat.com/security/cve/<CVE>.
  • Is the vulnerable part in use? Is the service running, the module loaded, the feature on?
  • Who can reach it: anyone on a public port, the internal network only, or local users only?

Read the KEV entry for the vendor guidance:

curl -sL https://raw.githubusercontent.com/cisagov/kev-data/main/known_exploited_vulnerabilities.json \
  | jq '.vulnerabilities[] | select(.cveID == "CVE-2025-32463")
        | {vulnerabilityName, requiredAction, notes, knownRansomwareCampaignUse}'

If the installed package is already the fixed version, either the finding is a false positive or the process still runs old code (see step 3). If the component is not installed at all, record why the scanner reported it and stop.

2. Contain while you prepare the fix

If the fix takes longer than a few minutes, reduce exposure first:

  • Allow the port only from known addresses, or put the service behind a VPN or an authenticating proxy. A rule in the firewall of your cloud provider is quick and does not touch the host.
  • Apply the mitigation of the vendor: a configuration change, or turning off the affected feature or module. KEV entries often say "Apply mitigations per vendor instructions"; the links in notes lead to them.
  • If nothing else works and the service can wait, take it offline.

3. Fix

Update the package, then make sure the new code runs:

# Debian, Ubuntu
sudo apt update && sudo apt install --only-upgrade <package>
# RHEL family
sudo dnf upgrade <package>
# Alpine (-U reads the current package index first)
sudo apk -U upgrade <package>
  • A service keeps the old code in memory until it restarts. needrestart (Debian, Ubuntu) and dnf needs-restarting (RHEL) list what still uses replaced files.
  • A kernel fix needs a reboot, and the old kernel stays installed. On Debian and Ubuntu the fixed kernel has a new package name: upgrade the meta package (linux-image-amd64, linux-image-generic, and linux-headers-amd64 or linux-headers-generic if headers are installed), reboot, then remove the old versioned packages with sudo apt-get purge. On the RHEL family, remove the old kernels after the reboot with sudo dnf remove --oldinstallonly.
  • A container image needs a rebuild with the fixed base image or package, and new containers from it (docker compose up -d, or docker run again). A restart of the old container changes nothing.
  • An application dependency needs a new build with the fixed version in the lockfile.

Then check the installed version and the running process, and scan again.

4. Look for signs that it was used

The bug is exploited in the wild, so check whether someone exploited it on your system while it was exposed. What to look for depends on the bug; the vendor advisory and the write-ups linked from the KEV entry often list indicators. General checks on a Linux server:

# logins and sudo use
last -n 30
sudo journalctl _COMM=sudo --since "14 days ago" | tail -50
# accounts with UID 0 and recently changed accounts
awk -F: '$3 == 0' /etc/passwd
ls -la --time-style=long-iso /etc/passwd /etc/shadow /etc/sudoers.d/
# SSH keys
sudo find / -xdev -name authorized_keys -mtime -30 -ls 2>/dev/null
# scheduled jobs
sudo ls -la /etc/cron.d /var/spool/cron/crontabs /var/spool/cron 2>/dev/null
systemctl list-timers --all
# network connections and listeners
sudo ss -tupn
# files in the web root changed in the last 14 days
sudo find /var/www -type f -mtime -14 -ls 2>/dev/null | head -50
# package files that differ from the package (Debian, Ubuntu / RHEL family)
sudo dpkg --verify | grep -v '^missing'
sudo rpm -Va | grep -v '^missing'

The last two compare installed files with the package checksums. A 5 in the third column means the content changed. Configuration files (marked c) change in normal use; binaries in /usr/bin should not:

??5??????   /usr/bin/zdump
??5?????? c /etc/debian_version

These checks can raise suspicion, but they cannot prove that a system is clean: an attacker with root can hide from all of them.

If you find something, stop working on the fix alone and go to the first hour of a security incident. Do not clean up traces before you have copies.

5. Write it down

Record in your ticket or log:

  • the CVE, the system, when the finding appeared and when it was fixed;
  • the mitigation used in between;
  • what you checked for signs of use and what you found;
  • what slowed you down (no access, no owner, no test system), so the next one goes faster.

Example: Log4Shell in December 2021

A team that ran a Java application with log4j-core 2.14.1 behind nginx would have found the JAR (step 1), blocked outbound LDAP and other unneeded outbound traffic from the server (step 2), deployed a build with 2.17.1 (step 3), and searched access logs for ${jndi: and checked for outbound connections and new files around the exposure (step 4). The Log4Shell guide has the details.

Sources

Check your servers every day

The Vulnpocalypse collector reports the packages and settings of a server once a day, and the digest lists what to fix, most urgent first.

Start free