ident
All repositories: gitoria
3.9 KB
# Mission 001 (old 003) — ident.worldapi.org MVP in Hybriel (ticket #2)One-shot worker. Architect (Claude Code on Byrodin) verifies your report.Read first: `/CONTAINERS/projects/antcolony/README.md`, `STATUS.md`, `loreana:/media/STORAGE/projects/tickets.worldapi.org/missions/001-tickets-mvp.md`and its result: the tickets app `loreana:/media/STORAGE/projects/tickets.worldapi.org`(README, STATUS, project.hl, store.hl, tests/) — same stack, same conventions, copy its setup.## Where- Host Loreana (`ssh loreana`, fish login shell → `bash -c '…'` or script files).- New app folder: `/media/STORAGE/projects/ident.worldapi.org`. Vendor `bin/hybriel` + pluginsexactly like the tickets app does (same binary, sha256 c51d163d…).- Hybriel repo `/media/STORAGE/projects/hybriel` READ ONLY. Reference for login:`projects/demo-social-network` (mail.hl, login_form.hl, signup_form.hl, store.hl, tests/).- Dev port **8351**, bind 0.0.0.0. Gate ports: pick your own range, not 8352 and not the socialgate's 8600-8619 (another worker runs the tickets gate at the same time).## What ident isLogin for all worldapi apps (tickets, gitoria, …). Email one-time codes only, no passwords.Accent orange `--color-accent: #ce9178` (tokens: `/CONTAINERS/projects/layouts.worldapi.org/css/foundation/tokens.css`on Byrodin, read only; markup rules in `docs/conventions.md` there).## Scope1. Users: email (unique, lowercased), display name, created. Sign up = first login with a new email(ask for a name once). Codes: 6 digits, expire after 10 min, single use, max 5 attempts, ratelimit sends per email.2. Pages: `/` (signed out: login form; signed in: "signed in as …", sign out), code entry,name prompt for new users.3. **Login for other apps — architect decision, redirect + code exchange (OAuth-code style,works across domains and dev ports):**- App sends browser to `ident/login?return=<url>&app=<name>`.- After successful OTP, ident redirects to `<return>?ident_code=<one-time code>` (code valid 60 s,single use). Only return URLs whose origin is on an allow list (config, for now: the tickets devorigins `http://100.77.141.84:8350`, `http://192.168.178.75:8350`, `http://127.0.0.1:8350`, pluswhatever your test client uses). Unknown origin → error page, no redirect.- App's server calls `POST ident/api/exchange {code}` → `{ user: { id, email, name } }` or 400.- ident keeps its own session cookie so a second app login does not need a new OTP.- Write this down as a short spec in the app README ("How apps use ident").4. Mail: do NOT send real mail in this mission. Use a file sink like the social app(`HL_SOCIAL_MAIL_SINK` pattern) configured via `.env`; tests read the code from the sink.Leave the hl:smtp path wired and configurable (SMTP_* env) for mail.byrod.in later.5. A minimal test client (a tiny second hybriel app or a route in the gate) that proves the wholeredirect → OTP → return → exchange flow end to end.Out of scope: wiring tickets to ident (next mission), deploy, Docker.## Rules- No git. Don't touch other project folders (read the tickets app only). Only kill your own PIDs.Clean up every headless Chrome (`--disable-gpu`, GPU is wedged). Scratch in `.scratch/`.- A test is the whole process: real headless browser drives login, observe the result;plus API negative cases (expired/reused code, wrong code 5x, bad return origin, reused exchange code).- Strict API from day one: unknown/missing fields → 400 naming the field.- Hybriel bugs: don't fix in the repo; report with repro.- Leave the dev server RUNNING on 8351 (setsid/nohup, `server.pid`, `server.log`).- Deliver `README.md`, `STATUS.md`, `tests/browser.mjs`.## Report (final answer, this structure)```## Done## Verified (each: command run + observed output)## Not verified / open## Hybriel issues (repro, observed, expected)## Questions for the creator## Running (URL, PID, log path)```
Branches
Latest commits
- 3c33d6eaident#34: the connection link in inbox has no class (rule on #conns a)mre
- dc97ec0dident#34: the Notif. chip and the Used in link share chipLook (Style.pChip) instead of the classes chip/used/notifmre
- 378bd432ident#34: the identity picture look is a static in styles.hl (Style.pAvatar); sizes stay with each listmre
- 1cf79e7eident#34: the wide page column is a static in styles.hl (Style.pWide), not the class "wide"mre
- ddc7d135Merge branch 'f7-hooks' into mainIdent
- eee0b513|||PR ident#34 part: test-hook classes replaced by name/element/attribute selectors (tests adjusted), the shared lead/message/notice looks are statics in styles.hlmre
- ccd6d0c4ident#34: browser gate: rowButton finds the row's button by namemre
- 24dd414eident#34: the shared lead, message and notice looks are statics in components/styles.hl, imported by the components (lib/looks.hl gone)mre
- 03ed26c7ident#34: access.hl: the remaining lead classes droppedmre
- 1d066c42ident#34: access.hl drops its unstyled lead class (the shared lead rule would otherwise mute it)mre
- 1e1dd7b4ident#34: the access page keeps its lead class string (the page has no ident-card, so its lead line was never muted; a shared rule would change the look)mre
- 89ac6553ident#34: the lead, message and notice lines are named with Style.pLead / pMessage / pNotice (shared bodies in lib/looks.hl) instead of class stringsmre
- e84be3deident#34: browser gate lists the Edit/Delete buttons by namemre
- fb7111faident#34: access page: unstyled test-hook classes (idrow, never, who, whoname, appname, neverrevoke) dropped; the tests use element/name selectorsmre
- 9f2ad803ident#34: notification switches: push/email by name=..., locked by aria-disabled, the switch look is the role=switch button (no switch/push/email/locked classes)mre
- e0f0ddaaident#34: inbox: the Mark read/unread button is styled as the button of its note-foot, the icon is found as the row's img (no toggle/icon classes)mre
- 16b49756ident#34: unused row classes (choice, usedrow, kind, shortid) droppedmre
- f9d6fb38ident#34: apps and identity rows: the Edit/New secret/Delete buttons carry name=..., the API key is found by its element; unused row classes (app, identity, shortid) droppedmre
- b323265aMerge branch 'f5-styles' into mainIdent
- 9ced53c3|||PR ident#33 ident#35 every component's styles live in its own Style block; styles.hl keeps the page-wide rest; the account bar is phone first (min-width: 60rem block); the avatar preview is hidden with the hidden attribute (ident#34 in part)mre