Security context

What an agent needs to avoid regressing past fixes and find the next vuln in this repo.

phala-network/phala-blockchain
master @ 407a962
28
Fixes
0
CVEs
HIGH
Peak severity
52.2%
Coverage
Highlights
Auth Bypass: 15 prior fixes. Scrutinize any change in this area.
pallets/phala/src/registry.rs: most-fixed (4 issues). Treat as high-risk during review.
24 high-severity fixes in this history; regressions here are high-impact.
Recurring patterns

The bug types that recur here, drawn from past fixes, not open vulnerabilities.

Auth Bypass: Critical vulnerability where unsigned transactions in the claim pallet bypassed signature verification, allowing unauthorized claims against user balances. The fix restricted this by enforcing rigorous validation within the validate_unsigned transaction pool hook.
Cryptographic Weakness: Weaknesses in Gatekeeper key derivation and random number generation allowed potential predictability and signature malleability. Fixes introduced deterministic derivation with constant contexts and transitioned random generators from sr25519 signatures to dedicated derived keys.
Memory Corruption: Memory safety violations within the enclave, specifically using incorrect size arguments or misusing transmute_copy, could lead to out-of-bounds corruption or enclave memory leakage.