Skip to content

How it works ​

futuros.xyz/como-funciona is the page we show technical and institutional partners to explain, stage by stage, what happens to a data point from the moment it exists at an agency (or at an institution that contributes it) until it appears as a cited figure. It is public, trilingual and needs no credential. This page documents what it shows and what it guarantees.

Two tracks, one corpus ​

The track is chosen with tabs and kept in the URL hash (#publicos or #aportados), so a shared link opens the right track directly.

The status of each stage ​

Each stage wears a badge that must match the code on main. The source of truth is src/routes/como-funciona.content.ts; if a stage changes status, it changes there and in this table in the same PR.

StageStatusWhat it means today
A1–A5In productionThe full public-data pipeline, described in The data pipeline and Provenance.
B1 ConsentIn productionvalidateContribution() requires consent: true; the license fixes the corpus posture. The pledge is recorded, not the dataset.
B2 Client-side encryptionNext phaseEnvelope encryption (AES-256-GCM + HPKE RFC 9180) specified in phase H. Not built.
B3 PseudonymizationIn productioncontributor_id = SHA-256 with the secret salt TRUST_ID_SALT; without it, production issues no receipts.
B4 ReceiptIn productionreceipt_hash SHA-256 over the canonical body; v2 adds an issuer HMAC-SHA256 when TRUST_RECEIPT_HMAC_KEY exists.
B5 Ledger and revocationIn productionThe code and the shared store are in production: KV Redis, with the same env names and the same precedence as the rate limiter (KV_REST_API_* first, then UPSTASH_REDIS_REST_*; #1287). GET /api/contribute returns configured: true. The public registry is live and currently empty (count 0, checked 2026-10-16). The page checks it live.
B6 TEE clean roomDesignConfidential VM (AMD SEV-SNP / Intel TDX, confidential GPU) with remote attestation, attestation-gated key release and aggregate-only, differentially private output.
B7 Compute at sourceDesignA node inside the contributor's infrastructure that runs only Ed25519-signed manifests; federated learning with secure aggregation.
B8 Public signature and anchoringDesignEd25519 over receipt_hash + an RFC 6962 Merkle log anchored with RFC 3161 / OpenTimestamps (phases C and D).

Design stages name candidate technologies in as much technical detail as possible, but none is built or contracted, and the page says so on each one. The page closes with a "What we do not claim today" block and the sovereignty posture regarding US hardware roots of trust.

Two reading layers ​

Each stage first shows a plain-language line and the "in → out" flow. The Show technical detail button (or the Technical mode switch, which opens them all) reveals the specification, the notes, a two-column threat model (what you can verify / what is not possible) and references to this documentation.

The labs ​

Nothing on the page is a mock:

  • Trace a figure (A3). Takes a real citation_id, parses it with parseMultiId(), resolves it with the source registry's inferSourceKey() / deepLinkFor() and looks up the published record in public/data/citations/<ISO3>.json.
  • Recompute a receipt (B3–B4). Recomputes contributor_id, salt_version, contribution_id, the canonical body, receipt_hash and the optional v2 signature with Web Crypto, in the browser, with no network calls. src/lib/trust-receipt-web.ts is a port of server/trust/ledger.ts, and src/lib/trust-receipt-web.test.ts requires byte-for-byte parity with makeReceipt() for v1 and v2 receipts: if the server changes the algorithm, the build fails before the demo can drift. It uses the public development salt and says so: its ids never match production ones.
  • Independent verifier. Accepts any receipt, including a real one from /contribuir: strips receipt_hash and the signature, canonicalizes the rest and recomputes SHA-256. A button tampers with a field to show the hash stops matching.
  • Attacker's view. Demonstrates the dictionary attack against a contributor_id computed with the public salt, which is exactly why production requires a secret TRUST_ID_SALT.
  • Ledger status (B5). Reads GET /api/contribute and shows whether the shared store is configured.

The headline figures (observations, citation records) are read live from /api/v1/index.json and link to that file.

  • The thesis and full receipt mechanics live in Data Trust.
  • The target cryptographic sequence (phases C, D, G, H) lives in Provenance: roadmap; /como-funciona presents it and does not redefine it. If the two diverge, the page is corrected, not the roadmap.

Every figure with its source — traceability is the contract.