feat(trust): full Duniter web-of-trust membership (params + referents)

Slice 4 of Block 2. The pure rule was already parameterised; this adds the
policy, cold-start and UI around it.

- commons_core: WotParams (sigQty/stepMax/sigValidity, Duniter defaults) +
  WebOfTrust.membersWith; npubToHex helper (NIP-19 decode) for adding roots.
- WotSettings (keystore): the active parameters, configurable — a young
  network loosens them and tightens as it grows, as Ğ1 did. Defaults Duniter.
- TrustReferents: the bootstrap 'seeds' membership is measured from — a
  bundled asset (empty until real founders are curated, no invented keys)
  unioned with referents the user adds by npub/QR. Honest cold-start.
- TrustCubit: computes the full membership verdict against referents+params
  alongside the personal circle, and exposes a TrustTier (networkMember >
  inYourCircle > vouched > unknown). Certifications issued with the active
  validity (they expire and renew, Duniter rule).
- UI: chat trust badge by tier; a 'Network of trust' screen (manage roots +
  advanced params) reached from the profile. i18n en/es/pt/ast.

Tests: WotParams/membersWith, npubToHex, TrustReferents, WotSettings, and
TrustCubit tiers/membership. Resolves the WoT-parameters decision
(open-decisions §B). Trust net stays empty/undetermined until seeded — by
design; users bootstrap their own roots.
This commit is contained in:
vjrj 2026-07-10 21:01:11 +02:00
parent a96049dd36
commit 4cf53f259f
29 changed files with 1111 additions and 39 deletions

View file

@ -443,6 +443,28 @@
"count": "Avalada por {n}",
"vouch": "Conozo a esta persona",
"vouched": "Avales a esta persona",
"circle": "Nel to círculu"
"circle": "Nel to círculu",
"member": "Miembru de confianza de la rede"
},
"wot": {
"title": "Rede de confianza",
"open": "Rede de confianza",
"help": "Cómo se decide quién ye miembru de confianza: la xente aválase ente sí, y la confianza estiéndese dende un conxuntu de raíces fundadores.",
"roots": "Raíces de confianza",
"rootsHelp": "Les identidaes fundadores qu'anclen la rede. Amiesta a quien te fíes (apega'l so códigu d'identidá); la pertenencia mídese p'afuera dende elles.",
"noRoots": "Entá nun hai raíces de confianza — nun se pue calcular la pertenencia hasta semar la rede.",
"addRoot": "Amestar una raíz de confianza",
"rootHint": "Apega un códigu d'identidá (npub…)",
"add": "Amestar",
"rootAdded": "Raíz de confianza amestada",
"rootInvalid": "Esi nun ye un códigu d'identidá válidu",
"remove": "Quitar",
"params": "Parámetros avanzaos",
"paramsHelp": "Regles Duniter. Aflóxales pa una rede nueva; apriétales según crez.",
"sigQty": "Avales pa ser miembru",
"stepMax": "Distancia máxima a una raíz",
"validityDays": "Validez del aval (díes)",
"reset": "Reafitar a valores Duniter",
"saved": "Guardáu"
}
}