Package org.bitcoinj.crypto
package org.bitcoinj.crypto
The crypto package contains classes that work with key derivation algorithms like scrypt (passwords to AES keys),
BIP 32 hierarchies (chains of keys from a root seed), X.509 utilities for the payment protocol and other general
cryptography tasks. It also contains a class that can disable the (long since obsolete) DRM Java/US Govt imposes
on strong crypto. This is legal because Oracle got permission to ship strong AES to everyone years ago but hasn't
bothered to actually remove the logic barriers.
-
ClassDescriptionImplementation of BIP 38 passphrase-protected private keys.This is just a wrapper for the i (child number) as per BIP 32 with a boolean getter for the most significant bit and a getter for the actual 0-based child number.A DeterministicHierarchy calculates and keeps a whole tree (hierarchy) of keys originating from a single root key.A deterministic key is a node in a
DeterministicHierarchy
.Provides a uniform way to access something that can be optionally encrypted with aKeyCrypter
, yielding anEncryptedData
, and which can have a creation time associated with it.An instance of EncryptedData is a holder for an initialization vector and encrypted bytes.Implementation of the BIP 32 deterministic wallet child key generation algorithm.HD Key derivation path.Static utilities used in BIP 32 Hierarchical Deterministic Wallets (HDW).A KeyCrypter can be used to encrypt and decrypt a message.Exception to provide the following:This exception is thrown when a private key or seed is decrypted, the decrypted message is damaged (e.g.This exception is thrown when a private key or seed is decrypted, it doesn't match its public key any more.This class encrypts and decrypts byte arrays and strings using scrypt as the key derivation function and AES for the encryption.A wrapper around ECPoint that delays decoding of the point for as long as possible.A SecureRandom implementation that is able to override the standard JVM provided implementation, and which simply serves random numbers by reading /dev/urandom.A MnemonicCode object may be used to convert between binary seed values and lists of words per the BIP 39 specificationExceptions thrown by the MnemonicCode module.Thrown when a list of MnemonicCode words fails the checksum check.Thrown when an argument to MnemonicCode is the wrong length.Thrown when a word is encountered which is not in the MnemonicCode's word list.This is a clean-room implementation of PBKDF2 using RFC 2898 as a reference.A TransactionSignature wraps anECKey.ECDSASignature
and adds methods for handling the additional SIGHASH mode byte that is used.An implementation of TrustStoreLoader handles fetching a KeyStore from the operating system, a file, etc.X509Utils provides tools for working with X.509 certificates and keystores, as used in the BIP 70 payment protocol.