/

CVE-2026-49832

Severity:

HIGH RISK

(8.0)

Remote Code Execution (CWE-94) in DSpace Velocity Templates

CVE-2026-49832

Awaiting Analysis

Vulnerability type

Category:

Code Injection

CWE:

CWE-94

Impact:

Remote Code Execution

Severity:

HIGH RISK

(8.0)

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

DSpace contains a remote code execution vulnerability in the Velocity template processing used for COAR Notify/LDN messages. Under conditions where attacker-controlled message content reaches this template processing path, an attacker may execute code with the privileges of the DSpace service.

Affected context

The issue affects DSpace deployments that use the vulnerable Velocity template handling path for COAR Notify or Linked Data Notifications (LDN). It is relevant to affected DSpace release lines where untrusted or insufficiently constrained message data can be evaluated as a template rather than treated strictly as data.

Exploit preconditions

  • Attack surface: DSpace COAR Notify/LDN message processing
  • Required access: The ability to submit or influence data that reaches the affected message and template-processing workflow
  • Trigger point: Evaluation of a Velocity template during message handling
  • Why exploitation is possible: Template expressions may be interpreted with capabilities that permit code execution instead of being limited to data rendering

Why this happens

The underlying flaw is code injection caused by treating template content influenced by an external party as executable template logic. Velocity evaluation can provide access to operations beyond simple substitution when its context and execution features are not sufficiently restricted. This behavior maps to CWE-94, Improper Control of Generation of Code, because attacker-influenced input can affect code-like instructions executed by the application.

Potential impact

  • An attacker may execute arbitrary code in the DSpace service process.
  • The attacker could access or modify repository-managed content and metadata.
  • The application may be used to access connected services or stored secrets.
  • The compromise could support data tampering, persistence, or further lateral movement.

General mitigation guidance

Mitigation generally focuses on removing executable template behavior from

untrusted message-processing paths.

Common defensive patterns include:

  • Treating notification content as data and using non-evaluating rendering mechanisms.
  • Restricting template contexts to an explicit allowlist of inert values and operations.
  • Disabling dangerous reflection, object access, method invocation, and other execution-capable template features.
  • Applying strict validation and canonicalization before message content reaches rendering logic.
  • Isolating the DSpace service with least-privilege accounts, limited filesystem access, and restricted network permissions.
  • Using maintained releases that contain the vendor's security correction and applying the organization's standard patch governance.

How teams detect issues like this

Detection approaches may include:

  • Static analysis rules identifying Velocity evaluation of externally influenced input.
  • Code review checks for dynamic template construction, unrestricted template contexts, and method or object access from templates.
  • Runtime monitoring for unexpected process creation, shell invocation, filesystem changes, or outbound connections from DSpace.
  • Logging and alerting on unusual COAR Notify/LDN message sources, template errors, and administrative changes following message processing.
  • Policy enforcement that requires approved templates and blocks executable constructs in externally supplied content.

Automated security review tools can help identify unsafe template evaluation patterns during development and CI.

Sources

SourceLink
github.comgithub.com/DSpace/DSpace/pull/12548
github.comgithub.com/DSpace/DSpace/pull/12549
github.comgithub.com/DSpace/DSpace/security/advisories/GHSA-9x82-rm84-c6x7

Frequently asked

questions

It may be remotely exploitable when an attacker can submit or influence a

COAR Notify/LDN message that is processed by the affected DSpace workflow.

The exact scope depends on notification configuration, exposure, and access

controls.

Not necessarily. Authentication requirements depend on how the DSpace

notification endpoint is exposed and whether message submission is restricted

by deployment-specific controls.

Ensure externally influenced content is rendered as data rather than evaluated

as a Velocity template, and restrict any remaining template context to a

narrowly defined, non-executable allowlist.

Combine safe-by-default template configuration, strict input validation,

security-focused code review, runtime least privilege, and monitoring for

process or filesystem activity that is inconsistent with normal DSpace

operation.

Find out what's already
exploitable in your codebase.