CVEReports
CVEReports

Automated vulnerability intelligence platform. Comprehensive reports for high-severity CVEs generated by AI.

Product

  • Home
  • Sitemap
  • RSS Feed

Company

  • About
  • Contact
  • Privacy Policy
  • Terms of Service

© 2026 CVEReports. All rights reserved.

Made with love by Amit Schendel & Alon Barad



CVE-2026-15603

CVE-2026-15603: Log Forging via Unescaped Unicode Line Separators in morgan Middleware

Amit Schendel
Amit Schendel
Senior Security Researcher

Sep 9, 2026·6 min read·18 visits

Executive Summary (TL;DR)

Unauthenticated remote attackers can inject unescaped Unicode line separators into HTTP headers, forcing Unicode-aware downstream log parsers to split records and forge false logging entries in morgan versions < 1.12.0.

An incomplete fix vulnerability (CVE-2026-15603) in the morgan HTTP request logger middleware for Node.js allows unauthenticated remote attackers to forge log entries. The flaw arises because the escaping mechanism does not neutralize Unicode line separator characters, enabling attackers to inject payloads that trick downstream log processors into splitting single log records into multiple logical entries.

Vulnerability Overview

The standard Express.js HTTP request logging middleware, morgan, relies on internal token serializers to output connection data. When processing incoming client requests, the middleware collects variables such as IP addresses, request paths, headers, and authenticated usernames. If these variables are printed without proper sanitation, raw data can corrupt the log output format.

This vulnerability, tracked as CVE-2026-15603, belongs to the log forging class (CWE-117). It represents an incomplete validation patch for a previous vulnerability, CVE-2026-5078, which resolved ASCII control character injection but overlooked specific Unicode characters. Consequently, unauthenticated remote attackers can inject specific Unicode line breaks to split log entries and construct spoofed system logs.

The attack surface exists on any HTTP endpoint utilizing the morgan middleware where user-controlled values (such as Basic Authentication usernames) are logged. This issue does not require specific authorization to exploit, exposing applications to untrusted remote network payloads.

Root Cause Analysis

The root cause lies in the selective character blacklisting within the internal escaping routine of morgan. While version 1.11.0 successfully sanitized standard C0 control codes, backslashes, and delete characters, it did not recognize non-ASCII Unicode line terminators. Specifically, characters like Next Line (U+0085), Line Separator (U+2028), and Paragraph Separator (U+2029) were left untouched in the raw output stream.

According to RFC 7230 and RFC 9110, the U+0085 character is technically valid within HTTP header fields as obsolete text. Node.js's standard HTTP parser processes and forwards these headers without validation failures, allowing them to reach the logging pipeline. When morgan writes these unescaped bytes, they are appended directly to the output medium.

Modern log ingestion engines, terminal viewers, and SIEM parsers are highly compliant with the Unicode Standard. These tools parse U+0085, U+2028, and U+2029 as physical newline boundaries. When the output stream is read, a single request entry containing these characters is interpreted as multiple distinct logical records.

Code Analysis

To comprehend the vulnerability, analyze the regular expression used in the vulnerable version 1.11.0. The escapeLogField function used a strict regex targeting C0 controls and backslashes:

// Vulnerable implementation in morgan v1.11.0
function escapeLogField (value) {
  if (value == null) return undefined
 
  // eslint-disable-next-line no-control-regex
  return String(value).replace(/[\u0000-\u001f\u007f\\]/g, function (ch) {
    switch (ch) {
      case '\\': return '\\\\'
      case '\b': return '\\b'
      // Other standard C0 ASCII escapes omitted
    }
  })
}

The patch introduced in version 1.12.0 corrected this regex by expanding the range to include C1 control characters (\u007f-\u009f) as well as the explicit separators \u2028 and \u2029. This blocks the injection vector completely:

// Patched implementation in morgan v1.12.0
function escapeLogField (value) {
  if (value == null) return undefined
 
  // eslint-disable-next-line no-control-regex
  return String(value).replace(/[\u0000-\u001f\u007f-\u009f\u2028\u2029\\]/g, function (ch) {
    switch (ch) {
      case '\\': return '\\\\'
      case '\b': return '\\b'
      // Safely escapes Unicode characters preventing log boundaries
    }
  })
}

Furthermore, the maintainers addressed systemic vulnerabilities in the token handling architecture. In previous versions, each logging token was individually responsible for escaping output. The patched version enforces a global wrapping boundary on all registered tokens, ensuring automatic escaping even if third-party components omit sanitization:

// Architectural wrapper added in v1.12.0
function token (name, fn) {
  morgan[name] = function tokenValue () {
    var value = fn.apply(this, arguments)
    return typeof value === 'string' ? escapeLogField(value) : value
  }
  return this
}

Exploitation Methodology

