Class BIP38PrivateKey

  • All Implemented Interfaces:
    java.io.Serializable, java.lang.Cloneable

    public class BIP38PrivateKey
    extends PrefixedChecksummedBytes
    Implementation of BIP 38 passphrase-protected private keys. Currently, only decryption is supported.
    See Also:
    Serialized Form
    • Field Detail

      • ecMultiply

        public final boolean ecMultiply
      • compressed

        public final boolean compressed
      • hasLotAndSequence

        public final boolean hasLotAndSequence
      • addressHash

        public final byte[] addressHash
      • content

        public final byte[] content
    • Method Detail

      • fromBase58

        public static BIP38PrivateKey fromBase58​(NetworkParameters params,
                                                 java.lang.String base58)
                                          throws AddressFormatException
        Construct a password-protected private key from its Base58 representation.
        Parameters:
        params - The network parameters of the chain that the key is for.
        base58 - The textual form of the password-protected private key.
        Throws:
        AddressFormatException - if the given base58 doesn't parse or the checksum is invalid
      • toBase58

        public java.lang.String toBase58()
        Returns the base58-encoded textual form, including version and checksum bytes.
        Returns:
        textual form
      • toString

        public java.lang.String toString()
        Overrides:
        toString in class java.lang.Object