3
0
mirror of https://github.com/Qortal/altcoinj.git synced 2025-02-12 10:15:52 +00:00

Fix key derivation

This commit is contained in:
Devrandom 2014-02-05 12:47:36 -08:00
parent 3dfaf54e28
commit e2ebe69aae

View File

@ -95,7 +95,7 @@ public class DeterministicHierarchy implements Serializable {
throw new IllegalArgumentException(String.format("No key found for %s path %s.",
relativePath ? "relative" : "absolute", HDUtils.formatPath(path)));
checkArgument(absolutePath.size() > 0, "Can't derive the master key: nothing to derive from.");
DeterministicKey parent = get(absolutePath.subList(0, absolutePath.size() - 1), relativePath, true);
DeterministicKey parent = get(absolutePath.subList(0, absolutePath.size() - 1), false, true);
putKey(HDKeyDerivation.deriveChildKey(parent, absolutePath.get(absolutePath.size() - 1)));
}
return keys.get(absolutePath);