Exploiting this flaw requires an unauthenticated attacker to supply a crafted HTTP request header to a vulnerable server. The attack typically targets fields that are automatically extracted by log tokens, such as the Authorization header decoded by the :remote-user token. By structuring the username field appropriately, an attacker can inject custom records.

An attacker constructs a username containing the Next Line (U+0085) byte sequence, followed by an arbitrary string formatted to look like a standard log. For example, the string might contain a fabricated loopback IP, a successful authentication event, and a mock timestamp. This payload is encoded in Base64 and sent inside the standard Authorization header.

When morgan processes the request, it outputs the unescaped payload directly to stdout. Downstream aggregators, such as Fluentd or Logstash, identify the U+0085 sequence as a newline character. As a result, the aggregator splits the single output line, creating a truncated log for the attacker's actual connection, and a completely separate, forged log representing the injected payload.

No specialized toolsets are required to execute this exploit. Standard command-line clients like curl can transmit the required payload directly to any exposed endpoint on the target system.

Impact Assessment

The primary impact of this vulnerability is the compromise of log integrity. If malicious actors can write arbitrary lines to application logs, they can mask exploitation activities or spoof system behavior. This interferes directly with security auditing and post-incident investigation processes.

This technique aligns with MITRE ATT&CK Defense Evasion tactics, specifically Indicator Removal on Host (T1070). Attackers can obfuscate their presence by splitting logs to make automated warning messages appear associated with benign loopback actions. Additionally, Stored Data Manipulation (T1565.001) can trigger false alerts, causing operational disruptions.

The vulnerability is rated with a CVSS base score of 5.3 (Medium). While the exploit complexity is low and privileges are not required, the direct security boundaries of the target server are not violated. The impact is isolated entirely to the logging ecosystem and downstream ingestion layers.

Remediation & Mitigation

Remediation requires upgrading the morgan dependency to version 1.12.0 or later. This version enforces complete output neutralization for all registered logging tokens. Administrators can execute the upgrade using package managers to update the dependency tree.

npm install morgan@1.12.0

If patching cannot be performed immediately, a temporary mitigation can be implemented using intermediate middleware. A request preprocessing middleware can inspect and sanitize incoming headers before they are processed by the logger. This code must explicitly strip or replace characters in the C1 and Unicode separator ranges:

app.use((req, res, next) => {
  for (const header in req.headers) {
    if (typeof req.headers[header] === 'string') {
      req.headers[header] = req.headers[header].replace(/[\u0080-\u009f\u2028\u2029]/g, '');
    } 
  }
  next();
});

Additionally, firewalls and API gateways can be configured to drop requests containing these characters. Deploying regular expression signatures targeting [\x80-\x9f\u2028\u2029] within HTTP headers effectively mitigates remote exploitation attempts at the perimeter.

Official Patches

ExpressJS ProjectMorgan Release v1.12.0 Changelog and Release
GitHub AdvisoriesOfficial GitHub Security Advisory

Fix Analysis (3)

Technical Appendix

CVSS Score
5.3/ 10
CVSS:3.1/AV:N/AC:L/PR:N/UI:N/S:U/C:N/I:L/A:N
EPSS Probability
0.24%
Top 86% most exploited

Affected Systems

Node.js applications utilizing morgan logging middleware version < 1.12.0Systems parsing morgan console outputs with Unicode-aware log ingestion agents (Elasticsearch, Fluentd, Logstash)

Affected Versions Detail

Product
Affected Versions
Fixed Version
morgan
OpenJS Foundation
< 1.12.01.12.0
AttributeDetail
CWE IDCWE-117
Attack VectorNetwork (AV:N)
CVSS v3.15.3 (Medium)
EPSS Score0.00235 (14.34th percentile)
ImpactLog Forging & Injection (Integrity Loss)
Exploit StatusProof of Concept (PoC) available
KEV StatusNot listed

MITRE ATT&CK Mapping

T1565.001Stored Data Manipulation
Impact
T1070Indicator Removal on Host
Defense Evasion
CWE-117
Improper Output Neutralization for Logs

The software does not neutralize or incorrectly neutralizes output that is written to logs, allowing an attacker to forge log entries or inject malicious content.

Vulnerability Timeline

Morgan version 1.11.0 is released, addressing standard C0 ASCII log injection (CVE-2026-5078)
2026-06-02
Security fix commit is pushed to the repository main branch
2026-08-28
Morgan version 1.12.0 is officially released on npm
2026-08-28
CVE-2026-15603 and GitHub Security Advisory GHSA-jxfw-x594-9x9m are publicly published
2026-08-28

References & Sources

  • [1]https://www.cve.org/CVERecord?id=CVE-2026-15603
  • [2]https://nvd.nist.gov/vuln/detail/CVE-2026-15603
  • [3]https://cna.openjsf.org/security-advisories.html
  • [4]https://www.wiz.io/vulnerability-database/cve/cve-2026-15603

