← Back to Challenger Blog
Guide #01 Zero-Trust Wallets 6 min read · Requires challenger-light

Connect Mainstream XRPL Wallets to Your Own Zero-Trust Local Node

Almost every XRPL wallet today defaults to a shared public RPC cluster. With challenger-light --wallet-ws, you can back Xaman, Crossmark, GemWallet, Joey, and xrpl.js with your own zero-database node that verifies 80% UNL validator quorum and 16-way SHAMap Merkle proofs locally on your machine.

Why Point Your Wallet at a Local Light Node?

When a wallet queries a public WebSocket server like wss://xrplcluster.com or wss://s1.ripple.com, it blindly trusts whatever JSON that server sends back for your XRP balance, account sequence, network fees, trustlines, and transaction finality. Running a full rippled node solves that, but requires terabytes of NVMe storage and high RAM.

challenger-light takes a different approach: zero database, direct P2P peering, local cryptographic verification. Now, with the new --wallet-ws flag, it speaks the exact rippled WebSocket JSON-RPC protocol mainstream wallets expect.

← Swipe diagram to inspect →
YOUR DEVICE / PRIVATE TAILNET (TRUSTED BOUNDARY) UNTRUSTED PUBLIC NETWORK MAINSTREAM WALLET Keys stay inside wallet • Xaman / Joey • Crossmark • GemWallet • MetaMask Snap • xrpl.js dApps SIGNS TXS LOCALLY WS JSON-RPC 127.0.0.1:6006 or wss://*.ts.net CHALLENGER-LIGHT --wallet-ws (0-DB Verifier) 1. Verify signed UNL (MNF\0) 2. Count 80% quorum (VAL\0) 3. Verify 16-way SHAMap proof 4. Push ledgerClosed stream 5. Relay signed tx_blob to P2P VERIFIED_LOCALLY: TRUE XRPL/2.3 TLS P2P XRPL P2P HUBS (UNTRUSTED) Serve raw VAL\0, headers, & TMGetLedger Merkle proofs. Cannot forge state or balances. XRPL UNL VALIDATORS Sign ledger hashes (VAL\0). 80% threshold required before any query is answered.
Figure 1. End-to-end zero-trust data flow between a mainstream wallet, challenger-light --wallet-ws, and untrusted XRPL P2P hubs. Zero keys leave your wallet

1Install & Start challenger-light --wallet-ws

Install the standalone Rust binary (or upgrade an existing installation with challenger-light --upgrade) and launch it with --wallet-ws:

Shell · Install & Start
# Install from GitHub (or run `challenger-light --upgrade` if already installed)
cargo install --git https://github.com/LJ-XRPL/challenger xrpl-light-client

# Start the zero-DB light node with the rippled-compatible WebSocket wallet server
challenger-light --wallet-ws

By default, --wallet-ws binds to ws://127.0.0.1:6006 while keeping the standard HTTP JSON-RPC server on http://127.0.0.1:5005. Within ~5–10 seconds, it fetches and verifies the signed UNL, connects to XRPL Mainnet P2P hubs over TLS, and reaches 80% validator quorum.

2Choose Your Connection Topology (Desktop vs. Mobile)

Desktop wallets can talk directly to ws://127.0.0.1:6006. Mobile wallets like Xaman and Joey enforce TLS (wss://) and run on a separate device, so they connect privately through Tailscale Serve — giving you an automatic, valid Let's Encrypt wss:// URL reachable only from your own devices.

← Swipe diagram to inspect →
PATH A · DESKTOP WALLETS & LOCAL APPS (ZERO TLS CONFIG) CROSSMARK / GEMWALLET / XRPL.JS Custom Node URL: ws://127.0.0.1:6006 Loopback WS Host + Ext Origin CHALLENGER-LIGHT --WALLET-WS Allows loopback Host & chrome-extension:// / moz-extension:// Blocks random websites (https://evil.com) & DNS rebinding by default PATH B · MOBILE WALLETS — XAMAN / JOEY / BIFROST (PRIVATE TLS VIA TAILSCALE) PHONE (XAMAN / JOEY) Settings → Advanced → Node wss://your-node.ts.net WireGuard + Valid TLS TAILSCALE SERVE tailscale serve --bg 6006 Private to your tailnet only 127.0.0.1 CHALLENGER-LIGHT --wallet-ws --wallet-ws-allow-any-origin
Figure 2. Desktop wallets connect over loopback ws://127.0.0.1:6006; mobile wallets connect over a private Tailscale wss:// endpoint. Never exposed to the public internet

Desktop (Crossmark / GemWallet / xrpl.js)

  1. Start challenger-light --wallet-ws on your laptop.
  2. Open your wallet's Network / Node settings.
  3. Add custom node: ws://127.0.0.1:6006.
  4. In xrpl.js: new xrpl.Client("ws://127.0.0.1:6006").

