Commit Graph
101 Commits
Author SHA1 Message Date
bchanot 868aa3d001 docs(docs): R4.10 owner results as declared (J1.7 FAIL Firefox + Brave, J2.3 FAIL), RUST.md §10.12 diagnosis of both anomalies, mini-recette, TODO R4.10 2026-10-21 00:26:06 +02:00
bchanot 45093135e9 docs(docs): RUST.md §10.11 R4.9 gates (verifier ×3 CONFORME, security re-gates PASS, check:all); TODO R4.9 ticked, owner actions; memory BDR-065, EVAL-025, LRN-065, journal 2026-10-20 22:12:24 +02:00
bchanot 49b812b9b4 docs(docs): R4.9 verifier and security follow-ups: §6 rows 19 (J2 device run, blocking before merge) and 20 (WebKit worker error trace); port 4173 in the exposure table as an owner-opened recette rule; serve.mjs post-bind check typed from the address; report-compare comment names the residual race 2026-10-20 22:05:04 +02:00
bchanot 80cc261c24 fix(tests): R4.9 security gate findings: serve.mjs refuses an empty or unspecified --host (an unset FAUNOSTEO_DEV_HOST bound every interface); report-compare reads at most the 50 MiB cap + 1 byte after its size check; recettes source dev-env.sh first 2026-10-20 21:16:48 +02:00
bchanot 24e05cecd5 docs(docs): PDF_IMPORT_HARDENING §6 row 7 classified from the R4.9 bench (bounded browser raster path, device check J2.6/J2.7) 2026-10-20 21:14:45 +02:00
bchanot eeae015bc4 docs(docs): RUST.md §10.11 R4.9 record: memory bench by dimension (linear flat after init, objects and URLs released, Chromium per-export growth = the browser's raster path, bounded at a plateau, control without the core identical), full checks, report:compare dry run; Chromium 16-step series and raster control results 2026-10-20 21:14:36 +02:00
bchanot 6166eba5f1 docs(docs): PDF_IMPORT_HARDENING §6 classifies every open import risk of §5 and BDR-058/059/063 (fixed with proof, accepted temporarily, blocking before merge, before public exposure) 2026-10-20 21:03:55 +02:00
bchanot 9e6125b656 docs(docs): R4.9 J1 and J2 recettes re-issued on the R4.8 build: OD-6 device list, J1.13 data kept on a refused import, J2.12 views and markers, J2.13 attachment and properties, J2.14 report:compare; results cells untouched 2026-10-20 21:03:55 +02:00
bchanot f36dbdd4ae docs(docs): RUST.md §10.10 R4.8 record (deleted, replaced, kept with reasons, census, non-regression table, risks, R5 prerequisites); CLAUDE.md, README, WORKSPACE, packages/README, TEST_STRATEGY, PDF-FORMAT, DEPLOY rollback R4 note and module size, hardening §5 pdf-lib closed, fixtures README, CHANGELOG R4 entry; TODO R4.8 closed; memory BDR-064, journal 2026-10-19 12:17:02 +02:00
bchanot 77e11a53e4 docs(docs): RUST.md §10.9 R4.7 record (tool on the core, O10 parity 158/72, A.3 lines as printed, timing), CLAUDE.md map and command, PDF-FORMAT; TODO R4.7 closed; memory BDR-063, journal 2026-10-19 11:13:42 +02:00
bchanot 264c5fa3fc docs(docs): RUST.md §10.8 R4.6 record (buffers, memory, parity, E3/E4 three engines, release series, W1, risks); ledger targets filled; compare-exports script; roundtrip raster-failure case; TODO R4.6 closed; memory BDR-062, LRN-063/064, journal 2026-10-19 02:49:42 +02:00
bchanot cdcdda8e1c docs(docs): R4.6 J2 recette (procedure, results grid, kit script), export harness phases and dist override, export series script, ledger targets of the app PDF suites, CLAUDE.md export flow; export driver publishes its User Timing split 2026-10-19 01:41:57 +02:00
bchanot a0d0a384c7 docs(docs): RUST.md §10.7 poppler pixel total corrected (150,193,611 over the 14 runs) 2026-10-19 00:27:27 +02:00
bchanot b44dd80af2 fix(domain): R4.5 gate hardenings: self-check without the import size cap, Ref(0) safe, pdf-write implies pdf-read; §10.7 records the gate 2026-10-18 23:39:31 +02:00
bchanot d2376a4574 docs(docs): RUST.md §10.7 R4.5 serialiser record; TODO R4.5a-e ticked 2026-10-18 23:29:43 +02:00
bchanot 4874913669 docs(docs): RUST.md §10.6 R4.4 layout record; TODO R4.4 closed; journal 2026-10-18 21:52:44 +02:00
bchanot 73706c074e docs(docs): J1: iPhone deferred by the owner, stays not tested; computer run reported without failure 2026-10-18 21:22:06 +02:00
bchanot 769544a1e8 docs(docs): J1 device run recorded as reported (no failure; devices and measures pending confirmation) 2026-10-18 21:18:34 +02:00
bchanot ee71a375a2 docs(docs): J1 kit carries the L report as a rescue copy; results template 2026-10-18 20:23:26 +02:00
bchanot b08373a89b docs(docs): RUST.md §10.5 completed (application build results, residual risks); R4 J1 procedure and kit
docs/development/R4_J1.md: the two LAN surfaces (dev server, production build behind the
DEPLOY CSP through serve.mjs --host on the DEV origin), the kit folder generated by
scripts/r4-j1-kit.mjs (reference PDFs, the O8 hostile corpus with expected messages,
rescue copies), twelve checks per device, what to report.
2026-10-18 19:52:25 +02:00
bchanot e0127b0726 docs(docs): RUST.md §10.5 draft of the R4.3 worker (amendment to B.1.5, messages, memory, leak series) 2026-10-18 19:00:24 +02:00
bchanot 6deee65b79 docs(docs): RUST.md §10.4 browser results of the Rust import; TODO R4.2 closed, journal 2026-10-18 16:59:37 +02:00
bchanot 83a66a23dc docs(docs): RUST.md §10.3 records the R4.2 security gate findings and the fix 2026-10-18 16:29:07 +02:00
bchanot 0d2c687b79 docs(docs): RUST.md §10.3 R4.2 reader record (parity, OD-4 explanation, OD-3 thresholds, Node budgets) 2026-10-18 16:16:31 +02:00
bchanot aada7997de docs(docs): R4.1 freeze record (RUST.md §10 draft, fixtures README R4 section)
Oracle table with commits, ledger totals, repository weight, freeze findings,
TypeScript baselines in Chromium, Firefox and WebKit with the watchdog
caveat; TODO R4.1a-f ticked; journal line.
2026-10-18 15:13:19 +02:00
bchanot 104887ff8a docs(docs): PDF export download goes through downloadBlob (RUST.md 8.7) 2026-10-18 04:55:11 +02:00
bchanot db8c0efc1c docs(docs): R3 validated and merged; README rescue copy restore 2026-10-17 13:13:10 +02:00
bchanot 9bd9acaf58 fix(app): rescue copy importable, trapping draft held, replace confirmed
The JSON rescue copy could not be restored in the app, a draft that traps
the engine left the tab on a reload screen and spent a recovery on every
read, and an unsaved or in-progress report could be lost by a reload
outside the editor or by New report / Import without warning.

Home import reads the copy (content-sniffed, 16 MiB cap, strict UTF-8)
through the core's draft.restore before any session change; a trapping
(draft, archive) pair is held in the resolution panel and only re-read
on Retry; ReplaceSessionDialog guards New report and Import; the
beforeunload guard is app-wide while unsaved. Supersedes BDR-055's
"never held" for `internal` only.
2026-10-17 12:58:57 +02:00
bchanot 6371523f8c fix(editor): honest stopped state when the draft is unsaved; no dead retry
0279953 chose the stopped message from CoreRuntime.stopped alone: it
promised the report was kept even when the tab's storage refused the
draft (export, the banner's advice, needs the core), four surfaces still
offered a retry that could not work, and a failed recovery below the cap
was a dead end since nothing called retry().

The runtime restarts a failed recovery on the next call (compiled module
reused, cap still counts traps) and notifies status listeners. One
CoreStoppedNotice on the editor, Home, New report and the full-page
notice: reload when saved, else core.stopped_unsaved with a core-free
copy download (also on the storage-full banner) and a beforeunload
guard. Export, import and new report say the stopped message; a core
failure reading an unread draft is FAILED, not held. ESLint census of
the failure keys; core.stopped says "plusieurs erreurs".
2026-10-16 18:26:10 +02:00
bchanot 0279953e9e feat(editor): a clear final state once the engine spent its three recoveries (canvas and action alerts) 2026-10-15 17:58:11 +02:00
bchanot 75708250a8 docs(docs): R3 owner decisions (trigger names per language, two canvas failure messages) 2026-10-15 01:03:17 +02:00
bchanot e1b56083c6 docs(docs): R3 figures at the final commit; TODO and journal after the gates 2026-10-15 00:45:21 +02:00
bchanot 23895b9351 fix(anatomy): url() locality skips CSS whitespace only (security audit R3 pass 2) 2026-10-15 00:40:30 +02:00
bchanot 157c854ed1 fix(anatomy): prescan closers searched after their opener; ASCII-only href trim; root painting attributes removed (security audit R3) 2026-10-15 00:25:43 +02:00
bchanot d6b5edb626 docs(docs): R3 in RUST.md §9, CLAUDE.md, CHANGELOG, PDF import gate note, packages README 2026-10-15 00:07:20 +02:00
bchanot c97b0e7c67 fix(store): banner on a refused archive write, rescue download kept alive 2026-10-14 23:18:33 +02:00
bchanot a37c50b9ee fix(store): drop the replaced archive when the new one cannot be written 2026-10-14 23:15:54 +02:00
bchanot e34b7f282e fix(store): hold session texts whose set-aside fails, never overwrite them 2026-10-14 23:11:59 +02:00
bchanot 8d7a56fbf8 docs(docs): RUST.md 8.6/8.7 module size after L1 and the JSON.stringify boundary invariant 2026-10-14 21:56:53 +02:00
bchanot f8a8b25614 docs(docs): L1 resolved, lone surrogates refused and set aside (RUST.md 8.7, PDF-FORMAT, CHANGELOG) 2026-10-14 21:49:40 +02:00
bchanot 36316cf67f fix(domain): sheet.check reads its document without an intermediate copy; RUST.md states the copy behaviour exactly
Second security pass on e49009e: PASS with two LOW items, both applied.
Module 1,044,559 B raw / 340,154 B gzip; core 135, core-wasm 25, app 313.
2026-10-14 01:07:17 +02:00
bchanot e49009e363 fix(domain): security audit follow-ups — deserialise JSON by reference, literal delete paths in the wasm build
The security gate (PASS, 0 blocking) reported LOW items: an imported
attachment's Value was copied for the wrapper and the snapshot gate (a
hostile 16 MiB attachment multiplied linear memory), and wasm-build.sh
deleted its outputs through a variable. Every JSON input is now read with
T::deserialize(&Value) (same errors, no copy); one deserialiser instead of
two also shrinks the shipped module from 1,180,281 to 1,046,498 bytes raw
(372,132 → 340,929 gzip). The two outputs are removed on their literal
paths. RUST.md records the numbers, the quarantine retention and the
base-image tag residual.
2026-10-14 01:02:30 +02:00
bchanot 8e8c58efca docs(docs): R2 — RUST.md §8 (migrated components, operations, runtime, census, proofs, measurements, behaviour differences, risks), CLAUDE.md, DEPLOY.md (CSP before an R2 image, never built on the VPS), WORKSPACE, TEST_STRATEGY, packages README, CHANGELOG 2026-10-14 00:51:44 +02:00
bchanot e633169a00 fix(workspace): LAN exposure via host firewall — the Supabase CLI forces 0.0.0.0, so PostgreSQL / Studio / raw Mailpit close by UFW rules on the LAN interface; gateway reduced to Mailpit behind basic auth on 54325
Owner run: the CLI prints 'All services bind to 0.0.0.0' and ignored the
rootless daemon's default address; the gateway could not share 54321/54324
with 0.0.0.0 listeners. Now: Kong serves the API directly; the DEV gateway
serves only Mailpit with basic auth on <DEV host>:54325; ENVIRONMENTS.md §3
gives the exact UFW rules (interface-scoped deny on 54322-54324, two cases
by current UFW state), rollback and impact; dev:net-check proves the
allowed surfaces from a distinct Docker network (5/5 OK) and prints the
refusal checks to run from another device, since a rootless container's
traffic to the host is delivered locally and cannot see the LAN firewall.
LRN-053 corrects LRN-052.
2026-10-13 23:01:19 +02:00
bchanot 3e48b0d848 chore(workspace): DEV least-privilege exposure — nginx DEV gateway (API on the LAN, Mailpit behind basic auth), network check from a distinct origin, loopback default for the rootless daemon documented
The Supabase CLI publishes 54321-54324 on every interface with no bind
option. Design: the rootless daemon binds published ports on loopback by
default (~/.config/docker/daemon.json {"ip":"127.0.0.1"}, owner action,
not applied), and the DEV gateway (Compose service dev-gateway, profile
dev, container faunosteo_dev_gateway) re-publishes only the API (Kong) and
Mailpit behind HTTP basic auth on FAUNOSTEO_DEV_HOST; Studio and PostgreSQL
stay loopback (SSH tunnel for Studio). pnpm dev:gateway generates the Mailpit
credentials (gitignored; htpasswd 644 because the rootless container user
cannot read a 600 file, hash only). pnpm dev:net-check probes from a
throwaway container on its own Docker network: app, API health, REST 401,
Mailpit 401/200, PostgreSQL and Studio closed. Gateway proven on alternate
ports (health 200, password login 200, Mailpit 401 / 200).
2026-10-13 22:38:40 +02:00
bchanot dd4c35c061 chore(workspace): DEV origin on the private network — scripts/dev-env.sh (FAUNOSTEO_DEV_HOST detected or set), Supabase CLI wrapper, pnpm dev on the LAN address, config.toml URLs via env(); ENVIRONMENTS.md (identity Faunosteo / faunosteo.com, DEV / STAGING / PROD, exposure table, owner procedure)
The owner tests from other devices of the private network: every test
surface is addressed by the machine's LAN address, never 127.0.0.1 or
localhost, never hard-coded. scripts/dev-env.sh decides the host once
(hostname -I, FAUNOSTEO_DEV_HOST override, production hosts refused);
scripts/supabase.sh exports it for every CLI call (pnpm db:*, pnpm supabase)
because config.toml now reads api.external_url (mail links), auth.site_url
and studio.api_url with env(); scripts/dev.sh = pnpm dev on that origin,
pnpm dev:offline keeps the local tool alone; dev-lan.sh removed.
Verified: GoTrue API_EXTERNAL_URL and Studio SUPABASE_PUBLIC_URL on the LAN
address, a signup mail linking to http://<lan>:54321/auth/v1/verify, the
four published ports answering from a separate Docker network, and the
10-step procedure in headless Chromium at the LAN origin with every request
URL audited (no 127.0.0.1 / localhost).
2026-10-13 22:06:25 +02:00
bchanot 40ae453f84 chore(supabase): ceiling comments aligned, prefix patterns built once, cross-account residuals named in STORAGE.md 2026-10-13 20:20:19 +02:00
bchanot 6a9657ce1e fix(supabase): per-account byte budget at begin (64 MiB of bytes present), pending claims charged at the cap, unsized objects ignored in the pending term, partial index on pending claims
Fourth audit (PASS, residual MEDIUM): one account could hold real bytes
during the grace with no bound. begin_avatar_upload now refuses rate_limited
when the caller's objects under its two prefixes plus one cap exceed
private.account_byte_budget(); pending claims count one 5 MiB cap each
(the declared size is not enforced by the upload); an object without a size
does not cancel its claim. pgTAP (plan 140): landed upload charged once by
its bytes, per-account budget refusal. STORAGE.md names the residuals
(colluding accounts at their budget, filesystem quota) and the musl ndots
detail.
2026-10-13 20:15:18 +02:00
bchanot 273914d825 fix(supabase): ceiling measured on bytes present in the bucket plus pending claims without bytes; confirm fails closed on an unsized object; cleartext host must start with a letter
Third audit (BLOCK 1): counting terminal rows while queued let begin spam
pin the ceiling with declared sizes. The ceiling now sums storage.objects
sizes of the bucket (whatever the row's state) plus the declared size of
pending_upload rows whose quarantine object has not landed: a claim dies
with its row, a present object counts whatever its row says, no full scan of
the assets history. confirm_asset_upload treats an object without a size as
upload_missing. pgTAP (plan 138): rejected rows without bytes weigh nothing,
pending claims fill, superseded claims vanish, present bytes fill, unsized
object refused. Worker: a single-label cleartext host must start with an
ASCII letter (0X… hex forms refused, test added); STORAGE.md names the
native-run search-domain residual.
2026-10-13 20:07:22 +02:00
bchanot c386a08b0b fix(supabase): second security pass — ceiling counts queued purges, confirm refuses more than declared, upload predicate needs an active account; worker cleartext host check strict
Re-audit findings: the ceiling now also counts terminal rows whose keys still
wait in the purge queue (contract wording kept honest, residual named);
confirm_asset_upload refuses an object larger than the declared size;
can_upload_avatar_object joins profiles.active; pgTAP covers the null
sha256 guard on a live lease, the three service_role revocations, the
queued-purge accounting and the deactivated-account upload (plan 137).
Worker: cleartext http only for localhost, a dotted-quad loopback address or
a non-numeric single-label name (numeric and hex hosts refused, tests added).
2026-10-13 19:58:54 +02:00