ADVISORIES

Go Vulnerability Database

GO-2026-5005

Invoking key constraints not enforced in golang.org/x/crypto/ssh/agent

Details

The in-memory keyring returned by NewKeyring() silently accepted keys with the ConfirmBeforeUse constraint but never enforced it. The key would sign without any confirmation prompt, with no indication to the caller that the constraint was not in effect. NewKeyring() now returns an error when unsupported constraints are requested.

Affected packages

EcosystemPackageAffected versions
Gogolang.org/x/crypto
All versions before 0.52.0 (fixed in 0.52.0)

References