Attack Flow Diagram

Press enter or space to select a node. You can then use the arrow keys to move the node around. Press delete to remove it and escape to cancel.
Press enter or space to select an edge. You can then press delete to remove it or escape to cancel.

More Reports

•38 minutes ago•GHSA-FMC8-P6Q7-75CC
9.9

GHSA-fmc8-p6q7-75cc: Argument Injection in Canonical LXD Backup Compression Leads to Host Root Code Execution

GHSA-fmc8-p6q7-75cc (associated with CVE-2026-48755) is a critical argument injection vulnerability in Canonical LXD (github.com/canonical/lxd). The vulnerability occurs during instance and storage volume backup operations when processing the user-supplied compression_algorithm configuration parameter. While LXD validates the primary executable token against an allowlist of supported compression binaries, it fails to sanitize or restrict subsequent tokens parsed via shellquote.Split. These additional arguments are passed directly to exec.Command. An authenticated attacker with privileges to trigger backups can inject command-line flags for utilities like zstd to read staged files from a container filesystem and write them to arbitrary paths on the underlying host filesystem, such as /etc/cron.d/, achieving root-level arbitrary code execution on the host.

Amit Schendel
Amit Schendel
4 views•10 min read
•about 2 hours ago•GHSA-PJFF-C2WC-F6JM
9.9

CVE-2026-48769: Arbitrary File Write and Remote Code Execution via Trusted Image Hash in Canonical LXD and Linux Containers Incus

A critical path traversal vulnerability caused by improper input validation (CWE-20) exists in the direct image download handler of Canonical LXD and Linux Containers Incus. When an authenticated user requests an image import using the URL source type, the daemon reads the image fingerprint from an untrusted HTTP response header (`Incus-Image-Hash` or `LXD-Image-Hash`) without validating that it conforms to a SHA-256 format. This unvalidated string is concatenated directly into a filesystem path via `filepath.Join` prior to file creation and cryptographic verification, allowing directory traversal sequences to write arbitrary files on the host filesystem as root.

Alon Barad
Alon Barad
7 views•10 min read
•about 6 hours ago•CVE-2026-9639
6.5

CVE-2026-9639: Authenticated Denial of Service via Nil-Pointer Dereference in Canonical LXD Custom Volume Backup Import

CVE-2026-9639 (GHSA-j93m-3j9p-m5m8) is a null pointer dereference vulnerability in Canonical LXD affecting versions 5.0.0 through 5.21.4 and 6.0 through 6.8. The flaw resides in the (*lxdBackend).CreateCustomVolumeFromBackup method within lxd/storage/backend_lxd.go. An authenticated attacker with the can_create_storage_volumes permission can upload a crafted custom volume backup tarball that omits the expires_at field on a snapshot entry, triggering an unhandled SIGSEGV panic and terminating the LXD daemon.

Amit Schendel
Amit Schendel
6 views•9 min read
•about 7 hours ago•CVE-2026-33050
8.8

CVE-2026-33050: OS Command Injection in GeoNode Vector Upload Handler

An operating system command injection vulnerability (CWE-78) exists in GeoNode versions prior to 5.1.0. The vulnerability occurs in the vector upload processing pipeline when handling user-supplied geospatial files. By supplying a crafted layer name containing shell metacharacters, an authenticated attacker with basic data upload privileges can execute arbitrary commands on the underlying server or container hosting the GeoNode application and Celery worker processes.

Alon Barad
Alon Barad
6 views•9 min read
•about 8 hours ago•CVE-2026-46429
5.5

CVE-2026-46429: Unrestricted File Upload and Validation Bypass in GeoNode

GeoNode versions prior to 5.0.3 contain an unrestricted file upload vulnerability (CWE-434) within the document and dataset ingestion architecture. Authenticated low-privileged users can bypass upload validation via direct REST API interactions, file extension masquerading, metadata mutation via PATCH requests, or malicious archive submissions. This allows attackers to store and serve dangerous file types, alter on-disk file references, or trigger path traversal and resource exhaustion during archive extraction.

Amit Schendel
Amit Schendel
7 views•10 min read
•about 9 hours ago•CVE-2026-55649
6.3

CVE-2026-55649: Stored Cross-Site Scripting in GeoNode Document Metadata Abstract Field

CVE-2026-55649 is a stored Cross-Site Scripting (XSS) vulnerability in GeoNode versions prior to 5.0.3. The flaw exists because document abstract metadata fields are ingested via the metadata management pipeline and stored in the backend database without HTML sanitization or input neutralization. An authenticated attacker with privileges to create or edit document metadata can inject arbitrary HTML and JavaScript payloads into these fields. When another user, such as an administrator, views the affected document page or catalog listing, the unencoded payload is rendered into the Document Object Model (DOM) and executes within the victim's browser session.

Amit Schendel
Amit Schendel
7 views•9 min read