gonano

package module
v0.0.0-...-6c241ae Latest Latest
Warning

This package is not in the latest version of its module.

Go to latest
Published: Jan 3, 2022 License: MIT Imports: 0 Imported by: 0

README

gonano Build Status Documentation

gonano is a WIP implementation of the Nano cryptocurrency in Go.

This is a work in progress. Do not use this in production environments. All of the exported API's are subject to change and should thus not be considered stable. The same applies to the database format, configuration files and wallet files.

Protocol documentation can be found at: doc/protocol.md.

The address of my motivational back account is: xrb_1tt5p7agt63f3q37151o1yz3k1pfdan7wet9anejzrdqnuz5kgtcqiwwtfm6.

Goals

The goals of this project are to:

  • Provide an alternative to the existing C++ implementation
  • Learn about the protocol
  • Document the protocol
  • Make Nano more accessible to developers

Progress

  • Network Protocol
    • Documentation (see also: doc/protocol.md)
    • Data structures
      • Keep alive
      • Publish
      • Confirm Req
      • Confirm ACK
      • Bulk Pull
      • Bulk Push
      • Frontier Req
      • Bulk Pull Blocks
    • Synchronization
      • Pull
      • Push
    • Pinging
    • (Re)broadcasting blocks
    • Voting
  • Blocks
    • Data structures
      • Send
      • Receive
      • Open
      • Change
      • State
    • Proof of Work
  • Node
    • Persist state to a database
      • Blocks
      • Address balance
      • Pending transactions
      • Representatives (voting weight)
      • Votes
    • Block verification
    • Fork resolution
      • Block rollback
    • RPC interface
  • Wallet
    • Data structures
      • Balance
      • Address
      • Seed
    • Persist state to an encrypted file
    • RPC interface
  • Tests

Compiling

Go 1.8 or newer is required.

Run make all to build everything. Binaries can be found in the 'build' folder.

Run make test to run the tests.

Dependencies

This project directly depends on the following packages:

  • badger - Fast key-value DB in Go
  • cobra - A Commander for modern Go CLI interactions
  • blake2b and ed25519 - Go supplementary cryptography libraries
  • uint128 128-bit unsigned integer package from CockroachDB
  • decimal - Arbitrary-precision fixed-point decimal numbers in go

The above packages are vendored and can be found in the vendor directory. The ed25519 and uint128 packages are placed elsewhere as those had to be customized for gonano.

License

The source code of this project is licensed under the MIT license. The protocol documentation is licensed under CC BY-SA.

Documentation

Overview

Package gonano provides an implementation of the Nano cryptocurrency. It encapsulates all packages of the gonano project. See the 'nano' package for the actual Nano implementation.

Directories

Path Synopsis
cmd
Package nano provides a number of useful types for Nano like Address and Balance.
Package nano provides a number of useful types for Nano like Address and Balance.
block
Package block provides implementations for Nano's block types.
Package block provides implementations for Nano's block types.
crypto
Package crypto provides some helpful crypto functions (used internally).
Package crypto provides some helpful crypto functions (used internally).
crypto/ed25519
Package ed25519 implements the Ed25519 signature algorithm.
Package ed25519 implements the Ed25519 signature algorithm.
crypto/random
Package random provides some functions to securely generate random bytes and numbers.
Package random provides some functions to securely generate random bytes and numbers.
node
Package node provides a node implementation that can participate in the Nano network.
Package node provides a node implementation that can participate in the Nano network.
node/proto
Package proto provides an implementation of the Nano network protocol.
Package proto provides an implementation of the Nano network protocol.
store
Package store provides a storage implementation for the Nano block lattice.
Package store provides a storage implementation for the Nano block lattice.
store/genesis
Package genesis provides the genesis constants for the live Nano network.
Package genesis provides the genesis constants for the live Nano network.
wallet
Package wallet provides some helpful wallet functionality like seed generation and key derivation.
Package wallet provides some helpful wallet functionality like seed generation and key derivation.

Jump to

Keyboard shortcuts

? : This menu
/ : Search site
f or F : Jump to
y or Y : Canonical URL