Mobile (Xaman / Joey via Tailscale)

  1. Run challenger-light --wallet-ws --wallet-ws-allow-any-origin.
  2. Run tailscale serve --bg 6006 on the same host.
  3. Copy the printed https://<node>.ts.net URL and change https:// to wss://.
  4. In Xaman: Settings → Advanced → Node → Add custom node.
Shell · Mobile via Tailscale Serve
# Private mobile-wallet setup (only reachable from your own Tailscale devices)
challenger-light --wallet-ws --wallet-ws-allow-any-origin --no-tui &
tailscale serve --bg 6006

3How Trustlines & Objects Verify With Zero Database

Balances (account_info) only need a single SHAMap leaf proof. Wallets also need your trustlines (account_lines) and owned offers/escrows/NFTs (account_objects). Here is how challenger-light proves every single one of them against the quorum-validated account_hash without storing any ledger database:

← Swipe diagram to inspect →
STEP 1 · ANCHOR QUORUM HEADER 80% UNL validated ledger_seq + account_hash (root) Every proof hashes here STEP 2 · DIRECTORY OWNER DIRECTORY Keylet = SHA512Half( 0x004F || AccountID ) Walks IndexNext pages Each page SHAMap-proven STEP 3 · PARALLEL PROOFS VERIFY EACH OBJECT 8-wide concurrent SHAMap leaf proofs: • RippleState • Offer / Escrow / NFT Bounded: 16 pages / 200 objs STEP 4 · WALLET RIPPLED JSON Low/High sign normalization + challenger_proof verified: true
Figure 3. How account_objects and account_lines cryptographically verify every trustline and object against the quorum state root. Zero unverified RPC passthrough

Supported Wallet WebSocket Commands

Command Verification Method Used By Wallets For
ping Local Connection keepalives & Custom Node health checks
server_info / server_state 80% UNL Quorum + FeeSettings Sync state, reserves (1 XRP / 0.2 XRP), validated ledger range
fee SHAMap FeeSettings Proof Autofilling Fee drops before signing
subscribe / unsubscribe Quorum ledgerClosed Stream Live ledger close pushes & tx confirmation watchers
ledger / ledger_closed / ledger_current 80% UNL Quorum Header Autofilling LastLedgerSequence
account_info SHAMap AccountRoot Proof XRP balance, Sequence, OwnerCount, reserve calc
account_lines SHAMap OwnerDir + RippleState IOU / stablecoin trustlines, balances, limits, freeze flags
account_objects SHAMap OwnerDir + Objects DEX offers, escrows, checks, NFTs, signer lists
ledger_entry SHAMap Arbitrary Keylet Direct state lookups (e.g. AMM, FeeSettings, SignerList)
submit & tx P2P Broadcast + Tx SHAMap Proof Broadcasting wallet-signed tx_blob & proving inclusion

4Test Your Live Local Node in 10 Seconds

Once challenger-light --wallet-ws is running, you can verify the WebSocket stream and SHAMap proofs directly with Node.js (or xrpl.js):

Node.js · Live WebSocket Proof Check
node -e '
const ws = new WebSocket("ws://127.0.0.1:6006");
ws.onopen = () => {
  ws.send(JSON.stringify({ id: 1, command: "fee" }));
  ws.send(JSON.stringify({ id: 2, command: "account_info", account: "rHb9CJAWyB4rj91VRWn96DkukG4bwdtyTh" }));
  ws.send(JSON.stringify({ id: 3, command: "account_lines", account: "rHb9CJAWyB4rj91VRWn96DkukG4bwdtyTh", limit: 3 }));
};
ws.onmessage = (e) => {
  const m = JSON.parse(e.data);
  console.log(m.id, m.status, "verified_locally:", m.result?.challenger_proof?.verified_locally);
  if (m.id === 3) ws.close();
};
'

You should see verified_locally: true on every single response — proving the fee settings, XRP balance, and trustlines were cryptographically checked against the live 80% UNL quorum state root on your own CPU.

Security Boundaries

The --wallet-ws listener never holds or touches private keys and exposes zero admin commands — only read-only SHAMap-verified queries and signed-blob submit broadcasts. By default it binds to 127.0.0.1:6006, rejects non-loopback Host headers (preventing DNS rebinding), restricts browser Origin headers to loopback and wallet-extension schemes (chrome-extension://, moz-extension://, safari-web-extension://), and enforces a 64-connection / 1 MiB frame cap.

What About Transaction History (account_tx)?

Because a 0-DB light client does not store historical ledger indices, account_tx (full past transaction history) is intentionally not mocked or silently proxied without proofs. Balance, reserves, fees, trustlines, owned objects, live ledger close streams, and submitting/proving new transactions all work end-to-end with zero trust.