spectred

command module
v0.3.14 Latest Latest
Warning

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

Go to latest
Published: May 2, 2024 License: ISC Imports: 3 Imported by: 0

README

Spectred

Build Status GitHub release GitHub license GitHub downloads

Spectred is the reference full node Spectre implementation written in Go (golang). It is a DAG as a proof-of-work cryptocurrency with instant confirmations and sub-second block times. It is based on the PHANTOM protocol, a generalization of Nakamoto consensus.

Overview

Spectre is a fork of Kaspa introducing CPU-only mining algorithm SpectreX.

SpectreX is based on AstroBWTv3 and proof-of-work calculation is done in the following steps:

  • Step 1: SHA-3
  • Step 2: AstroBWTv3
  • Step 3: HeavyHash

Spectre will add full non-disclosable privacy and anonymous transactions in future implemented with the GhostFACE protocol build by a team of anonymous crypto algorithm researchers and engineers. Simple and plain goal:

  • PHANTOM Protocol + GhostDAG + GhostFACE = Spectre

Spectre will become a ghostchain; nothing more, nothing less. Design decisions have been made already and more details about the GhostFACE protocol will be released at a later stage. Sneak peak: It will use Pedersen Commitments as it allows perfect integration with the Spectre UTXO model and allows perfect hiding. ElGamal will be used for TX signature signing as it has a superior TPS (transactions per second) performance. Any PRs are welcome and can be made with anonymous accounts. No pre-mine, no shit, pure privacy is a hit!

Comparison

Why another fork? Kaspa is great but we love privacy, Monero and DERO are great but we love speed! So lets join the cool things from both. We decided to take Kaspa as codebase, quick comparison:

Feature Spectre Kaspa Monero DERO
PoW Algorithm SpectreX kHeavyHash RandomX AstroBWTv3
Balance Encryption Future No Yes Yes
Transaction Encryption Future No Yes Yes
Message Encyrption Future No No Yes
Untraceable Transactions Future No Yes Yes
Untraceable Mining Yes No No Yes
Built-in multicore CPU-miner Yes No Yes Yes
High BPS Yes Yes No No
High TPS Yes Yes No No

Untraceable Mining is already achieved with AstroBWTv3 and a multicore miner is already being shipped with Spectre, working on ARM/x86. There is already a proof-of-concept Rust AstroBWT implementation currently under review and investigation to merge it into Spectre Rust codebase. We leave it up to the community to build an highly optimized CPU-miner.

Mathematics

We love numbers, you will find a lot of mathematical constants in the source code, in the genesis hash, genesis paylod, genesis merkle hash and more. Mathematical constants like Pi, E and several prime numbers used as starting values for nonce or difficulty. The first released version is 0.3.14, the famous Pi divided by 10.

Installation

Install from Binaries

Pre-compiled binaries for Linux x86_64, Windows x64 and macOS x64 as universal binary can be downloaded at: https://github.com/spectre-project/spectred/releases

Build from Source

Go 1.19 or later is required. Install Go according to the installation instructions at http://golang.org/doc/install. Ensure Go was installed properly and is a supported version:

go version

Run the following commands to obtain and install spectred including all dependencies:

git clone https://github.com/spectre-project/spectred
cd spectred
go install . ./cmd/...

Spectred (and utilities) should now be installed in $(go env GOPATH)/bin. If you did not already add the bin directory to your system path during Go installation, you are encouraged to do so now.

Getting Started

Spectred has several configuration options available to tweak how it runs, but all of the basic operations work with zero configuration.

spectred

Mining

The built-in spectreminer is a very simple unoptimized multi-core miner. Withouit specifying amount of cores it spawns one mining worker as the original Kaspa builtin miner. You can specify amount of workers based on number of cores with the command line option --workers.

Discord

Join our Discord server and discuss with us. Don't forget: We love privacy!

Issue Tracker

The integrated github issue tracker is used for this project.

License

Spectred is licensed under the copyfree ISC License.

Documentation

Overview

Copyright (c) 2024-2024 The Spectre developers Copyright (c) 2018-2019 The kaspanet developers Copyright (c) 2013-2018 The btcsuite developers Copyright (c) 2015-2016 The Decred developers Copyright (c) 2013-2014 Conformal Systems LLC. Use of this source code is governed by an ISC license that can be found in the LICENSE file.

Spectred is a full-node spectre implementation written in Go.

The default options are sane for most users. This means spectred will work 'out of the box' for most users. However, there are also a wide variety of flags that can be used to control it.

Usage:

spectred [OPTIONS]

For an up-to-date help message:

spectred --help

The long form of all option flags (except -C) can be specified in a configuration file that is automatically parsed when spectred starts up. By default, the configuration file is located at ~/.spectred/spectred.conf on POSIX-style operating systems and %LOCALAPPDATA%\spectred\spectred.conf on Windows. The -C (--configfile) flag can be used to override this location.

Directories

Path Synopsis
app
appmessage
Package appmessage implements the spectre appmessage protocol.
Package appmessage implements the spectre appmessage protocol.
rpc
cmd
spectrewallet/libspectrewallet/bip32/base58
Package base58 provides an API for working with modified base58 and Base58Check encodings.
Package base58 provides an API for working with modified base58 and Base58Check encodings.
consensus/utils/txscript
Package txscript implements the spectre transaction script language.
Package txscript implements the spectre transaction script language.
dagconfig
Package dagconfig defines DAG configuration parameters.
Package dagconfig defines DAG configuration parameters.
infrastructure
db/database
Package database provides a database for spectred.
Package database provides a database for spectred.
logger
Package logger defines an interface and default implementation for subsystem logging.
Package logger defines an interface and default implementation for subsystem logging.
network/addressmanager
Package addressmanager implements concurrency safe Spectre address manager.
Package addressmanager implements concurrency safe Spectre address manager.
stability-tests
daa
testing
Package util provides spectre-specific convenience functions and types.
Package util provides spectre-specific convenience functions and types.
bech32
Package bech32 provides a Go implementation of the bech32 format.
Package bech32 provides a Go implementation of the bech32 format.

Jump to

Keyboard shortcuts

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