A subclass of BTC::Address that represents a serialized private key in a Wallet Import Format (WIF), also known as "sipa format".
Returns a new WIF by parsing a Base58Check-encoded string (must be a valid WIF string).
Returns a new WIF with the 32-byte binary string private_key
.
If network
is not specified, BTC::Network.default is used.
If public_key_compressed
is not specified, false
is used.
Returns a new WIF with key.private_key.
Raises ArgumentError
if key
does not have a private_key
component.
If network
is not specified, key.network
is used (instance of BTC::Network).
If public_key_compressed
is not specified, key.public_key_compressed
is used.
Returns a BTC::Key instance represented by the WIF. The returned object inherits network
and public_key_compressed
attributes.
Returns raw binary 32-byte private key stored in WIF.
Returns string representation of the WIF in Base58Check encoding.
Returns BTC::PublicKeyAddress instance corresponding to this key's public key.
Returns true
or false
depending on whether the corresponding public key should be compressed (33 bytes) or not (65 bytes).
Returns a BTC::Network instance based on the version prefix of the address (mainnet or testnet).
Returns an integer value of the one-byte prefix of the WIF encoding. 128 for mainnet, 239 for testnet.
Returns false
.
Returns false
.