NEXA
login
{ "title": "NEXA", "summary": "Nexa cryptocurrency consensus and protocol specifications" }

Nexa Blockchain Protocol and Consensus Specifications

Last updated: 2023 May 9

Overview

Nexa is a decentralized cryptocurrency with a public distributed ledger.
Transactions are validated and transmitted over a peer-to-peer (P2P) overlay (over TCP-IP) network, and stored in the blockchain.
Nexa utilizes the Proof-of-Work timestamping and consensus scheme with a hash function that is a combination of elliptic curve multiplication and SHA-256, targeting a 2-minute block time.
It utilizes the secp256k1 parameters with the Schnorr algorithm for digital signatures.
The ticker symbol for Nexa is NEXA (or NEX if you must have 3 letters).

The Nexa consensus protocol is a modification of Bitcoin Cash, which is a modification of Bitcoin. This documentation attempts to cover the full Nexa protocol, by leveraging previously written documentation for Bitcoin Cash. Therefore you may occasionally see references to Bitcoin Cash that are no longer applicable. Please notify us on our issue tracker if you discover a problem.

Style GuideContributorsTarget AudienceProject History

CWIK Markdown Cheat Sheet

Design

Merkle Tree
Block N
Hash0
Hash1
Hash2
Hash3
Hash01
Hash23
Root
Hash
Prev_Hash
Timestamp
Merkle Root
Block N+1
Block N-1
Tx0
Tx1
Tx2
Tx3

Nexa operates on the blockchain which is replicated among the nodes in the Nexa overlay network.
Transactions are submitted to network nodes, which will validate the transaction against the transaction history in the blockchain.
Once transactions are considered valid, they will be grouped into blocks through Merkle Trees.
Through rigorous hash computation, blocks can be mined into the blockchain by the network nodes and are subsequently broadcast to the network.

The blockchain serves as the public ledger for the nexa cryptocurrency and participant-defined tokens.
It consists of a tree of blocks, where each block references its parent by cryptographic hash. Of this tree, one single chain of blocks probabilistically contains overwhelmingly more cumulative hashing work than any other chain.
This chain is called the “main chain” and its history, from genesis block to tip, defines the current state of the ledger, achieving consensus about what transactions are included in the blockchain and ledger.

Due to the characteristics of hash functions, the content of any block cannot be altered without changes to all its subsequent blocks.
The time and computation intensity of such change increases as the blockchain is extended with new blocks.

Therefore, the transaction history in the blockchain at an arbitrary point in the past can be considered probabilistically immutable even with public access, with the probability of immutability increasing the deeper in the chain the transaction is found.

The transactions on Nexa are pseudonymous.
The blockchain does not keep records of coin ownerships for users.
Instead, each transaction refers to the unspent outputs of previous transactions.
The outputs of the transaction is then locked through locking scripts and whoever holds the correct unlocking scripts can use the outputs in their future transactions.

The Nexa network is an ad-hoc decentralized network of volunteers, in which transactions are transmitted and validated.
Messages on the network are usually broadcast on a best-effort basis.

Basics

Overview

Blockchain Basics

Chain work

Protocol Hashing Algorithms

Transaction Pool

The Blockchain

Addresses

Address Types

Cashaddr Encoding

Blocks

The Block

Block Header

Merkle Tree

Transaction Ordering

Cryptography

Bitcoin Keys (Public/Private)

Multisignature (M-of-N multisig)

Signatures (ECDSA/Schnorr)

Encoding

Base58

Cashaddr

Proof of Work (PoW)

Difficulty Adjustment Algorithm

Mining

Proof of Work

Script (Bitcoin transaction language)

Operation Codes (opcodes)

Script

Tokens

Native Tokenization

Token Description Document

NFT/SFT Specification

NFT/SFT Categories

Transactions

NEXA Transactions Overview

Template Script Output Format

Locking Script

Transaction Format

Transaction Signing

Unlocking Script

Transaction validation

Block-Level Validation Rules

Network-Level Validation Rules

Transaction Validation

Formats

Network Address

Variable Length Integer

Variable Length String

History

Block Version

Protocol Version

Transaction Version

Mining

Echelon Protocol

Mining Pools

Network protocol

Basic Network Parameters

Handshake

Network Messages

Nexa

Address

Bignum

Bignum Modulo Divisor

Blinded POW

CAPD

Challenge Transaction

Delegated Payment Protocol

Nexa POW

Nexa ID

OP_BIN2BIGNUM

OP_EXEC

OP_NUM2BIN

OP_PLACE

OP_PUSH_TX_STATE

Opcode Syntax

Outpoint

Script Templates

Sighash Type

Script Instructions

Transaction

Transaction Identifier

Transaction Overview

Protocol Changes

Addresses

CAPD Message Pool (Counterparty and Protocol Discovery)

DPP (Delegated Payment Protocol)

Nexa Identity

Challenge Transactions

Simple Payment Verification (SPV)

Bloom Filters

SPV

Miscellaneous

Endian