Description
When adding a key to a remote agent constraint extensions such as restrict-destination-v00@openssh.com were not serialized in the request. Destination restrictions were silently stripped when forwarding keys, allowing unrestricted use of the key on the remote host. The client now serializes all constraint extensions. Additionally, the in-memory keyring returned by NewKeyring() now rejects keys with unsupported constraint extensions instead of silently ignoring them.
Published: 2026-05-22
Score: n/a
EPSS: n/a
KEV: No
Impact: n/a
Action: n/a
AI Analysis

Impact

When a key that contains constraint extensions such as restrict-destination-v00@openssh.com is added to a remote ssh agent, the agent omitted these constraints during serialization. As a result, forwarded keys were stripped of all destination restrictions, allowing anyone who could forward a key to use it anywhere on the remote host without limitation. The vulnerability therefore enables an attacker who can forward an SSH key to abuse it beyond the intended constraints, potentially accessing services or executing commands on the remote system. The description does not provide a CVSS score but the impact on confidentiality, integrity and availability is significant because unrestrained keys can be used to impersonate legitimate users.

Affected Systems

The vulnerability affects the golang.org/x/crypto/ssh/agent component of the Go cryptographic library. No specific version numbers were listed, so any build of the agent prior to the fix that does not enforce constraint serialization may be vulnerable.

Risk and Exploitability

The EPSS score is not available and the issue is not listed in the CISA KEV catalog, so the exact likelihood of exploitation is unknown. However, the attack would require the ability to forward a key via ssh-agent, which can be achieved by a local user or a process with agent access. Because the flaw silently removes all constraint extensions, the attack vector is straightforward for anyone who can trigger key forwarding. The fix now serializes all constraint extensions and rejects unsupported ones, greatly reducing the window of opportunity for exploitation. Monitoring agent usage and restricting key forwarding remain prudent measures until a patched version is deployed.

Generated by OpenCVE AI on May 22, 2026 at 04:24 UTC.

Remediation

No vendor fix or workaround currently provided.

OpenCVE Recommended Actions

  • Upgrade golang.org/x/crypto to the latest release that includes the fixed key serialization and constraint rejection logic
  • Re‑configure your SSH deployment to disable key forwarding or to use Restrict mode explicitly
  • Audit existing scripts or applications that invoke ssh-agent to ensure they do not forward keys without proper constraints

Generated by OpenCVE AI on May 22, 2026 at 04:24 UTC.

Tracking

Sign in to view the affected projects.

Advisories

No advisories yet.

History

Fri, 22 May 2026 04:45:00 +0000

Type Values Removed Values Added
Weaknesses CWE-290

Fri, 22 May 2026 03:30:00 +0000

Type Values Removed Values Added
Description When adding a key to a remote agent constraint extensions such as restrict-destination-v00@openssh.com were not serialized in the request. Destination restrictions were silently stripped when forwarding keys, allowing unrestricted use of the key on the remote host. The client now serializes all constraint extensions. Additionally, the in-memory keyring returned by NewKeyring() now rejects keys with unsupported constraint extensions instead of silently ignoring them.
Title Invoking agent constraints dropped when forwarding keys in golang.org/x/crypto/ssh/agent
References

Subscriptions

No data.

cve-icon MITRE

Status: PUBLISHED

Assigner: Go

Published:

Updated: 2026-05-22T02:31:26.660Z

Reserved: 2026-04-07T18:13:03.529Z

Link: CVE-2026-39832

cve-icon Vulnrichment

No data.

cve-icon NVD

Status : Received

Published: 2026-05-22T04:16:22.663

Modified: 2026-05-22T04:16:22.663

Link: CVE-2026-39832

cve-icon Redhat

No data.

cve-icon OpenCVE Enrichment

Updated: 2026-05-22T04:30:25Z

Weaknesses