CVE-2025-34079

7.8 HIGH

📋 TL;DR

This vulnerability allows authenticated attackers with administrator credentials to execute arbitrary commands with SYSTEM privileges on NSClient++ servers. It affects NSClient++ version 0.5.2.35 when the web interface and ExternalScripts module are enabled. Attackers can inject malicious commands through the web API and trigger them remotely.

💻 Affected Systems

Products:
  • NSClient++
Versions: 0.5.2.35
Operating Systems: Windows
Default Config Vulnerable: ✅ No
Notes: Requires both web interface (default port 8443) and ExternalScripts module to be enabled. Not vulnerable in default configuration.

📦 What is this software?

⚠️ Risk & Real-World Impact

🔴

Worst Case

Complete system compromise with SYSTEM privileges, enabling data theft, lateral movement, ransomware deployment, and persistent backdoor installation.

🟠

Likely Case

Attackers with stolen or default admin credentials gain full control over the monitoring server, potentially compromising the entire monitoring infrastructure.

🟢

If Mitigated

Limited to authorized administrators performing legitimate script execution with proper audit trails.

🌐 Internet-Facing: HIGH
🏢 Internal Only: MEDIUM

🎯 Exploit Status

Public PoC: ⚠️ Yes
Weaponized: CONFIRMED
Unauthenticated Exploit: ✅ No
Complexity: LOW

Metasploit module available. Requires admin credentials. Exploitation is straightforward once authenticated.

🛠️ Fix & Mitigation

✅ Official Fix

Patch Version: Not available

Vendor Advisory: Not available

Restart Required: No

Instructions:

No official patch exists. This is a design flaw in the intended functionality. Apply workarounds and security controls instead.

🔧 Temporary Workarounds

Disable web interface

windows

Disable the web interface if not required for operations

Edit nsclient.ini: set [/settings/NSClient/server] enabled = false
Restart NSClient++ service

Disable ExternalScripts module

windows

Disable the ExternalScripts module to prevent command injection

Edit nsclient.ini: set [/settings/external scripts] enabled = false
Restart NSClient++ service

Restrict web interface access

windows

Configure firewall rules to restrict access to web interface port

netsh advfirewall firewall add rule name="Block NSClient Web" dir=in action=block protocol=TCP localport=8443
Or restrict to specific management IPs

🧯 If You Can't Patch

  • Change default admin password to strong, unique credentials
  • Implement network segmentation to isolate NSClient++ servers from critical systems

🔍 How to Verify

Check if Vulnerable:

Check if version is 0.5.2.35 and both web interface and ExternalScripts module are enabled in nsclient.ini

Check Version:

nscp client --version

Verify Fix Applied:

Verify web interface is disabled or ExternalScripts module is disabled in configuration

📡 Detection & Monitoring

Log Indicators:

  • Unusual API calls to /settings/query.json or /query/{name} endpoints
  • Multiple failed authentication attempts followed by successful login
  • External script execution logs with unusual commands

Network Indicators:

  • HTTP POST requests to port 8443 with command injection patterns
  • Outbound connections from NSClient++ server to unexpected destinations

SIEM Query:

source="nsclient.log" AND (uri="/settings/query.json" OR uri="/query/*") AND (command="cmd.exe" OR command="powershell.exe")

🔗 References

📤 Share & Export