CVE-2021-47699

5.4 MEDIUM

📋 TL;DR

Nagios XI versions before 5.8.7 contain a cross-site scripting vulnerability in the Audit Log page's Send to NLS form. Attackers can inject malicious scripts that execute in victims' browsers when they view the compromised page. This affects all Nagios XI administrators and users who access the Audit Log functionality.

💻 Affected Systems

Products:
  • Nagios XI
Versions: All versions prior to 5.8.7
Operating Systems: All supported platforms
Default Config Vulnerable: ⚠️ Yes
Notes: Requires authenticated access to the Audit Log page. The vulnerability exists in the default installation.

📦 What is this software?

⚠️ Risk & Real-World Impact

🔴

Worst Case

An authenticated attacker could steal administrator session cookies, perform actions as the victim, or redirect users to malicious sites, potentially leading to full system compromise if combined with other vulnerabilities.

🟠

Likely Case

Attackers steal session cookies or credentials from authenticated users, gaining unauthorized access to the Nagios XI interface with the victim's privileges.

🟢

If Mitigated

With proper input validation and output encoding, the script injection would be neutralized, preventing any client-side execution.

🌐 Internet-Facing: MEDIUM
🏢 Internal Only: MEDIUM

🎯 Exploit Status

Public PoC: ✅ No
Weaponized: UNKNOWN
Unauthenticated Exploit: ✅ No
Complexity: MEDIUM

Exploitation requires authenticated access to the Nagios XI interface and victim interaction with the compromised Audit Log page.

🛠️ Fix & Mitigation

✅ Official Fix

Patch Version: 5.8.7

Vendor Advisory: https://www.nagios.com/changelog/nagios-xi/

Restart Required: No

Instructions:

1. Backup your Nagios XI configuration. 2. Download Nagios XI 5.8.7 or later from the Nagios website. 3. Follow the official upgrade instructions at https://assets.nagios.com/downloads/nagiosxi/docs/Upgrading-Nagios-XI.pdf. 4. Verify the upgrade completed successfully.

🔧 Temporary Workarounds

Disable Send to NLS functionality

all

Temporarily disable the vulnerable Send to NLS form feature in the Audit Log page

Implement WAF rules

all

Configure web application firewall to block XSS payloads targeting the Audit Log endpoints

🧯 If You Can't Patch

  • Restrict access to the Nagios XI interface to trusted networks only
  • Implement Content Security Policy headers to mitigate script execution

🔍 How to Verify

Check if Vulnerable:

Check Nagios XI version via Admin > System Config > About page. If version is below 5.8.7, the system is vulnerable.

Check Version:

grep 'nagiosxi_version' /usr/local/nagiosxi/var/xiversion

Verify Fix Applied:

After upgrading, verify version is 5.8.7 or higher and test the Audit Log Send to NLS form with basic XSS payloads like <script>alert('test')</script> to ensure proper sanitization.

📡 Detection & Monitoring

Log Indicators:

  • Unusual POST requests to /nagiosxi/admin/auditlog.php with script tags or JavaScript in parameters
  • Multiple failed login attempts followed by successful login and Audit Log access

Network Indicators:

  • HTTP requests containing <script> tags or JavaScript functions sent to Nagios XI Audit Log endpoints

SIEM Query:

source="nagios_access.log" AND (uri_path="/nagiosxi/admin/auditlog.php" AND (http_method="POST" AND (content="<script>" OR content="javascript:")))

🔗 References

📤 Share & Export