/

CVE-2026-40882

Severity:

HIGH RISK

(7.6)

XML External Entity (XXE) in OpenRemote Velbus Asset Import

CVE-2026-40882

Analyzed

Vulnerability type

Category:

XML External Entity (XXE)

CWE:

CWE-611

Impact:

Server-Side File Disclosure and Server-Side Request Forgery (SSRF)

Severity:

HIGH RISK

(7.6)

CVSS version:

3.1

Catch this CVE while code is being written

Detect vulnerable code directly in pull requests, so CVEs are fixed before merge.

Summary

OpenRemote's Velbus asset import endpoint parses user-supplied XML without proper XXE hardening, allowing external entity resolution.

An authenticated user who can access the import endpoint may abuse XML external entities to read server-side files (up to 1023 characters) or initiate server-side request forgery (SSRF).

Affected context

This vulnerability appears in OpenRemote deployments that expose the Velbus asset import functionality and accept XML documents from authenticated users.

It becomes relevant when:

  • The XML parser is configured with default or permissive settings
  • External entity resolution is not explicitly disabled
  • Backend services, internal networks, or sensitive files are reachable from the OpenRemote server

Exploit preconditions

  • Attack surface: HTTP(S) endpoint handling Velbus asset XML imports
  • Required access: Authenticated access with permission to call the import endpoint
  • Trigger point: Submission and processing of crafted XML documents containing external entity declarations
  • Why exploitation is possible: The XML parser processes external entities by default, and the application does not enforce explicit XXE protections, allowing the attacker-controlled XML to reference internal files or network resources

Why this happens

The root cause is the use of an XML parser that permits processing of external entities without explicit hardening.

This aligns with CWE-611: Improper Restriction of XML External Entity Reference, where untrusted XML input is parsed without disabling features such as external general entities, parameter entities, or DTDs.

Conceptually, the parser treats data (the XML document) as instructions to fetch and expand external resources, creating an unintended bridge between user-controlled input and internal file systems or network targets.

Potential impact

  • Disclosure of server-side files accessible to the OpenRemote process (limited to content under 1023 characters per response)
  • Server-Side Request Forgery (SSRF) to internal HTTP(S) services
  • Probing of internal network topology and services reachable from the OpenRemote server
  • Potential pivot to exploit vulnerabilities on internal services reached via SSRF
  • Exposure of sensitive configuration values, credentials, or tokens stored in readable files

General mitigation guidance

Effective mitigation centers on hardening XML parsing behavior and minimizing trust in user-supplied XML:

  • Configure XML parsers to disable external entity resolution, DTD processing, and parameter entities by default
  • Prefer high-level XML APIs or libraries that are secure-by-default regarding XXE
  • Validate and sanitize incoming XML against a strict schema, rejecting unexpected constructs such as DOCTYPE declarations
  • Isolate components that must process complex XML in hardened, least-privileged services or sandboxes
  • Limit the OpenRemote process's filesystem and network access using OS-level permissions, container policies, and network segmentation

How teams detect issues like this

XXE issues can be surfaced using a combination of review and automated checks:

  • Static analysis rules that flag XML parser configurations where external entities or DTDs are enabled on untrusted input paths
  • Code review checklists that require explicit disabling of XXE features whenever XML is parsed from user-controlled sources
  • Security tests or fuzzing that inject XML payloads with external entities and monitor for outbound requests or unexpected file content in responses
  • Web application firewalls or API gateways monitoring for XML payloads containing DOCTYPE declarations and unusual entity constructs

Sources

SourceLink
github.comgithub.com/openremote/openremote/security/advisories/GHSA-g24f-mgc3-jwwc

Frequently asked

questions

It can be, but only if the Velbus asset import endpoint is exposed to remote users and they can authenticate and call the import function. The issue is not anonymous; some level of authenticated access is required.

The attacker must be an authenticated user with the ability to invoke the Velbus asset import endpoint and supply custom XML data. Without this capability, the XXE behavior cannot be triggered.

The most robust fix is to configure all XML parsers handling user-controlled input to disable external entities and DTD processing, and to enforce strict schema validation. Using XML libraries that are secure-by-default for XXE and centralizing parser configuration helps ensure consistency.

Adopt secure XML parsing guidelines across the codebase, enforce them via coding standards and static analysis, and treat any user-supplied XML as untrusted. During design and code review, require explicit evidence that XXE-related features are disabled and that services processing XML operate under least privilege with constrained filesystem and network access.

Find out what's already
exploitable in your codebase.