From 2f51b174db48efbdb5b8e805b59547cd3565c165 Mon Sep 17 00:00:00 2001 From: Diego Basch Date: Sat, 18 Jan 2014 23:40:24 -0800 Subject: [PATCH] removed unused imports --- src/main/java/com/fruitcat/bitcoin/BIP38.java | 9 +++++---- src/test/java/com/fruitcat/bitcoin/BIP38Test.java | 4 +--- 2 files changed, 6 insertions(+), 7 deletions(-) diff --git a/src/main/java/com/fruitcat/bitcoin/BIP38.java b/src/main/java/com/fruitcat/bitcoin/BIP38.java index d5fe604..bf17998 100644 --- a/src/main/java/com/fruitcat/bitcoin/BIP38.java +++ b/src/main/java/com/fruitcat/bitcoin/BIP38.java @@ -115,7 +115,7 @@ public static GeneratedKey encryptedKeyFromIntermediate(byte[] intermediate) thr } /** - * Generates a confirmation code for the party that requested the key with an intermediate passphrase. + * Generates a confirmation code for the party that requested the address with an intermediate passphrase. * @param flagByte * @param addressHash * @param ownerEntropy @@ -145,7 +145,8 @@ private static String confirm(byte flagByte, byte[] addressHash, byte [] ownerEn } /** - * Verifies a generated key. + * Verifies a generated key. TO DO: verify with just the confirmation code, + * so we don't have to decrypt the key to recalculate the address. * @param passphrase * @param generatedKey * @return @@ -397,8 +398,8 @@ else if (args[0].equals("-d")) { } private static void usage() { - System.out.println("Usage: BIP38 [-d|-e] [passphrase] [key]\nEncrypts or decrypts a key."); - System.out.println(" BIP38 [passphrase]\nGenerates a key encrypted with the passphrase."); + System.out.println("Usage: BIP38 [-d|-e] [passphrase] [key] - Encrypts or decrypts a key."); + System.out.println(" BIP38 [passphrase] - Generates a key encrypted with the passphrase."); } } \ No newline at end of file diff --git a/src/test/java/com/fruitcat/bitcoin/BIP38Test.java b/src/test/java/com/fruitcat/bitcoin/BIP38Test.java index d9576c6..2faf463 100644 --- a/src/test/java/com/fruitcat/bitcoin/BIP38Test.java +++ b/src/test/java/com/fruitcat/bitcoin/BIP38Test.java @@ -1,8 +1,6 @@ package com.fruitcat.bitcoin; import com.google.bitcoin.core.Base58; -import com.google.bitcoin.core.DumpedPrivateKey; -import com.google.bitcoin.params.MainNetParams; import org.testng.annotations.Test; import static org.testng.Assert.assertEquals; @@ -62,4 +60,4 @@ public void checkConfirmation() throws Exception { assert(BIP38.verify(testPass, gk)); assert(!BIP38.verify("garbage", gk)); } -} +} \ No newline at end of file