Pass tx builder RNG to spend_sig()

This commit is contained in:
Jack Grigg
2019-06-12 23:12:55 +01:00
parent 532299d46e
commit 17f6bbcc67
3 changed files with 9 additions and 7 deletions

View File

@@ -1002,8 +1002,11 @@ pub extern "system" fn librustzcash_sapling_spend_sig(
Err(_) => return false,
};
// Initialize secure RNG
let mut rng = OsRng;
// Do the signing
let sig = spend_sig(ask, ar, unsafe { &*sighash }, &JUBJUB);
let sig = spend_sig(ask, ar, unsafe { &*sighash }, &mut rng, &JUBJUB);
// Write out the signature
sig.write(&mut (unsafe { &mut *result })[..])