Get desktop application:
View/edit binary Protocol Buffers messages
* Data attached to a Key message that defines the data needed by the BIP32 deterministic key hierarchy algorithm.
Used in:
Random data that allows us to extend a key. Without this, we can't figure out the next key in the chain and should just treat it as a regular ORIGINAL type key.
The path through the key tree. Each number is encoded in the standard form: high bit set for private derivation and high bit unset for public derivation.
How many children of this key have been issued, that is, given to the user when they requested a fresh key? For the parents of keys being handed out, this is always less than the true number of children: the difference is called the lookahead zone. These keys are put into Bloom filters so we can spot transactions made by clones of this wallet - for instance when restoring from backup or if the seed was shared between devices. If this field is missing it means we're not issuing subkeys of this key to users.
* Flag indicating that this key is a root of a following chain. This chain is following the next non-following chain. Following/followed chains concept is used for married keychains, where the set of keys combined together to produce a single P2SH multisignature address
Used in:
The initialisation vector for the AES encryption (16 bytes)
The encrypted private key
* An exchange rate between Bitcoin and some fiat currency.
Used in:
This much of satoshis (1E-8 fractions)…
…is worth this much of fiat (1E-4 fractions).
ISO 4217 currency code (if available) of the fiat currency.
* An extension to the wallet
Used in:
like org.whatever.foo.bar
If we do not understand a mandatory extension, abort to prevent data loss. For example, this could be applied to a new type of holding, such as a contract, where dropping of an extension in a read/write cycle could cause loss of value.
* A key used to control Bitcoin spending. Either the private key, the public key or both may be present. It is recommended that if the private key is provided that the public key is provided too because deriving it is slow. If only the public key is provided, the key can only be used to watch the blockchain and verify transactions, and not for spending.
Used in:
Either the private EC key bytes (without any ASN.1 wrapping), or the deterministic root seed. If the secret is encrypted, or this is a "watching entry" then this is missing.
If the secret data is encrypted, then secret_bytes is missing and this field is set.
The public EC key derived from the private key. We allow both to be stored to avoid mobile clients having to do lots of slow EC math on startup. For DETERMINISTIC_MNEMONIC entries this is missing.
User-provided label associated with the key.
Timestamp stored as millis since epoch. Useful for skipping block bodies before this point. Only reason it's optional is that some very old wallets don't have this data.
The seed for a deterministic key hierarchy. Derived from the mnemonic, but cached here for quick startup. Only applicable to a DETERMINISTIC_MNEMONIC key entry.
Encrypted version of the seed
Used in:
* Unencrypted - Original bitcoin secp256k1 curve
* Encrypted with Scrypt and AES - Original bitcoin secp256k1 curve
* Not really a key, but rather contains the mnemonic phrase for a deterministic key hierarchy in the private_key field. The label and public_key fields are missing. Creation timestamp will exist.
* A key that was derived deterministically. Note that the root seed that created it may NOT be present in the wallet, for the case of watching wallets. A deterministic key may or may not have the private key bytes present. However the public key bytes and the deterministic_key field are guaranteed to exist. In a wallet where there is a path from this key up to a key that has (possibly encrypted) private bytes, it's expected that the private key can be rederived on the fly.
Used in:
Used in:
Timestamp stored as millis since epoch. Useful for skipping block bodies before this point when watching for scripts on the blockchain.
* The parameters used in the scrypt key derivation function. The default values are taken from http://www.tarsnap.com/scrypt/scrypt-slides.pdf. They can be increased - n is the number of iterations performed and r and p can be used to tweak the algorithm - see: http://stackoverflow.com/questions/11126315/what-are-optimal-scrypt-work-factors
Used in:
Salt to use in generation of the wallet password (8 bytes)
CPU/ memory cost parameter
Block size parameter
Parallelisation parameter
* A simple key->value mapping that has no interpreted content at all. A bit like the extensions mechanism except an extension is keyed by the ID of a piece of code that's loaded with the given data, and has the concept of being mandatory if that code isn't found. Whereas this is just a blind key/value store.
Used in:
Used in:
See Wallet.java for detailed description of pool semantics
If pool is not present, that means either: - This Transaction is either not in a wallet at all (the proto is re-used elsewhere) - Or it is stored but for other purposes, for example, because it is the overriding transaction of a double spend. - Or the Pool enum got a new value which your software is too old to parse.
The nLockTime field is useful for contracts.
millis since epoch the transaction was last updated
A list of blocks in which the transaction has been observed (on any chain). Also, a number used to disambiguate ordering within a block.
Data describing where the transaction is in the chain.
Exchange rate that was valid when the transaction was sent.
Memo of the transaction. It can be used to record the memo of the payment request that initiated the transaction.
* This is a bitfield oriented enum, with the following bits: bit 0 - spent bit 1 - appears in alt chain bit 2 - appears in best chain bit 3 - double-spent bit 4 - pending (we would like the tx to go into the best chain) Not all combinations are interesting, just the ones actually used in the enum.
Used in:
In best chain, not all outputs spent
In best chain, all outputs spent
In non-best chain, not our transaction
Double-spent by a transaction in the best chain
Our transaction, not in any chain
In non-best chain, our transaction
For what purpose the transaction was created.
Used in:
Old wallets or the purpose genuinely is a mystery (e.g. imported from some external source).
Created in response to a user request for payment. This is the normal case.
Created automatically to move money from rotated keys.
Stuff used by Lighthouse.
In future: de/refragmentation, privacy boosting/mixing, child-pays-for-parent fees, etc.
* A description of the confidence we have that a transaction cannot be reversed in the future. Parsing should be lenient, since this could change for different applications yet we should maintain backward compatibility.
Used in:
This is optional in case we add confidence types to prevent parse errors - backwards compatible.
If type == BUILDING then this is the chain height at which the transaction was included.
If set, hash of the transaction that double spent this one into oblivion. A transaction can be double spent by multiple transactions in the case of several inputs being re-spent by several transactions but we don't bother to track them all, just the first. This only makes sense if type = DEAD.
If type == BUILDING then this is the depth of the transaction in the blockchain. Zero confirmations: depth = 0, one confirmation: depth = 1 etc.
Where did we get this transaction from? Knowing the source may help us to risk analyze pending transactions.
Used in:
We don't know where it came from, or this is a wallet from the future.
We received it from a network broadcast. This is the normal way to get payments.
We made it ourselves, so we know it should be valid.
Used in:
In best chain. If and only if appeared_at_height is present.
Unconfirmed and sitting in the networks memory pools, waiting to be included in the chain.
Deprecated: equivalent to PENDING.
Either if overriding_transaction is present or transaction is dead coinbase
Used in:
Hash of the transaction this input is using.
Index of transaction output used by this input.
Script that contains the signatures/pubkeys.
Sequence number. Currently unused, but intended for contracts in future.
Value of connected output, if known
Used in:
script of transaction output
If spent, the hash of the transaction doing the spend.
If spent, the index of the transaction input of the transaction doing the spend.
* Data required to reconstruct TransactionSigner.
Used in:
fully qualified class name of TransactionSigner implementation
arbitrary data required for signer to function
* A bitcoin wallet
the network used by this wallet
The SHA256 hash of the head of the best chain seen by this wallet.
The height in the chain of the last seen block.
The version number of the wallet - used to detect wallets that were produced in the future (i.e the wallet may contain some future format this protobuf/ code does not know about)
A UTF8 encoded text description of the wallet that is intended for end user provided text.
UNIX time in seconds since the epoch. If set, then any keys created before this date are assumed to be no longer wanted. Money sent to them will be re-spent automatically to the first key that was created after this time. It can be used to recover a compromised wallet, or just as part of preventative defence-in-depth measures.
transaction signers added to the wallet
Number of signatures required to spend. This field is needed only for married wallets to reconstruct KeyChainGroup and represents the N value from N-of-M CHECKMULTISIG script. For regular single wallets it will always be 1.
* The encryption type of the wallet. The encryption type is UNENCRYPTED for wallets where the wallet does not support encryption - wallets prior to encryption support are grandfathered in as this wallet type. When a wallet is ENCRYPTED_SCRYPT_AES the keys are either encrypted with the wallet password or are unencrypted.
Used in:
All keys in the wallet are unencrypted
All keys are encrypted with a passphrase based KDF of scrypt and AES encryption