Engineering Approach
Socialbridge is delivered through repeatable guardrails: modular packages, pre-flight simulations, portable design tooling, and a growing automated test lab.
Architecture guardrails
The wallet ships as a modular stack of packages (core, domain, network, crypto runtime) so presentation layers stay thin and replaceable. Strict capability injection and a dual-vault model keep secrets sealed—keys live inside the secret vault, while the app vault stores confidential metadata such as account lists and history.
- Clear separation of secret vault, app vault, blockchain drivers, and experience layer
- Definition-of-done checklists for every module before it reaches users
- Architecture Decision Records capture each guardrail for future audits
Cryptography stack
The vault encrypts every secret with libsodium primitives: Argon2id derives device-bound keys, and XChaCha20-Poly1305 keeps the ciphertext authenticated even if storage is copied. Per-record salts and nonces come from libsodium’s randombytes_buf (backed by the OS CSPRNG), so the same secret never encrypts to the same bytes twice.
- Argon2id hardening with tuned memory and time costs resists brute-force attempts on stolen backups
- XChaCha20-Poly1305 provides authenticated encryption with 192-bit nonces, preventing tampering and replay
- libsodium’s audited implementations run in constant time and ship with built-in secure wipe utilities
Pre-flight simulation & risk gates
Before a TON transaction is broadcast, the wallet replays it through a local sandbox virtual machine. Users see final balances, money paths, and excess refunds with full fidelity, without sending real funds during the preview step.
- Full-chain sandbox emulator reproduces the contract execution without broadcasting
- Money-path inspector shows every hop, return, and jetton mint
- Risk engine issues bounce verdicts and compensation hints in plain language
Theme & interface studio
A standalone theme editor manipulates runtime tokens, grids, and GPU shaders so partners can reskin the wallet or embed the editor inside their own apps. Layout constraints mirror design tools, enabling rapid brand-ready launches.
- Live editing of typography, icon sets, surfaces, and motion textures
- Portable editor package drops into any project with the same token schema
- Runtime CSS variable graph keeps design changes atomic and reversible
Quality discipline
The project currently runs 337 automated tests across vault logic, DeFi flows, and UI contracts. Every feature ships with a prompt log, checklist, and rollback plan so regressions are easy to detect and unwind.
- Unit, integration, and scenario suites cover swaps, staking, and risk gates
- Tech docs and modular rollout plans document each major refactor
- Release notes track what changed, why it changed, and how to revert safely