Commit Graph
234 Commits
Author SHA1 Message Date
Simon AxelssonandClaude Opus 5 89a435f837 fix(security,repo-honesty): real security headers + a doctor that checks truth, not presence
CI (SIAX Cloud) / security (push) Successful in 14s
Security Scan (SIAX Cloud) / security (push) Successful in 14s
CI (SIAX Cloud) / integration (push) Failing after 30s
CI (SIAX Cloud) / quality (push) Successful in 47s
Security Scan (SIAX Cloud) / security (pull_request) Successful in 14s
CI (SIAX Cloud) / integration (pull_request) Failing after 25s
CI (SIAX Cloud) / security (pull_request) Successful in 29s
CI (SIAX Cloud) / quality (pull_request) Successful in 48s
Two defects of the same kind: the repo asserted things about itself that were
not true, and nothing in it could tell.

A. CHANGELOG.md claimed CSP/HSTS/X-Frame-Options since 2026-08. `main`
   contained none of it -- a repo-wide grep for
   `content-security-policy|strict-transport-security|x-frame-options` matched
   exactly one file, CHANGELOG.md itself. The only header on 0pt.app was
   Vercel's own HSTS default, which does not survive the move to
   Coolify/Traefik that siax.config.json and .gitea/workflows/cd.yml are
   already pointed at.

   - next.config.mjs: `headers()` on `/(.*)` with CSP (frame-ancestors 'none',
     base-uri 'self', object-src 'none', form-action 'self'), HSTS,
     X-Frame-Options DENY, X-Content-Type-Options, Referrer-Policy,
     Permissions-Policy; plus poweredByHeader: false. Same idiom as
     sax3l/siax-io's next.config.mjs.
   - Carve-outs re-derived against THIS tree, not inherited: the stale
     `ci/security-headers-and-scanning` branch (8d2ff73, 142 commits behind)
     carried a `form-action https://checkout.stripe.com` allowance justified
     by a redirect that is actually `window.location.href`, which form-action
     does not govern -- dropped rather than kept as decorative permission.
     frame-src is derived from NOCODB_BASE_URL/METABASE_SITE_URL, the same env
     the components/embed.tsx iframe is configured from, so wiring that
     component up cannot be silently blanked by this header (the failure
     sax3l/siax-io recorded as SIO-013). 'unsafe-eval' is dev-only.
   - tests/security/security-headers.test.ts: blocking regression gate inside
     `pnpm run test`, i.e. the required "CI (SIAX Cloud) / quality" context.
     Asserts against expectations written out in the test, not imported from
     the config. Proven to fail: removing X-Frame-Options -> `pnpm run test`
     exits 1; weakening frame-ancestors to 'self' -> exits 1.

B. scripts/siax-doctor.mjs validated that siax.repo.json fields were PRESENT,
   never what they said. Measured on this tree: operationalState "running"
   (false) and "down" (true) both gave 40/40, exit 0, byte-identical output.

   - Value checks (enums, git.siax.io const, fleet node pattern, bare-hostname
     form), cross-file consistency (declared prod hostnames must appear in
     this repo's own siax.config.json / contracts/openapi.yaml, and vice
     versa), and GOV-06 substantiation: operationalState must be backed by a
     dated probe record in evidence/operational-state.json that agrees with
     it. Liveness is not knowable offline; whether a liveness CLAIM is backed
     is. Offline, deterministic, no network -- CI can never go red for want of
     an internet connection.
   - `--live` (opt-in) probes the declared hosts for real and checks the
     headers on the wire; `--write-evidence` refreshes the record. Not wired
     into CI on purpose.
   - tests/repo/siax-doctor.test.ts runs the doctor inside `pnpm run test` and
     asserts the negative cases against fixture trees (SIAX_DOCTOR_ROOT), so
     the "cannot fail" defect cannot come back.

