mirror of
https://github.com/sparrowwallet/drongo.git
synced 2024-12-26 01:56:44 +00:00
allow zero length paths when parsing psbt key derivations
This commit is contained in:
parent
6c03c4106a
commit
f46d627755
1 changed files with 1 additions and 1 deletions
|
@ -64,7 +64,7 @@ public class PSBTEntry {
|
||||||
throw new PSBTParseException("Invalid master fingerprint specified: " + masterFingerprint);
|
throw new PSBTParseException("Invalid master fingerprint specified: " + masterFingerprint);
|
||||||
}
|
}
|
||||||
if(data.length < 8) {
|
if(data.length < 8) {
|
||||||
throw new PSBTParseException("Invalid key derivation specified: not enough bytes");
|
return new KeyDerivation(masterFingerprint, "m");
|
||||||
}
|
}
|
||||||
List<ChildNumber> bip32pathList = readBIP32Derivation(Arrays.copyOfRange(data, 4, data.length));
|
List<ChildNumber> bip32pathList = readBIP32Derivation(Arrays.copyOfRange(data, 4, data.length));
|
||||||
String bip32path = KeyDerivation.writePath(bip32pathList);
|
String bip32path = KeyDerivation.writePath(bip32pathList);
|
||||||
|
|
Loading…
Reference in a new issue