Technical Docsv0.9 Testnet

Krypco Documentation

Technical reference for the krypco.eu hybrid blockchain. Learn how to run a node, deploy contracts, and interact with the network.

Getting Started

Krypco is a hybrid blockchain built in Rust, forked from Midnight Network. It combines a permissioned private chain with a permissionless public chain, connected via zero-knowledge proofs. Follow these steps to get up and running.

Chain ID
20269
RPC Port
8545
WebSocket
8546
P2P Port
3000

1. Install Prerequisites

The krypco node requires Rust (stable channel), a C/C++ toolchain, and RocksDB libraries. On Ubuntu 22.04 or 24.04 LTS:

Install build dependencies (Ubuntu)
# Install Rust
curl --proto '=https' --tlsv1.2 -sSf https://sh.rustup.rs | sh
source $HOME/.cargo/env

# System packages
sudo apt update && sudo apt install -y \
  build-essential cmake clang llvm libclang-dev \
  protobuf-compiler libprotobuf-dev \
  librocksdb-dev libsnappy-dev liblz4-dev \
  libzstd-dev libbz2-dev libgflags-dev

2. Build the Node

Clone and build
git clone https://github.com/krypcoeu/krypco-node.git
cd krypco-node
cargo build --release --bin krypco-node

# The binary will be at target/release/krypco-node

3. Generate Validator Keys

Every node needs an identity key pair. The private key is used for signing; keep it secure and never commit it to version control.

Key generation
# Generate a new key pair
./krypco-node key generate --output-file ~/krypco/config/identity.key

# Inspect the public key (safe to share)
./krypco-node key inspect ~/krypco/config/identity.key \
  --output-format json > ~/krypco/config/identity.pub.json

4. Configure the Node

Edit config/node.toml to set your network mode, ports, and storage directory. The node supports three modes: public (permissionless), private (permissioned with KYC), and hybrid (default, bridges both chains via ZK proofs).

config/node.toml (excerpt)
[network]
mode = "hybrid"
p2p_port = 3000
rpc_port = 8545
ws_port = 8546
bootstrap_nodes = [
  "/dns4/boot1.krypco.eu/tcp/3000",
  "/dns4/boot2.krypco.eu/tcp/3000"
]

[consensus]
type = "pop"
epoch_duration_seconds = 86400

[storage]
data_dir = "/var/lib/krypco/data"
db_type = "rocksdb"
max_open_files = 10000

[rpc]
enable = true
allowed_origins = ["*"]

5. Run the Node

Systemd (recommended)
sudo systemctl start krypco-node
sudo systemctl enable krypco-node
sudo systemctl status krypco-node
Docker alternative
docker run -d --name krypco-node --restart always \
  -p 3000:3000 -p 8545:8545 -p 8546:8546 \
  -v ~/krypco/data:/data \
  -v ~/krypco/config:/config \
  krypcoeu/node:latest \
  --config /config/node.toml --validator

6. Connect a Wallet

Add the Krypco network to MetaMask or any EVM-compatible wallet using these parameters. The RPC endpoint is available through our public gateway.

Network NameKrypco Testnet
Chain ID20269
Currency SymbolBFr
RPC URLhttps://rpc.krypco.eu
Block Explorerhttps://krypco.eu/explorer

Firewall Configuration

Open the following ports for your node to communicate with the network. Only expose the RPC port if you intend to serve external queries (use a reverse proxy with rate limiting in production).

PortProtocolPurposeRequired
3000TCPP2P networking (libp2p)Yes
8545TCPJSON-RPC endpointOptional
8546TCPWebSocket subscriptionsOptional
9100TCPPrometheus metricsOptional