RedPallas, the Action Signature Scheme
1. Why This Chapter Exists
Orchard signs two things per bundle: the binding commitment with
the binding signature, and each Action's rk with a
spend-authorising signature. Both use RedDSA over Pallas
(RedPallas). The re-randomisable property lets each Action sign
under a one-time public key without revealing the wallet's
. After this chapter the reader understands the
difference between the two flavours and can derive their bases.
2. Definitions
Definition 2.1 (RedDSA Sign)
Over a prime-order group with base and order , with hash , to sign under secret with public :
- Sample nonce deterministically from and .
- .
- .
- .
- Output .
Definition 2.2 (Re-randomisation)
For randomiser , the randomised key is . The randomised secret is , and a signer with both can sign messages under .
Definition 2.3 (Orchard Flavours)
SpendAuth: base , signs the per-Action SIGHASH; key is .Binding: base (the value commitment randomness base), signs the bundle-level SIGHASH; key is from Chapter 13.
3. The Code
3.1 The Facade
loading...
Orchard wraps the upstream
reddsa crate. The
two marker types SpendAuth and Binding parametrise the same
implementation over the two bases.
3.2 Use Sites
- Per-Action
rkderivation insrc/builder.rs(sampling and constructing $\mathsf{rk} = \mathsf{ak}- [\alpha] \mathcal{G}_{\mathsf{ak}}$).
- In-circuit constraint in
src/circuit.rs. - Binding signature key derivation in
src/bundle.rs.
4. Failure Modes
- Identity
rk. #492 added an explicit rejection of identityrkinAction::from_parts. The defence catches a malformed bundle that would otherwise pass verification under a special case of the Schnorr equation. - Nonce reuse. RedDSA derives the nonce deterministically from and the message; a buggy override that resamples randomly opens the door to a discrete-log recovery attack on .
- Wrong base. Signing a
SpendAuthmessage with theBindingbase or vice versa produces a verifier that accepts unrelated values. The marker types prevent this at compile time; do not bypass them. alpha = 0. If , and unlinkability is lost. The builder must sample ; an override that allows zero is a privacy bug.
5. Spec Pointers
- Zcash Protocol Specification, Section 5.4.7: RedDSA, RedJubjub, and RedPallas instantiation.
- Pointcheval-Sanders re-randomisable signatures: the underlying construction.
reddsa: the upstream Rust implementation.
6. Exercises
- Verify on paper that holds when . Show that the verifier does not need .
- The two marker types
SpendAuthandBindingcannot be confused at compile time. Readsrc/primitives/redpallas.rsand identify the trait bound that enforces the distinction. - Code task. Add a unit test in
src/primitives/redpallas.rsthat constructs an identity-valuedVerificationKey<SpendAuth>and asserts that parsing returns an error. Runcargo test --lib redpallas::.
7. Further Reading
- Sapling protocol paper for the historical RedJubjub design that RedPallas mirrors.
- The audit reports linked from Chapter 17, which review the binding signature derivation in detail.