The README carries the write-side query contract, and the numbers describe that tree
The contract section said the unknown-parameter guard refuses on the list
endpoints. It now refuses on every endpoint under /admin-api, and the
interesting part is not the coverage: it is that the guard itself had the
bug. It assumed limit/offset were legal everywhere, so GET
/admin-api/countries?limit=2 was answered with the whole table by the
image that already carried the guard.
Numbers re-measured on ac672d9, not carried forward:
host unit 128/128, integration 170/170, smoke 28/0,
compose 94/0, console 58/0, image 261 MB, 0 containers
linux source PASS (128/128, 170/170, 28/28), compose 94/0 with
enforcement lag 11 ms, console 58/0
act 5 jobs succeeded, 0 failed; console-evidence.zip 534,721 bytes
compose assertion history: ... 81 before the retry loop, 86 before the
write-endpoint guard, 94 now
This commit is contained in:
@@ -25,8 +25,8 @@
|
||||
# scripts/ci-linux-rehearsal.sh runs the gates in containers. Source gates
|
||||
# (restore, build, unit, integration, smoke) in mcr.microsoft.com/dotnet/sdk:10.0
|
||||
# - Ubuntu 24.04.5, SDK 10.0.401 resolving the pinned global.json: unit 128/128,
|
||||
# integration 141/141, smoke 28/28, first try (at dcf8a73). Compose gate in docker:cli against
|
||||
# the host daemon: 86/86 on Linux. Console gate in
|
||||
# integration 170/170, smoke 28/28, first try (at ac672d9). Compose gate in docker:cli against
|
||||
# the host daemon: 94/94 on Linux. Console gate in
|
||||
# mcr.microsoft.com/playwright:v1.63.0-noble - the stack seeded by docker:cli,
|
||||
# the same console-check.cjs driving it in a real Linux Chromium: 58/58. The
|
||||
# only wall clock ever measured for the source job is 1:02.81 cold (first
|
||||
@@ -35,8 +35,8 @@
|
||||
# number. What it does not have is a runner: the repository has no remote, so
|
||||
# this file has never executed on GitHub. It has been executed by a local
|
||||
# Actions-compatible runner (nektos/act 0.2.89, catthehacker/ubuntu:act-latest)
|
||||
# at dcf8a73: 5 jobs succeeded, 0 failed - lint, source (128/128, 141/141, smoke
|
||||
# 28/0), image (261 MB, compose smoke 86/0), console (58 assertions, screenshot
|
||||
# at ac672d9: 5 jobs succeeded, 0 failed - lint, source (128/128, 170/170, smoke
|
||||
# 28/0), image (261 MB, compose smoke 94/0), console (58 assertions, screenshot
|
||||
# artifact) and freshness (pin 2026-10 = newest 2026-10).
|
||||
|
||||
name: ci
|
||||
|
||||
@@ -331,6 +331,25 @@ and the guard's first run broke three tests that were right to send it, which
|
||||
is the worse failure mode for a guard of this kind: refusing a request that
|
||||
works.
|
||||
|
||||
That guard covered the read side only, and the image that carried it then
|
||||
answered the same request two ways depending on the verb. Measured on that image:
|
||||
`POST /admin-api/blocks?zzz=1` answered **204** and wrote the ban, `PUT
|
||||
/admin-api/policy?zzz=1` answered **200** and changed the policy, `PUT
|
||||
/admin-api/countries/DE?allowed=true&zzz=1` answered **204**, `DELETE
|
||||
/admin-api/blocks?key=…&zzz=1` answered **200** `{"deleted":1}` — while `GET
|
||||
/admin-api/blocks?zzz=1` answered 400 naming the parameter. The silent half was
|
||||
the half that changes state: a misspelled scoping parameter on a write acts with
|
||||
a wider scope than the caller meant, and answers as if the scope had applied.
|
||||
Every endpoint under `/admin-api` refuses an unknown parameter now — the writes,
|
||||
plus `/state`, `/geo` and `/policy`, which take none — and the refusal runs
|
||||
before any state change, so a rejected write cannot half-happen. One measurement
|
||||
changed the design rather than the coverage: `GET /admin-api/countries?limit=2`
|
||||
still answered 200 with every row after the GET guard landed, because that
|
||||
listing has no paging to honour and the guard had assumed `limit`/`offset` were
|
||||
legal everywhere — the same bug one level down, in the guard itself. Each
|
||||
endpoint now declares its own parameter surface and the base set is only `token`,
|
||||
so the list a refusal prints is true for the endpoint that printed it.
|
||||
|
||||
The exemption listing was the last one left uncapped, and it had a second fault
|
||||
worth more than the ceiling. `GET /admin-api/allow` answered with every row ever
|
||||
written and no statement of whether any of them still meant anything. Measured on
|
||||
@@ -706,26 +725,26 @@ macOS working tree make the next `--no-build` try to exec an ELF file — inside
|
||||
`mcr.microsoft.com/dotnet/sdk:10.0`. The compose gate runs in `docker:cli`
|
||||
against the host daemon, so the image build and the stack are Linux.
|
||||
|
||||
Rehearsed 2026-10-02, most recently at `dcf8a73`, each stage run on its own, so
|
||||
Rehearsed 2026-10-02, most recently at `ac672d9`, each stage run on its own, so
|
||||
the numbers below describe the tree at the head of this file rather than a
|
||||
commit several fixes behind it. The same suite on the macOS host at `dcf8a73`
|
||||
gives the same counts: unit **128/128**, integration **141/141**, smoke **passed
|
||||
28, failed 0**, compose **86 passed, 0 failed**, console **58 assertions, 0
|
||||
commit several fixes behind it. The same suite on the macOS host at `ac672d9`
|
||||
gives the same counts: unit **128/128**, integration **170/170**, smoke **passed
|
||||
28, failed 0**, compose **94 passed, 0 failed**, console **58 assertions, 0
|
||||
failed**, image 261 MB, 0 containers left behind. Source gates: Ubuntu
|
||||
24.04.5, SDK **10.0.401** resolving `dotnet/global.json` (pinned `10.0.100`,
|
||||
`rollForward: latestFeature` — which is also the answer to whether
|
||||
`setup-dotnet` with `10.0.x` satisfies the pin), unit **128/128**, integration
|
||||
**141/141**, smoke **28/28**, first try, nothing to fix. The first
|
||||
**170/170**, smoke **28/28**, first try, nothing to fix. The first
|
||||
rehearsal of this pipeline timed a cold container and a cold NuGet cache at
|
||||
**1:02.81**; the runs after it were not re-timed, so that is the only wall clock
|
||||
measured here, and the source job's 25-minute timeout is not close either way.
|
||||
Compose gate on Linux: **86 passed, 0 failed** (27 before the geo-pin and
|
||||
Compose gate on Linux: **94 passed, 0 failed** (27 before the geo-pin and
|
||||
alerting assertions, 41 before the alert-edge ones, 47 before the pillar-health
|
||||
ones, 53 before the write-health ones, 63 before the ban-write ones, 72 before
|
||||
the scenes were made non-vacuous, 74 before the query surface was refused rather
|
||||
than dropped, 81 before the retry loop), enforcement lag 0 ms, 12 ms and 36 ms in
|
||||
than dropped, 81 before the retry loop, 86 before the write-endpoint guard), enforcement lag 0 ms, 12 ms and 36 ms in
|
||||
three runs, 12 ms at `a77ab53`, 13 ms at `6e6461a`, 11 ms at `c97c7a1`, 12 ms at
|
||||
`7e081da`, 12 ms at `7b57c56`, 14 ms at `1bcc086`, 12 ms at `336c2f7`, 13 ms at `dcf8a73`. Console gate on Linux: **58
|
||||
`7e081da`, 12 ms at `7b57c56`, 14 ms at `1bcc086`, 12 ms at `336c2f7`, 13 ms at `dcf8a73`, 11 ms at `ac672d9`. Console gate on Linux: **58
|
||||
assertions, 0 failed** — described below, 0 containers left behind. `scripts/geo-db-freshness.sh` was run
|
||||
in `mcr.microsoft.com/dotnet/sdk:10.0` too: current pin answers 0, and a forced
|
||||
`PIN=2026-05` answers 1 with the bump command, so the gate that decides whether
|
||||
@@ -765,12 +784,12 @@ the stage re-run after it leaves 0 containers.
|
||||
Honest status of the workflow itself: it has never executed on a GitHub-hosted
|
||||
runner, because the repository has no remote. It *has* been executed start to
|
||||
finish by a local Actions-compatible runner — `nektos/act` 0.2.89 on
|
||||
`catthehacker/ubuntu:act-latest`, most recently at `dcf8a73` — 5 jobs
|
||||
`catthehacker/ubuntu:act-latest`, most recently at `ac672d9` — 5 jobs
|
||||
succeeded, 0 failed: `lint` (both pinned tools download, verify their checksums
|
||||
and find nothing), `source` (unit 128/128, integration 141/141, smoke 28/28),
|
||||
`image` (`openwaf:ci` 261 MB, compose smoke 86 passed / 0 failed), `console`
|
||||
and find nothing), `source` (unit 128/128, integration 170/170, smoke 28/28),
|
||||
`image` (`openwaf:ci` 261 MB, compose smoke 94 passed / 0 failed), `console`
|
||||
(58 assertions / 0 failed with `playwright@1.63.0` and `chromium-1243`,
|
||||
screenshot artifact published, 524,624-byte zip) and the `freshness` job (pin
|
||||
screenshot artifact published, 534,721-byte zip) and the `freshness` job (pin
|
||||
2026-10 = newest 2026-10). That is a stronger claim than
|
||||
"the steps were run by hand", and a weaker one than "CI is green": it proves the
|
||||
YAML executes and the pinned tools resolve, not that GitHub's image agrees. The
|
||||
@@ -813,9 +832,9 @@ dotnet/
|
||||
OpenWaf.Infrastructure/ EF Core (sqlite/postgres), snapshot store, writers, MMDB geo
|
||||
OpenWaf.Edge/ the deployable: guard, observer, admin API, healthcheck mode
|
||||
OpenWaf.Tests.Unit/ 128 tests over the decision logic
|
||||
OpenWaf.Tests.Integration/ 141 tests driving the real pipeline against a fake upstream
|
||||
OpenWaf.Tests.Integration/ 170 tests driving the real pipeline against a fake upstream
|
||||
scripts/smoke.sh 28 assertions against a running edge + a real upstream
|
||||
scripts/compose-smoke.sh 86 assertions against the built image (compose + nginx)
|
||||
scripts/compose-smoke.sh 94 assertions against the built image (compose + nginx)
|
||||
scripts/console-check.cjs 58 assertions against the page, in a real Chromium
|
||||
scripts/geo-db-freshness.sh the pinned geo database vs the vendor (0/1/2)
|
||||
.github/workflows/ci.yml runs the gates on every push
|
||||
|
||||
Reference in New Issue
Block a user