Quantum Chainquantumcha.in ↗
Signing identity

Generate Quantum keys and keep the boundary explicit.

A Quantum account uses a post-quantum keypair. The public key determines its 20-byte address. The private key authorizes exact 32-byte transaction digests and should remain inside a controlled signer for its entire lifetime.

Account model

Public data identifies the account. Secret data authorizes it.

Private key
Secret native key material. It is never an RPC parameter and never appears in a signed transaction.
Public key
The exact 1,952-byte key carried by signed transactions.
Address
Keccak-256(publicKey)[12:32], the low 20 bytes of the hash.
Signature
The exact 3,293-byte result returned for a 32-byte signing digest.
Display format
Addresses use the familiar 0x plus 40 hexadecimal character form. Public keys and signatures should stay binary inside applications.
Address compatibilityThe display shape matches an Ethereum address, but a standard Ethereum private key does not control a Quantum address. Generate and sign through Quantum-compatible tooling.
JavaScript

Create a disposable wallet for Sandbox tests.

account.ts
import { QuantumWallet, bytesToHex } from "@quantum_chain/sdk";

const wallet = QuantumWallet.generate();
try {
  console.log("address", wallet.address);
  console.log("public key", bytesToHex(wallet.publicKey));
} finally {
  wallet.destroy();
}

QuantumWallet.generate() creates a local native signer. publicKey is a defensive copy. destroy() erases local signer state where the native implementation supports it.

Do not persist tutorialsGenerated quickstart wallets are for short-lived Sandbox use. Do not print or store exportPrivateKey() output in normal applications.
Python

Use the signer as a context manager.

account.py
from py_quantum import Signer

with Signer.generate() as signer:
    print("address", signer.address_hex)
    print("public key bytes", len(signer.public_key))

The Python API intentionally does not expose private-key bytes. The native handle owns them until close(), which the context manager calls automatically.

Production signer boundary

Let transaction callers depend on an interface, not key storage.

TypeScript
interface QuantumSigner {
  getPublicKey(): Promise<Uint8Array>;
  signDigest(digest: Uint8Array): Promise<Uint8Array>;
}

An external signer receives the exact 32-byte digest only after the caller has validated network identity and complete transaction intent. It returns the public key and canonical signature. The transaction layer verifies both before attachment.

Reference-client tools

Use node keystores only for their intended operational profile.

ToolPurposeRecommended use
keygeneratorCreate or recover a mnemonic-derived Quantum account and encrypted keystoreControlled development and recovery procedures only
ethkeyInspect, generate, change passwords, and perform offline operations on keystore filesOffline operator workstation
clefSeparate account-management and signing processOperator-controlled hot-signing environments after review
development generation
./build/bin/keygenerator --passphrase "REPLACE_WITH_A_STRONG_PASSPHRASE"
recovery
./build/bin/keygenerator \
  --passphrase "REPLACE_WITH_A_STRONG_PASSPHRASE" \
  --recover "REPLACE_WITH_THE_COMPLETE_12_WORD_MNEMONIC"

The current command writes both an encrypted keystore and a separate mnemonic file in its working directory. Move the mnemonic immediately into the approved offline recovery process and remove the plaintext working copy through your organization’s secure procedure.

Command-line exposureArguments may be visible in shell history and process listings. The commands above document the tool’s current interface, not a production secret-entry recommendation.

A Web3-style keystore protects the serialized private key with a password-based encryption envelope. Compatibility of the JSON container does not make generic Ethereum key tools Quantum-compatible. They may assume a different plaintext key type.

Security rules

Protect the key before, during, and after signing.