CVE-2026-42507

Arbitrary inputs are included in errors without any escaping in net/textproto

Published Jun 2, 2026 CVSS 3.1 · 5.3 Medium EPSS < 1% KEV · Not listed
Description
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.

Analysis

AI-generated

Technical impact

The flaw is in Go’s net/textproto package where error messages embed input values without escaping. An attacker who can influence those inputs can inject arbitrary content into error messages that may be displayed to users or written to logs. This raises the risk of misleading error output or the disclosure of sensitive information.

Affected Systems

It affects the Go standard library component net/textproto. No specific version guidance is provided, so any Go version that includes the current implementation is potentially vulnerable until a fix is released.

Risk and Exploitability

EPSS score is < 1% and the vulnerability is not listed in the CISA Known Exploited Vulnerabilities catalog; CVSS score is 5.3. The vulnerability is likely exploitable in any context where an application uses net/textproto to handle protocol data and forwards error messages to clients or logs them. The likely attack vector is remote, leveraged through the protocol handled by the application, and depends on whether the error content is exposed to users or captured in audit trails. Despite the moderate CVSS score of 5.3, the potential for log or output injection makes this a high‑impact concern for systems that rely on accurate error reporting.

Remediation

No solution or workaround provided in the CVE record.

OpenCVE Recommended Actions

  • Upgrade to the latest Go release that includes the fix for GO-2026-5039 or apply any vendor‑supplied patch to net/textproto
  • Modify your application’s error handling to escape or remove user input before including it in error messages, addressing the log injection weakness
  • Configure your service to return generic error responses to clients while logging detailed errors in a sanitized, internal context

Generated by OpenCVE AI on June 18, 2026 at 22:35 UTC.

Tracking

Sign in to view the affected projects.

Advisories

No advisories available
History
Type Values Removed Values Added
Weaknesses CWE-20
CWE-532
Type Values Removed Values Added
Weaknesses CWE-20
CWE-532
Type Values Removed Values Added
Weaknesses CWE-107
Type Values Removed Values Added
Metrics cvssV3_1

{'score': 5.3, 'vector': 'CVSS:3.1/AV:N/AC:L/PR:N/UI:N/S:U/C:N/I:L/A:N'}

ssvc

{'options': {'Automatable': 'yes', 'Exploitation': 'none', 'Technical Impact': 'partial'}, 'version': '2.0.3'}

Type Values Removed Values Added
First Time appeared Golang
Golang net
Vendors & Products Golang
Golang net
Type Values Removed Values Added
Weaknesses CWE-107
Type Values Removed Values Added
Description 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.
Title Arbitrary inputs are included in errors without any escaping in net/textproto
References
Weaknesses
  • CWE-117

    Improper Output Neutralization for Logs

Sources

Status
PUBLISHED
Assigner
Go
Published
Updated
Jun 3, 2026, 7:04 PM
Reserved
Apr 28, 2026, 12:21 AM
Status
Awaiting Analysis
Published
Jun 2, 2026, 11:16 PM
Modified
Jul 22, 2026, 7:10 PM
Severity
Moderate
Public date
Jun 2, 2026, 10:01 PM