CVE-2026-45137
Description
Anchor is a framework providing several convenient developer tools for writing Solana programs. From 1.0.0 to before 1.0.2, an logic error causes anchor programs to accept any program id when requiring the system program id, causing false assumptions resulting in potential arbitrary cpi in programs that invoke system program instructions. In the TryFrom<&'a AccountInfo<'a>> implementation for Program<'a, T>, the id of T is compared with Pubkey::default() to check whether anchor should allow any executable account, or a specific account, because when no T is supplied, T defaults to (), which implements Id::id() by returning Pubkey::default(). This results in T = () and T = System (which has Pubkey::default() as the id) having the same behavior, both allow any executable account. Programs built with anchor assume that the anchor runtime verifies passed in programs of type Program<'a, System> are in fact the system program. This false assumption can lead to arbitrary CPI or payment bypassing when programs try making CPI calls to the system program using the passed in system program due to the fact that the attacker can pass in any program instead of the system program. This vulnerability is fixed in 1.0.2.
Predictions
Heuristic predictions, AS-IS, for prioritization only.
Mitigations
No mitigations published for this CVE yet.
The vendor-content worker queues fetches as references arrive (check back in a few minutes). Or โ if you've already worked around this in production โ publish your fix to the community-verified tier.
โ Propose a mitigation on Community โ Mitigations published via the community go through AI scoring + 2 human reviewers + 7-day silent objection window before landing here withsource_tier=community-verified.
Package impact
| Ecosystem | Package | Vulnerable | Fixed |
|---|---|---|---|
| crates.io | anchor-lang | | |
| crates.io | anchor-lang | >=1.0.0,<1.0.2 | 1.0.2 |
| RUST | anchor-lang | >= 1.0.0, < 1.0.2 | 1.0.2 |
References
- https://github.com/otter-sec/anchor/security/advisories/GHSA-c6rc-8jpp-2fgc
- https://github.com/solana-foundation/anchor/security/advisories/GHSA-c6rc-8jpp-2fgc
- https://github.com/solana-foundation/anchor
- https://github.com/solana-foundation/anchor/releases/tag/v1.0.2
- https://rustsec.org/advisories/RUSTSEC-2026-0144.html
- https://crates.io/crates/anchor-lang
- https://github.com/advisories/GHSA-c6rc-8jpp-2fgc
CWEs
CWE-20
Community-verified mitigations for this CVE will appear above when contributors publish them.
Verify integrity in audit chain (admin only). AS-IS.