C. CHANGELOG.md is now true. The header claim stands; the four claims it was
   bundled with (Trivy --exit-code 1, gitleaks, SHA-pinned actions, SBOM +
   license artifacts) are still false on main and are listed as not
   implemented instead of left asserted. All four live in .gitea/workflows/**,
   a protected path on this repo, so they need an authorised workflow change.

Nothing under .gitea/workflows/** or .gitignore is touched.

Verified: pnpm run typecheck exit 0; pnpm run test exit 0 (74 files / 965
tests passed, up from 72/945); pnpm run build exit 0 and the built
.next/routes-manifest.json carries all six headers; node scripts/siax-doctor.mjs
55/55 exit 0; --live 57/57 exit 0. eslint on the new files exit 0 (repo lint is
advisory and its 17 pre-existing problems are unchanged).

Co-Authored-By: Claude Opus 5 <noreply@anthropic.com>
2026-09-07 20:45:58 +02:00
admin 4514d97e13 Merge pull request 'feat: durable AUD0 outbox + dataset/search/ER HTTP surfaces + P065 stängd (kod, utan workflow-ändringar)' (#43) from feat/aud0-outbox-code-20260907 into main
Security Scan (SIAX Cloud) / security (pull_request) Successful in 13s
CI (SIAX Cloud) / security (pull_request) Successful in 17s
CI (SIAX Cloud) / quality (pull_request) Successful in 49s
CI (SIAX Cloud) / integration (pull_request) Failing after 54s
Deploy to Coolify / deploy (push) Failing after 4s
CI (SIAX Cloud) / security (push) Successful in 13s
Security Scan (SIAX Cloud) / security (push) Successful in 16s
CI (SIAX Cloud) / integration (push) Failing after 28s
CI (SIAX Cloud) / quality (push) Successful in 38s
2026-09-07 17:53:04 +00:00
admin 3c9abda020 ci: tar bort python-engine.yml — kräver estate-policy-beslut (skyddade filer)
CI (SIAX Cloud) / security (push) Successful in 16s
Security Scan (SIAX Cloud) / security (pull_request) Successful in 15s
Security Scan (SIAX Cloud) / security (push) Successful in 16s
CI (SIAX Cloud) / security (pull_request) Successful in 21s
CI (SIAX Cloud) / integration (push) Failing after 27s
CI (SIAX Cloud) / quality (push) Successful in 35s
CI (SIAX Cloud) / integration (pull_request) Failing after 36s
CI (SIAX Cloud) / quality (pull_request) Successful in 50s
Ny blockerande pytest-gate + Postgres/OpenSearch/ClickHouse-härdningen i
ci.yml ur PR #10 berör .gitea/workflows/ (estate-skydd). De nya real-infra-
testerna är exekverade lokalt (Postgres 5/5; OpenSearch/CH-gate behåller
main:s konfig tills beslut) — hålls utanför merge så koden landar.
2026-09-07 19:52:02 +02:00
admin 6befaa7be7 test(er): resolv-determinism — match-pairs behöver hard-rule decided_by
CI (SIAX Cloud) / security (pull_request) Successful in 14s
Security Scan (SIAX Cloud) / security (pull_request) Successful in 16s
Security Scan (SIAX Cloud) / security (push) Successful in 17s
CI (SIAX Cloud) / security (push) Successful in 29s
CI (SIAX Cloud) / integration (pull_request) Failing after 31s
CI (SIAX Cloud) / integration (push) Failing after 32s
CI (SIAX Cloud) / quality (pull_request) Successful in 36s
CI (SIAX Cloud) / quality (push) Successful in 38s
Python Engine CI (SIAX Cloud) / python-engine (push) Successful in 9m31s
Python Engine CI (SIAX Cloud) / python-engine (pull_request) Successful in 9m32s
_apply_matches ignorerar medvetet decided_by=score (defence in depth:
score/fuzzy får aldrig skapa canonical identity-länkar) — testernas
stub-bridge returnerade score-pairs och förväntade ändå merge → CI-fail var
implementationen som hade rätt. Pairs är nu decided_by=stable-identifiers.v3.

Verifierat: pytest services/api/tests 6+14 pass, full unit 945/945,
typecheck EXIT 0, real-Postgres 5/5.
2026-09-07 19:50:02 +02:00
Simon Axelsson cc6fbd71c5 Merge commit '3edc56d' into HEAD 2026-09-07 19:46:53 +02:00
admin 0eb9429932 ci: behåller main:s workflows (estate-skyddade filer)
CI (SIAX Cloud) / security (push) Successful in 15s
Security Scan (SIAX Cloud) / security (push) Successful in 14s
CI (SIAX Cloud) / quality (push) Failing after 27s
CI (SIAX Cloud) / integration (push) Failing after 30s
Security Scan (SIAX Cloud) / security (pull_request) Successful in 14s
CI (SIAX Cloud) / security (pull_request) Successful in 16s
CI (SIAX Cloud) / quality (pull_request) Failing after 20s
CI (SIAX Cloud) / integration (pull_request) Failing after 35s
Python Engine CI (SIAX Cloud) / python-engine (push) Failing after 4m56s
Python Engine CI (SIAX Cloud) / python-engine (pull_request) Failing after 4m48s
CI-härdningen ur PR #10 (Trivy HIGH/CRITICAL blocking, Postgres-service i
integration, python-engine pytest-gate) berör .gitea/workflows/ och kräver
estate-policy-beslut — dokumenterad separat, hålls UTANFÖR denna merge så
koden kanoniseras utan blockering. Härdningens nya tester är exekverade
lokalt: real-Postgres 5/5 (DATABASE_URL-aktiverad outbox).
2026-09-07 19:35:29 +02:00
admin 3edc56dcdb fix: slutgranskning av dataset/search/ER-ytorna + STATUS-sanning
Security Scan (SIAX Cloud) / security (push) Successful in 16s
CI (SIAX Cloud) / security (push) Successful in 17s
CI (SIAX Cloud) / integration (push) Successful in 29s
CI (SIAX Cloud) / quality (push) Successful in 48s
Security Scan (SIAX Cloud) / security (pull_request) Successful in 15s
CI (SIAX Cloud) / security (pull_request) Successful in 28s
CI (SIAX Cloud) / quality (pull_request) Successful in 48s
CI (SIAX Cloud) / integration (pull_request) Successful in 55s
Python Engine CI (SIAX Cloud) / python-engine (push) Failing after 4m52s
Python Engine CI (SIAX Cloud) / python-engine (pull_request) Failing after 4m48s
Slutgate inför merge (per fortsättningsplan):

Kontrakt: CreateDatasetVersionInput.artifact_refs → readonly string[]
(anropare får skicka 'as const'; servicen muterar aldrig); postgres.js
tx.array() får muterbar kopia vid INSERT.

Testkorrigeringar (stale mot starkare implementation — aldrig svagare):
- entity-resolution-http: request(body, undefined) triggade default-param
  och skickade GILTIGT token → 200. Tomt token = 'utan token' → 401 fail-closed.
- entity-resolution: /two records/ → /between 2 and 5000/ (bounds-aware validering)
- search-service: omformat purpose-filter-test + NY negativ kontroll —
  rebuild avvisar dokument utan purpose_tags (fail closed, generation discarded)
- dataset-postgres.realinfra: sätter DATABASE_URL i setup så den durabla
  AUD0-outboxen aktiveras (testet ljög annars om durabilitet) — 5/5 mot live Postgres

STATUS.md: AUD0-klient + lineage-rader (outbox nu real-infra testad),
gap-listan (persistence/routes/outbox stängda, exakt vad som återstår),
P065 STÄNGD med closure-record (thin adapter, v3-semantik, hard-negative
transitivitet, fail-closed 401 — 4/4 planpunkter verifierade).

Verifierat: typecheck EXIT 0 · 945/945 unit · 5/5 real-Postgres · next build EXIT 0
2026-09-07 19:31:22 +02:00
admin e49f809e68 Merge pull request 'fix(descriptor): 0PT operationalState running -> down (measured 2026-09-07)' (#41) from fix/descriptor-0pt-operational-state-down into main
Deploy to Coolify / deploy (push) Successful in 2s
Security Scan (SIAX Cloud) / security (push) Successful in 15s
CI (SIAX Cloud) / security (push) Successful in 17s
CI (SIAX Cloud) / integration (push) Successful in 28s
CI (SIAX Cloud) / quality (push) Successful in 51s
2026-09-07 17:02:47 +00:00
Simon AxelssonandClaude Opus 5 8dd85ad7cc fix(descriptor): 0PT operationalState running -> down (measured)
CI (SIAX Cloud) / integration (push) Successful in 26s
CI (SIAX Cloud) / quality (push) Successful in 32s
Security Scan (SIAX Cloud) / security (push) Successful in 37s
CI (SIAX Cloud) / security (push) Successful in 37s
Security Scan (SIAX Cloud) / security (pull_request) Successful in 14s
CI (SIAX Cloud) / security (pull_request) Successful in 15s
CI (SIAX Cloud) / integration (pull_request) Successful in 30s
CI (SIAX Cloud) / quality (pull_request) Successful in 56s
Both public 0PT hosts are dead as of 2026-09-07:

  $ curl -sSI https://0pt.app/
  HTTP/2 402 ... server: Vercel ... x-vercel-error: DEPLOYMENT_DISABLED
  (identical on /api/health and /api/ready)

  $ curl -sSI https://api.0pt.app/health
  HTTP/2 404 ... server: Vercel ... x-vercel-error: DEPLOYMENT_NOT_FOUND

siax.repo.json claimed operationalState "running"; siax.repo.v3.json
claimed "degraded" on the strength of a 2026-09-04 probe where
/api/health still answered 200. Neither holds now, so both files move to
"down" and both domain entries record the probe that motivated it.

Also recorded: both names resolve into Vercel address space
(216.150.16.193 / 216.150.1.1 and 216.150.1.129 / 216.150.16.65), not
the Hetzner fleet.

No DNS, deploy or provider setting was touched.

Co-Authored-By: Claude Opus 5 <noreply@anthropic.com>
2026-09-07 18:50:38 +02:00
admin e2437ab09e docs(er): reconcile ecosystem acquisition plan with canonical ER architecture
CI (SIAX Cloud) / security (push) Successful in 16s
CI (SIAX Cloud) / quality (push) Failing after 19s
Security Scan (SIAX Cloud) / security (push) Successful in 32s
CI (SIAX Cloud) / integration (push) Failing after 49s
Python Engine CI (SIAX Cloud) / python-engine (push) Failing after 5m34s
2026-09-07 18:22:26 +02:00
admin 93c01d2264 fix(er): refuse score-only matches at Python merge boundary 2026-09-07 18:18:33 +02:00
admin d0cba02ee0 feat: expose idempotent N0D-backed batch ER submission 2026-09-07 18:18:23 +02:00
admin 7d11ea895c feat: expose generic tenant-safe ER candidate API 2026-09-07 18:18:12 +02:00
admin 35a8ff0f2a feat: add generic ER composition root 2026-09-07 18:18:02 +02:00
admin 243918a255 feat: harden canonical ER service and idempotent batch submission 2026-09-07 18:17:52 +02:00
admin 9782eaf42c refactor: share ER request validation across HTTP surfaces 2026-09-07 18:17:00 +02:00
admin 00e4636655 refactor: centralize ER request validation 2026-09-07 18:16:43 +02:00
admin 6f525c5c9e fix: pass registration country into canonical company identity rules 2026-09-07 18:15:47 +02:00
admin 76038205ca ci: require Postgres-backed search definition integration path 2026-09-07 18:13:17 +02:00
admin ed1abc4cd4 test: prove search definitions survive restart across Postgres and OpenSearch 2026-09-07 18:12:50 +02:00
admin 6d02a5cd34 auth: allow service-token search definition administration 2026-09-07 18:12:16 +02:00
admin 84945a2ff7 feat: expose tenant and purpose constrained search query route 2026-09-07 18:11:58 +02:00
admin e400afc882 feat: expose governed durable search definitions 2026-09-07 18:11:44 +02:00
admin f3a8cf6cc2 feat: add production search composition root 2026-09-07 18:11:31 +02:00
admin 82f7475b91 fix: audit only newly created durable search definitions 2026-09-07 18:11:06 +02:00
admin 8dfd429a61 refactor: return stable creation metadata for search definition audit 2026-09-07 18:10:13 +02:00
admin d45eb74772 test(er): cover country-qualified stable identifiers 2026-09-07 18:09:46 +02:00
admin 195c4611dc chore: remove redundant search definition index 2026-09-07 18:09:44 +02:00
admin e13d550837 fix(er): country-qualify company registration identifiers 2026-09-07 18:09:12 +02:00
admin 9961ac7e03 refactor: make search definitions restart-safe 2026-09-07 18:09:05 +02:00
admin 7e2b5304b7 test(er): pin review-only fuzzy company boundary 2026-09-07 18:08:24 +02:00
admin dd01fe76c9 feat: add durable versioned search definition repository 2026-09-07 18:08:09 +02:00
admin 04d861b920 fix(er): require human review for score-only company matches 2026-09-07 18:07:56 +02:00
admin 1c1d14a3eb feat: persist versioned search index definitions 2026-09-07 18:07:45 +02:00
admin ccda286022 feat: expose tenant-safe dataset version describe route 2026-09-07 18:07:09 +02:00
admin e70acc8981 feat: expose durable dataset version create and query routes 2026-09-07 18:07:01 +02:00
admin b5ffdbc091 feat: expose tenant-safe dataset describe route 2026-09-07 18:06:46 +02:00
admin 102e1e1616 feat: expose tenant-safe dataset registry HTTP surface 2026-09-07 18:06:36 +02:00
admin 70fd81dc4d feat: share durable dataset services across route modules 2026-09-07 18:06:21 +02:00
admin 97f26834c7 ci: run durable dataset and AUD0 outbox tests on live Postgres 2026-09-07 18:05:59 +02:00
admin 851e43d8db test: prove dataset registry and versions against real Postgres 2026-09-07 18:05:15 +02:00
admin 3c5850fbe5 refactor: persist dataset versions and make lineage retry-stable 2026-09-07 18:03:21 +02:00
admin 3ccdcf0cf6 fix: use postgres arrays and normalized idempotency comparison 2026-09-07 18:02:38 +02:00
admin 906fe9ac37 feat: add durable dataset version repository 2026-09-07 18:01:56 +02:00
admin a3bad9aa12 refactor: extract canonical dataset version types 2026-09-07 18:01:24 +02:00
admin 8432d19d8c fix: scope dataset version idempotency uniqueness to real keys 2026-09-07 18:01:14 +02:00
admin 298c965448 feat: add durable dataset version store 2026-09-07 18:00:58 +02:00
admin ea02f4e9f7 refactor: persist DatasetService through repository boundary 2026-09-07 18:00:47 +02:00
admin 5dbd53045c feat: add durable dataset registry repository 2026-09-07 18:00:29 +02:00
admin 6a687212a1 test: pin lineage queued-vs-emitted semantics 2026-09-07 17:59:20 +02:00