3
0
mirror of https://github.com/Qortal/altcoinj.git synced 2025-01-31 15:22:16 +00:00

WalletTool: recognize private key format properly.

Resolves issue 390.
This commit is contained in:
Mike Hearn 2013-11-24 19:10:34 +01:00
parent 3569dfe2d4
commit 95fc6d7245

View File

@ -688,7 +688,7 @@ public class WalletTool {
} }
if (options.has("privkey")) { if (options.has("privkey")) {
String data = (String) options.valueOf("privkey"); String data = (String) options.valueOf("privkey");
if (data.charAt(0) == 'L') { if (data.startsWith("5J") || data.startsWith("5H") || data.startsWith("5K")) {
DumpedPrivateKey dpk; DumpedPrivateKey dpk;
try { try {
dpk = new DumpedPrivateKey(params, data); dpk = new DumpedPrivateKey(params, data);