Serialization

Block Header

Field

Type

Length

Present

nVersion

signed int

4 bytes

Always

hashPrevBlock

uint256

32 bytes

Always

hashMerkleRoot

uint256

32 bytes

Always

nTime

unsigned int

4 bytes

Always

nBits

unsigned int

4 bytes

Always

nNonce

unsigned int

4 bytes

Always

Block

Field

Type

Length

Present

blockHeader

Block Header

70 bytes

Always

vTx

Transaction vector

Variable

Always

vchBlockSig

unsigned char vector

Variable

Always

Bulletproof Range Proof

Field

Type

Length

Present

V_size

Compact size

Variable

Always

V

G1Element vector

V_size

If V_size > 0

L_size

Compact size

Variable

Always

L

G1Element vector

L_size

If L_size > 0

R_size

Compact size

Variable

Always

R

G1Element vector

R_size

If R_size > 0

A

G1Element

48 bytes

Always

S

G1Element

48 bytes

Always

T1

G1Element

48 bytes

Always

T2

G1Element

48 bytes

Always

taux

Scalar

32 bytes

Always

mu

Scalar

32 bytes

Always

a

Scalar

32 bytes

Always

b

Scalar

32 bytes

Always

t

Scalar

32 bytes

Always

Transaction

Field

Type

Length

Present

nVersion

signed int

4 bytes

Always

nTime

unsigned int

4 bytes

Always

vin

Transaction Input vector

Variable

Always

flags

unsigned char

1 byte

If vin.size() == 0

vin

Transaction Input vector

Variable

If vin.size() == 0

vout

Transaction Output vector

Variable

If vin.size() == 0

vout

Transaction Output vector

Variable

If vin.size() > 0

wit

TxWitness vector

Variable

If flags&1

nLockTime

unsinged int

4 bytes

Always

strDZeel

string

Variable

If nVersion >= 2

vchBalanceSig

unsigned char vector

96 bytes

If nVersion & 0x30

vchTxSig

unsigned char vector

96 bytes

If nVersion & 0x10

Transaction Input

Field

Type

Length

Present

prevout

OutPoint

36 bytes

Always

scriptSig

unsigned char vector

Variable

Always

nSequence

unsigned int

4 bytes

Always

Transaction Output

Field

Type

Length

Present

nValue

unsigned int

8 bytes

Always

nValue

unsinged int

8 bytes

If nValue == ~(uint64_t)0

ephemeralKey

unsigned char vector

48 bytes

If nValue == ~(uint64_t)0

outputKey

unsigned char vector

48 bytes

If nValue == ~(uint64_t)0

spendingKey

unsigned char vector

48 bytes

If nValue == ~(uint64_t)0

bp

Bulletproof Range Proof

If nValue == ~(uint64_t)0

scriptPubKey

unsigned char vector

Variable

Always

Scalar

Field

Type

Length

Present

data

unsigned char vector

32

Always

G1Element

Field

Type

Length

Present

data

unsigned char vector

48

Always

OutPoint

Field

Type

Length

Present

hash

uint256

32

Always

n

unsigned int

4

Always

TxWitness

Field

Type

Length

Present

stack

vector of unsigned char vectors

Variable

Always