Cloudanix VulnDB

CVE-2026-42507

Medium · 5.3

CVSS

5.3

EPSS

0.4%

Published

Jun 2, 2026

CISA due date

—

Cloudanix analysis

Next patch cycle SSVC: Track

A software bug can let someone send specially crafted bad input that makes application logs show misleading messages.

Exploitation
Remote Unauthenticated
Attacker needs
None
Complexity
Low
Impact
Data Tampering
Component
Library
Class
Improper Input Validation
Remediation
Upgrade
Effort
Medium
Patch risk
Low

What it actually does

CVE-2026-42507 is an improper input validation issue in Go's net/textproto package. When certain parsing or protocol-handling functions return errors, they may include attacker-controlled input directly in the error message. If an application prints, stores, forwards, or alerts on those errors without additional sanitization, an attacker can inject misleading content such as forged log lines, fake headers, terminal control characters, or alert text. The vulnerability does not directly provide code execution, privilege escalation, or data disclosure, but it can undermine log integrity and incident analysis by polluting error output with attacker-supplied content.

Why it matters to the business

Organizations using affected Go versions or applications built with affected Go standard library code may have untrusted network input reflected into logs or operational error messages. The main business risk is reduced trust in logs and monitoring: attackers could hide activity, create false leads, trigger misleading alerts, or complicate investigations. The CVSS score is moderate, EPSS is low and stable, it is not listed in CISA KEV, and there is no known mature exploit, so this is generally a hygiene and defense-in-depth update rather than an emergency patch unless the affected application logs externally supplied protocol input into security-relevant systems.

How an attack unfolds

An attacker interacts with a Go-based service or client path that uses net/textproto to parse text-based protocol data, such as HTTP-like headers or other MIME-style text protocol fields. The attacker deliberately sends malformed input that causes net/textproto to return an error. Because the error may include the original malformed input, the attacker crafts that input to contain embedded newline characters, carriage returns, escape sequences, or text resembling legitimate log entries. If the application records the error as-is, the resulting logs or console output may contain attacker-created content that appears to be produced by the application or infrastructure. This can be used to forge events, obscure true source activity, mislead responders, or poison downstream log analytics, but exploitation depends on the application exposing a reachable parsing path and logging or displaying the returned error without sanitization.

How to fix it

Upgrade to a Go release that includes the fix once available from the Go project or the relevant vendor distribution, then rebuild and redeploy affected applications so they no longer embed unsanitized attacker-controlled input in net/textproto error messages. If exact fixed versions are not yet available in the provided inventory, track official Go security release notes for CVE-2026-42507 and apply the first patched release for all supported Go branches in use. As compensating controls, sanitize or encode error messages before logging, strip or escape carriage returns, line feeds, ANSI escape sequences, and other control characters from untrusted input, avoid logging raw parser errors at high trust levels, and configure log pipelines to preserve event boundaries and reject multiline injection where possible.

How to confirm the fix worked

Confirm the deployed application was rebuilt with a Go toolchain or runtime source tree containing the fix for CVE-2026-42507. Review build metadata using commands such as `go version -m <binary>` where applicable, SBOMs, container image metadata, and CI build records to identify the Go version used. Test representative parsing paths by submitting malformed text-protocol input containing carriage returns, line feeds, and obvious marker strings, then verify that logs and error outputs do not create forged log entries or preserve raw control characters. Validate that log shippers and SIEM parsers treat the event as a single sanitized record and do not split attacker-controlled content into separate events.

Typical attack path

  1. Identify a Go-based service, proxy, mail-related component, API client, or other application path that processes text-protocol style input using net/textproto.
  2. Send malformed text protocol input designed to trigger a parsing error.
  3. Embed misleading content in the malformed input, such as newline-delimited fake log entries, forged severity labels, terminal escape sequences, or fabricated request metadata.
  4. Cause the application to return, print, or log the generated error message.
  5. Rely on unescaped logging, alerting, terminal display, or log aggregation to preserve the injected content.
  6. Use the polluted logs or alerts to confuse monitoring, create false evidence, hide related activity, or delay incident response.

How to detect it

To assess prior exploitation, review application logs, reverse proxy logs, protocol parser error logs, container stdout/stderr, systemd journal entries, SIEM-normalized events, and log shipper records for malformed text-protocol parsing errors that contain embedded line breaks, forged timestamps, fake severity levels, ANSI escape sequences, or unexpected header-like content. Focus on internet-facing Go services and any application logs that include errors from text protocol parsing. Look for single requests that appear to generate multiple log records, log entries with inconsistent source metadata, impossible timestamp ordering, duplicated prefixes inside message bodies, or event fields containing raw carriage return and line feed characters. Because this flaw does not create a unique file, process, registry key, or network artifact, detection is based on suspicious log content and correlation between raw ingress traffic and downstream log records. If named threat actor activity is later reported, add their known infrastructure, user agents, and payload patterns to hunts, but no threat actors are currently identified in the provided data.

  • \r\nINFO
  • \r\nWARN
  • \r\nERROR
  • \nINFO
  • \nWARN
  • \nERROR
  • \u001b[
  • malformed MIME header
  • malformed header line
  • invalid header field
  • net/textproto
  • textproto.ProtocolError

What your security team should do

  • Inventory externally reachable Go applications and services that parse text-based protocol input and generate logs from parser errors.
  • Prioritize patching applications where logs feed security monitoring, compliance evidence, automated alerting, fraud detection, or operational decision-making.
  • Track official Go security advisories for the fixed release and rebuild affected binaries after upgrading the Go toolchain or vendor package.
  • Implement centralized log sanitization rules that escape or remove CR, LF, ANSI escape, and other control characters from untrusted fields.
  • Harden log ingestion pipelines to prevent multiline log forgery and to preserve original event boundaries.
  • Search recent logs for signs of log injection attempts, especially malformed protocol inputs followed by suspicious new log lines or forged severity labels.
  • Treat this as moderate priority in normal patch cycles unless active abuse is observed or the affected application is security-critical.

The record

When returning errors, functions in the net/textproto package would include its input as part of the error. This might allow an attacker to inject misleading content to errors that are printed or logged.

Affected packages

Ecosystem Package Introduced Fixed
openSUSE:Leap 16.0 go1.25 0 1.25.11-160000.1.1
openSUSE:Leap 16.0 go1.26 0 1.26.4-160000.1.1
openSUSE:Tumbleweed go1.25 0 1.25.11-1.1
openSUSE:Tumbleweed go1.26 0 1.26.4-1.1
openSUSE:Tumbleweed rclone 0 1.74.3-1.1

Related vulnerabilities