You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
Copy file name to clipboardExpand all lines: lightning/src/chain/keysinterface.rs
+9-2
Original file line number
Diff line number
Diff line change
@@ -1072,7 +1072,9 @@ impl KeysManager {
1072
1072
// We only seriously intend to rely on the channel_master_key for true secure
1073
1073
// entropy, everything else just ensures uniqueness. We rely on the unique_start (ie
1074
1074
// starting_time provided in the constructor) to be unique.
1075
-
let child_privkey = self.channel_master_key.ckd_priv(&self.secp_ctx,ChildNumber::from_hardened_idx(chan_id asu32).expect("key space exhausted")).expect("Your RNG is busted");
1075
+
let child_privkey = self.channel_master_key.ckd_priv(&self.secp_ctx,
1076
+
ChildNumber::from_hardened_idx((chan_id asu32) % (1 << 31)).expect("key space exhausted")
0 commit comments