GitHub Advisoryadvisory · crates.io

GHSA-429q-fhh4-r6hj Anchor: `InterfaceAccount` allows account substitution between unexpected types

HIGH Published 2026-05-13 Modified 2026-05-19 Official page ↗
Ecosystem
crates.io
Packages
anchor-lang
Severity
High
CVSS vector
CVSS:4.0/AV:N/AC:L/AT:N/PR:N/UI:N/VC:N/VI:H/VA:N/SC:N/SI:N/SA:N
Weaknesses
CWE-20
Reviewed
2026-05-13

Affected packages

• crates.io anchor-lang: >= 1.0.0-rc.1, < 1.0.0-rc.2 → fixed in 1.0.0-rc.2

Description

Impact Any uses of `InterfaceAccount` allows another unexpected account type to be passed, after https://github.com/solana-foundation/anchor/pull/3837 disabled discriminator checking for this type. The bug was originally reported and fixed in https://github.com/solana-foundation/anchor/pull/4139, see that PR for more details. Patches https://github.com/solana-foundation/anchor/pull/4139 patched the issue and was released in `1.0.0-rc.2`. Users should upgrade to the latest released version of Anchor 1.0. References Bug landed in: https://github.com/solana-foundation/anchor/pull/3837 Bug fixed in: https://github.com/solana-foundation/anchor/pull/4139

Related

Weakness · CWE (1)

  • CWE-20 Improper Input Validation weakness

References