para is a command-line tool for miners and pools. It is experimental
software with no warranty. See LICENSE for more details.
This repository includes a modified fork of
ckpool, which currently
runs on parasite.wtf:42069. For instructions on how to connect, please visit
parasite.space.
In addition to adding a postgres database for share logging and some helpful
flags it modifies the coinbase payout logic found in stratifier.c. For more
information go
here.
// Generation value
g64 = COIN;
d64 = wb->coinbasevalue - COIN;
wb->coinb2bin[wb->coinb2len++] = 2 + wb->insert_witness;
u64 = (uint64_t*)&wb->coinb2bin[wb->coinb2len];
*u64 = htole64(g64);
wb->coinb2len += 8;
/* Coinb2 address goes here, takes up 23~25 bytes + 1 byte for length */
wb->coinb3len = 0;
wb->coinb3bin = ckzalloc(256 + wb->insert_witness * (8 + witnessdata_size + 2));
if (ckp->donvalid && ckp->donation > 0) {
u64 = (uint64_t*)wb->coinb3bin;
*u64 = htole64(d64);
wb->coinb3len += 8;
wb->coinb3bin[wb->coinb3len++] = sdata->dontxnlen;
memcpy(wb->coinb3bin + wb->coinb3len, sdata->dontxnbin, sdata->dontxnlen);
wb->coinb3len += sdata->dontxnlen;
}para is more than just glue code around ckpool though. It implements a Rust
library for the Stratum protocol and includes helpful command-line tools that
measure ping, inspect block templates and mimic mining machines. To see a full
list of available commands just follow the instructions below and do para help.
Rust is required to build, test, and develop. To install with curl:
curl --proto '=https' --tlsv1.2 -sSf https://sh.rustup.rs | sh
This repo includes a bundled development environment with Hermit that provides the above requirements.
. ./bin/activate-hermit
Clone the para repo:
git clone https://github.com/parasitepool/para.git
cd para
To build a specific version of para, first checkout that version:
git checkout <VERSION>
And finally to actually build para:
cargo build --release
Once built, the para binary can be found at ./target/release/para.
You can also install para directly into your path by doing:
cargo install --path .
para requires:
rustcversion 1.90.0 or later- Available from
rustup update
- Available from
gccversion 10.5.0 or later.- Available from your package manager or gnu.org
These versions can be verified with:
rustc --version
gcc --versionTo compile software on Linux systems, you may need additional packages which
are not always installed by default. For Debian based systems (Ubuntu, Kali,
etc), you can install these dependencies with apt:
sudo apt install build-essential pkg-config libssl-dev
To build Rust programs on Windows, you need one of two ABI configurations:
- MSVC
- On Windows,
rustupwill configure Rust to target this ABI by default - Visual Studio with
Build Tools
is required for building with MSVC
- this can be a very large install (~4GB)
- On Windows,
- GNU (GCC)
- Available from the
rustup toolchain install stable-gnucommand - Requires MinGW/MSYS2
# Run from within the MSYS terminal pacman -S --needed base-devel mingw-w64-ucrt-x86_64-toolchain \ mingw-w64-ucrt-x86_64-nasm
- Available from the
The Rustup Book provides more details on Windows builds.