CVE DatabaseCVE-2021-25298
한국어 권고문 →
CVE-2021-252988.8/HIGHCISA KEVCWE-78

Nagios XI 5.7.5 Remote OS Command Injection Vulnerability (CVE-2021-25298) Security Advisory

⚡ Jump to Patch
Affected Vendors
nagios
Affected Components
nagios_xi
Published Date
2021-02-15
CVSS v3.1
8.8
HIGH
EPSS (30d)
73.6%
FIRST.org
CISA KEV
Exploited

Executive & SecOps Summary

SECOPS ASSESSMENT
Affected Scope

Nagios XI version 5.7.5

Impact

An authenticated attacker can execute arbitrary OS commands on the Nagios XI server via a single crafted HTTP request, potentially leading to full system compromise.

Mitigation

Immediately upgrade Nagios XI to a patched version (5.8.0 or higher), or disable/restrict access to the vulnerable configuration wizard.

Affected Products & Version Scope

Nagios XI version 5.7.5 with the cloud-vm configuration wizard enabled

Remediation & Live Workaround Commands

PATCH & WORKAROUND

1. Official Patch & Version Upgrade Commands

Upgrade Nagios XI to the latest stable version (5.8.0 or higher) where this vulnerability has been resolved. Use the following commands to download and run the official upgrade script:

bash
# Access the Nagios XI server as root and perform the upgrade
cd /tmp
wget https://assets.nagios.com/downloads/nagiosxi/xi-latest.tar.gz
tar xzf xi-latest.tar.gz
cd nagiosxi
./upgrade

2. Temporary Workaround & Hardening Configuration

If an immediate upgrade is not feasible, temporarily disable the vulnerable cloud-vm configuration wizard by moving it out of the web directory, and restrict access to the Nagios XI console.

bash
# Backup and remove the vulnerable cloud-vm wizard directory
mv /usr/local/nagiosxi/html/includes/configwizards/cloud-vm /usr/local/nagiosxi/html/includes/configwizards/cloud-vm.bak

# Restrict access to the Nagios XI web interface to trusted IP ranges in Apache configuration
# Add the following directive to your Apache configuration file (e.g., /etc/httpd/conf.d/nagiosxi.conf)
<Directory '/usr/local/nagiosxi/html'>
    Require ip 10.0.0.0/8 192.168.0.0/16
</Directory>

3. Log Audit & IoC Verification Commands

Inspect the web server access logs for suspicious requests targeting the cloud-vm wizard containing shell metacharacters.

bash
# Search Apache access logs for cloud-vm wizard execution and command injection attempts
grep -i 'cloud-vm' /var/log/httpd/access_log | grep -E '(%3B|%26|%7C|;|\&|\|)'

# Verify the currently installed Nagios XI version
grep 'product_version' /usr/local/nagiosxi/html/config.inc.php
Interactive SecOps Remediation Checklist
0/4 (0%)
Recommended Security Control & Mitigation Partner
Cloudflare Enterprise & Pro WAF
Due to active exploitation in the wild (CISA KEV), immediately upgrade Nagios XI to version 5.8.0 or higher to secure your monitoring infrastructure.

Block Exploits Instantly with Managed Virtual Patching Rules

Can't patch production immediately? Deploy managed WAF rules at the edge to intercept RCE, SQLi, and deserialization payloads before they hit your origin server.

3-min setup · Automated Zero-Day Managed Rules
Practice Exploiting & Patching This Web Vulnerability in an Interactive Lab
Launch Hands-On Security Lab

Technical Root Cause & Exploitation Mechanics

1. Vulnerability Overview & Root Cause

This vulnerability (CVE-2021-25298) is an OS command injection flaw in the network and infrastructure monitoring solution Nagios XI version 5.7.5. The root cause lies within the /usr/local/nagiosxi/html/includes/configwizards/cloud-vm/cloud-vm.inc.php file, where user-controlled input is processed without adequate sanitization or validation before being passed directly to system shell execution functions.

2. Exploitation Mechanics & Attack Scenario

To exploit this vulnerability, an attacker must first obtain valid credentials to authenticate to the Nagios XI web interface. Once authenticated, the attacker can send a single HTTP request targeting the cloud-vm configuration wizard, embedding shell metacharacters (such as ;, &, |, or ` `) within the input parameters. The backend PHP script executes these parameters directly via system shell commands, allowing the attacker to run arbitrary OS commands with the privileges of the web server user (typically apache or nagios`).

3. Infrastructure & Business Impact

Since Nagios XI is centrally positioned to monitor critical enterprise servers, network devices, and cloud infrastructure, a compromise of this server is highly critical. Attackers can leverage this access to harvest credentials, map internal network topologies, pivot to other internal systems, or deploy ransomware. This vulnerability is actively exploited in the wild, as indicated by its inclusion in the CISA KEV list and its high EPSS score.

Official Vendor Advisories & References

Frequently Asked SecOps Questions (CVE-2021-25298)

FAQ

Q1. How critical is CVE-2021-25298 and is it actively exploited in the wild?

CVE-2021-25298 is rated CVSS 8.8 (HIGH) with a 30-day EPSS exploitation probability of 73.6%. It is listed in the CISA Known Exploited Vulnerabilities (KEV) catalog, requiring immediate emergency remediation.

Q2. Which vendors and products are affected by CVE-2021-25298?

Primary impacted vendors include nagios across nagios_xi. Scope summary: Nagios XI version 5.7.5 with the cloud-vm configuration wizard enabled

Q3. What temporary mitigations or workarounds exist for CVE-2021-25298 before patching?

[Mitigation] Immediately upgrade Nagios XI to a patched version (5.8.0 or higher), or disable/restrict access to the vulnerable configuration wizard. Follow the CLI remediation commands and interactive SecOps checklist on this page to restrict exposure prior to your maintenance window.

SECOPS WORKBENCH INTEGRATION

Generate an Internal Engineering Notice or CISO Report for CVE-2021-25298

Instantly format this advisory into an executive CISO summary or engineering patch ticket.

Generate Report →

🔗 Related Advisories in Similar Stack (nagios)

View Category →
SecOps Advisory Dispatch & RSS Feed

Subscribe to Daily Vulnerability Briefings & KEV Alerts

Concise morning briefings for SecOps, DevSecOps, and SRE teams covering newly exploited CVEs and mitigation priorities.

Slack / Teams / RSS Feed:
PatchKO
CVE-2021-25298 Nagios XI 5.7.5 Remote OS Command Injection Vulnerability (CVE-2021-25298) Security Advisory (CVSS 8.8) - Patch & Workaround | CVE Pulse