Broaden `Authorization`s from `SpendDescriptionV5::into_spend_description`
This enables the method to be used with bundles that have spend auth signatures and proofs, but not yet binding signatures.
This commit is contained in:
parent
03515178d6
commit
6527e792e4
|
@ -12,6 +12,11 @@ and this library adheres to Rust's notion of
|
||||||
`sapling_crypto::keys::EphemeralSecretKey`, matching the existing public APIs
|
`sapling_crypto::keys::EphemeralSecretKey`, matching the existing public APIs
|
||||||
that expose it.
|
that expose it.
|
||||||
|
|
||||||
|
### Changed
|
||||||
|
- `sapling_crypto::bundle::SpendDescriptionV5::into_spend_description` now
|
||||||
|
supports any `Authorization` for which the `SpendDescription` itself is fully
|
||||||
|
authorized.
|
||||||
|
|
||||||
## [0.3.0] - 2024-10-02
|
## [0.3.0] - 2024-10-02
|
||||||
|
|
||||||
### Changed
|
### Changed
|
||||||
|
|
|
@ -298,12 +298,15 @@ impl SpendDescriptionV5 {
|
||||||
Self { cv, nullifier, rk }
|
Self { cv, nullifier, rk }
|
||||||
}
|
}
|
||||||
|
|
||||||
pub fn into_spend_description(
|
pub fn into_spend_description<A>(
|
||||||
self,
|
self,
|
||||||
anchor: bls12_381::Scalar,
|
anchor: bls12_381::Scalar,
|
||||||
zkproof: GrothProofBytes,
|
zkproof: GrothProofBytes,
|
||||||
spend_auth_sig: redjubjub::Signature<SpendAuth>,
|
spend_auth_sig: redjubjub::Signature<SpendAuth>,
|
||||||
) -> SpendDescription<Authorized> {
|
) -> SpendDescription<A>
|
||||||
|
where
|
||||||
|
A: Authorization<SpendProof = GrothProofBytes, AuthSig = redjubjub::Signature<SpendAuth>>,
|
||||||
|
{
|
||||||
SpendDescription {
|
SpendDescription {
|
||||||
cv: self.cv,
|
cv: self.cv,
|
||||||
anchor,
|
anchor,
|
||||||
|
|
Loading…
Reference in New Issue