ZEBRA: Consensus divergence via P2SH sigop undercount in pure-Rust disabled-opcode parser
Key facts
- Attack vector
- Network
- Privileges required
- None
- User interaction
- None
- Attack complexity
- Low
- Attack requirements
- None
- Impact type
- —
- Confidentiality · integrity · availability
- None · High · None
- Fix status
- Fixed
Attack profile from CVSS 4.0 · CNA. Fix status from CNA and GitHub.
Summary
ZEBRA is a Zcash node written entirely in Rust. Prior to 4.5.0, Zebra can accept a block that zcashd rejects because the P2SH signature-operation counter undercounts redeem scripts containing a disabled opcode followed by signature opcodes. In zebra-script/src/lib.rs, p2sh_input_sigop_count used the pure-Rust script::Code::sig_op_count path, whose try_fold parser stops at disabled opcodes such as OP_CODESEPARATOR and returns only the partial count accumulated before the error. The zcashd reference implementation continues static signature-operation counting through disabled opcodes, so an attacker can broadcast P2SH spends that Zebra counts below MAX_BLOCK_SIGOPS while zcashd counts above the 20,000-operation limit. If a Zebra miner includes those transactions, Zebra validators accept the block while zcashd validators reject it, creating a consensus chain split that affects network integrity and availability without requiring the attacker to produce a block. This issue is fixed in version 4.5.0.
Why it matters now
SSVC decision points
CISA ADP · SSVC 2.0.3
- Exploitation
- None
- Automatable
- Yes
- Technical impact
- Partial
The decision (Track, Attend, Act) also depends on your mission and well-being impact; see CISA's SSVC guide.
Affected products
| Vendor | Product | Affected versions | Fixed in | Status | Source |
|---|---|---|---|---|---|
| ZcashFoundation | zebra | before 4.5.0 | 4.5.0 | Patch available | CNA |
| — | zebra-script (crates.io) | before 7.0.0 | 7.0.0 | Patch available | GHSA-gf9r-m956-97qx |
| — | zebrad (crates.io) | before 4.5.0 | 4.5.0 | Patch available | GHSA-gf9r-m956-97qx |
- zebra VendorZcashFoundation Affected before 4.5.0 Fixed in 4.5.0 Patch available CNA
- zebra-script (crates.io) Vendor— Affected before 7.0.0 Fixed in 7.0.0 Patch available GHSA-gf9r-m956-97qx
- zebrad (crates.io) Vendor— Affected before 4.5.0 Fixed in 4.5.0 Patch available GHSA-gf9r-m956-97qx
Remediation
- Fix · CNA zebra (ZcashFoundation) Fixed in 4.5.0
- Fix · GHSA-gf9r-m956-97qx zebra-script (crates.io) Fixed in 7.0.0 Advisory →
- Fix · GHSA-gf9r-m956-97qx zebrad (crates.io) Fixed in 4.5.0 Advisory →
Timeline
- 2026-10-02 Threatist record created from CVE-2026-52735
- 2026-10-03 Alias added: GHSA-gf9r-m956-97qx
References
Other 7
- https://github.com/ZcashFoundation/zebra/security/advisories/GHSA-gf9r-m956-97qx
- https://github.com/ZcashFoundation/zebra/commit/1440b43ca7df59aca948090d45117557b217a6cd
- https://github.com/ZcashFoundation/zebra/releases/tag/v4.5.0
- https://github.com/AlfredoG87/zcash_script/blob/v0.4.4/src/script/iter.rs#L104-L115
- https://github.com/ZcashFoundation/zebra
- https://github.com/ZcashFoundation/zebra/blob/d4cd662c716382f6397d2a730148025a1ca79fec/zebra-consensus/src/block.rs#L140
- https://github.com/ZcashFoundation/zebra/blob/d4cd662c716382f6397d2a730148025a1ca79fec/zebra-script/src/lib.rs#L383-L400
More ZcashFoundation vulnerabilities
- TI-2026-66079 Zebra before 4.4.0 Consensus Split via SIGHASH_SINGLE Missing-Output Handling CVSS 4.0HIGH 8.3
- TI-2026-37850 ZEBRA: Mempool transaction admission denial via single-peer inbound queue saturation CVSS 3.1MEDIUM 5.3
- TI-2026-71182 Improper block validation in Zebra gossip lets peers drop new blocks CVSS 4.0MEDIUM 6.3
- TI-2026-29537 Zebra: addr/addrv2 Deserialization Resource Exhaustion CVSS 4.0MEDIUM 6.3
- TI-2026-86702 Incomplete cleanup in Zebra lets peers stall initial sync CVSS 4.0HIGH 8.7
- TI-2026-86701 Quadratic signature hashing in Zcash Zebra enables denial of service CVSS 4.0HIGH 8.7
Sources
- CVE-2026-52735 · CVE Program
- CVE-2026-52735 · NVD
- FIRST EPSS
- GHSA-gf9r-m956-97qx · GitHub Advisory Database · CC BY 4.0
This product uses the NVD API but is not endorsed or certified by the NVD. Sources and licences