Documentation
StellarLock Documentation
Technical documentation for StellarLock Markets and StellarLock Code — what each product verifies, how it fails safely, and exactly what it does not guarantee.
Markets — overview
StellarLock Markets turns an intent (“buy Apple”) into a verified, inspected Solana transaction. The path is: intent → asset resolver → curated registry → Jupiter route → transaction builder → StellarLock risk engine → RPC simulation → fingerprint → wallet → Solana.
Intent
→ Asset Resolver
→ Registry (exact mint match)
→ Jupiter (quote + swap instructions)
→ Transaction Builder (v0, ALTs resolved)
→ StellarLock Risk Engine (identity/intent/programs/recipient)
→ RPC Simulation
→ Fingerprint (SHA-256 of exact message)
→ Wallet signature
→ Solana confirmationAsset resolution
You search an underlying company or index (Apple, NVIDIA, Tesla, Microsoft, Meta, Alphabet, Amazon, S&P 500). StellarLock maps that underlying to the tokenized representations it can prove, rather than to whatever token happens to carry a matching ticker.
Verified representations
A representation is accepted only when its mint address matches a curated, sourced issuer entry (currently xStocks on Solana). The registry records the issuer, token symbol, expected token program, source URL and the date the entry was human-verified.
Copycat detection
Ticker, name and logo are metadata and are treated as untrusted. Look-alike tokens sharing a ticker with a verified representation are surfaced with an identity mismatch and execution is blocked.
Secure Buy & transaction pre-flight
Before signing is offered, StellarLock runs deterministic checks on the exact message:
- Asset identity and official mint match
- Trade intent — input asset, output asset and amount match what you asked for
- Program analysis — every invoked program is inspected against an allowlist
- Signer and recipient validation
- Address lookup table resolution so no account stays hidden
- RPC simulation against current chain state
Transaction fingerprinting
StellarLock hashes the exact serialized message it audited. The same hash is recomputed for the message handed to your wallet and re-checked server-side after signature. If the two differ, execution is blocked and pre-flight must run again.
Token-2022 & scaled UI amounts
xStocks deployments use Token-2022 with the Scaled UI Amount extension. StellarLock accounts for the multiplier when displaying and validating amounts, so the number you approve is the number the chain settles.
Failure states
- No verified representation for the underlying → no trade offered
- Mint mismatch or unknown issuer → blocked with an identity error
- Route unavailable or quote stale → quote must be refreshed
- Simulation failure → blocked, with the RPC error surfaced verbatim
- Fingerprint mismatch → blocked, pre-flight re-runs
Security model
What StellarLock verifies: asset identity against a curated registry, exact mint equality, transaction contents after decoding, invoked programs, signers and recipients, declared intent versus decoded instructions, simulation outcome, and message integrity between audit and signature.
What it does not guarantee: issuer solvency or redemption, market and liquidity risk, correctness of third-party data, or the behaviour of your wallet after signing.
Assumptions: the curated issuer registry is accurate at its recorded verification date; the Solana RPC endpoint returns honest state; Jupiter returns routes that we then re-check locally; simulation reflects current — not future — chain state. StellarLock is non-custodial and never holds keys; signing always happens in your wallet.
Markets — coming soon
Not shipped yet: underlying reference-price integrity, Pyth integration, Ondo and Backpack providers, Constellations, Solana v1 portfolio batching, Security Passport anchoring, and a public developer API. These are tracked on the roadmap.
Quickstart
- Sign in with Google or email at /auth.
- Open the StellarLock Code.
- Paste code, drag in files, or upload a
.zip. - Pick an engine — Speed Scan for fast triage or Deep Reasoning for complex flows.
- Click Run audit. Findings stream in real-time with line refs and patch suggestions.
- Export as JSON or SARIF, or revisit later from History.
Scan engines
Stellar Lock ships two reasoning engines tuned for different jobs.
Speed Scan
single-passSingle-pass triage. Best for snippets, configs, single files, and CI gates where latency matters. Catches the obvious — injection, hardcoded secrets, weak crypto, misconfigured RBAC.
Deep Reasoning
multi-stepChains analysis across files, tracks data flow between functions, and reasons about business-logic abuse. Recommended for smart contracts, auth flows, and anything where exploit chains span multiple files.
Pre-flight checks
Before any payload leaves your browser, the Pre-flight panel runs two deterministic checks locally:
- Secret detection — regex + entropy scoring for AWS GitHub OpenAI Anthropic Stripe Slack Google JWT RSA / SSH keys and generic
.envvalues. - Dependency CVEs — parses
package.json,requirements.txt,Cargo.toml,go.mod,Gemfile.lock— then queries OSV.dev for known vulnerabilities.
Reading findings
Every finding has the same shape:
- Threat level — Critical · High · Medium · Low · Safe (color-coded).
- Title + category — e.g. SQL injection via unsanitized input, mapped to OWASP / CWE.
- Location — file path and line number, clickable to jump in the editor.
- Explanation — why it's a vulnerability, what an attacker would do with it.
- Patch — a concrete code suggestion, copyable in one click.
Use the Compare view (/compare) to diff two scans side-by-side and see which findings were resolved.
Exporting SARIF / JSON
Every scan exports as SARIF 2.1.0 — the industry standard. SARIF imports cleanly into:
- GitHub Code Scanning (upload via the Security tab)
- VS Code SARIF Viewer extension
- GitLab, Sonatype, DefectDojo, and most security dashboards
Raw JSON is also available for custom pipelines.
Supported inputs
Source files for mainstream stacks, plus configs and archives.
Privacy & retention
Your source code is not retained after a scan completes. We persist only the scan metadata (target name, mode, timestamp) and the structured report so you can revisit findings later.
Payloads are not used to train any model. Deleting a scan from History removes the report from our database.
Limits
- Per-file: 15 MB
- Per-scan payload: 500,000 characters total
- Rate limits: not enforced during public preview — be reasonable.
- History retention: scans stay in your workspace until you delete them.