Files

5.0 KiB

P05-OIDC-02 — Private Loopback Forwarder & Real OIDC Acceptance

Date: 2026-11-22 Baseline: b78270e9d45c1764c5642024b8147885deaacde3 Gitea Run #90: overall FAILURE on cbcd60e76ec909df4f9c5826adf7a3e2a899c73e: four disposable services healthy, no host ports; private loopback localhost:8080 not ready; no client/user/browser test executed. Owned cleanup PASS. P05-OIDC-02 status: Run #91 FAILED — private proxy/Host route PASS and prebuilt image/digest verification PASS, but socat sidecar exited with code 1 before provisioning; browser OIDC NOT EXECUTED. Owned cleanup PASS. Full acceptance BLOCKED.

Source changes

The existing manual Gitea workflow .gitea/workflows/p05-oidc-acceptance.yml is reused; original backend, P02 developer Compose, official Login V2 application, Account Portal Auth.js/source, and all manifests/lockfiles stay unchanged.

In tests/ci/oidc_e2e/run.sh only, the runner now distinguishes:

  1. Private proxy/Host readiness: a disposable Python container sharing Traefik's isolated network namespace makes GET /debug/ready on 127.0.0.1:80 with the exact Host: localhost:8080; HTTP 200 required before the forwarder.
  2. Verified prebuilt forwarding binary: Docker Hub versioned alpine/socat:1.8.1.3 (preinstalled socat; no runtime apk add). The CI runner verifies the socat entrypoint, resolves the pulled version to its immutable registry sha256 image digest and starts the run-owned sidecar by digest; no latest image. This image is published by the alpine/socat project; see Docker Hub repository, exact versioned tags.
  3. Private forwarder readiness and failure evidence: the sidecar shares only the CI proxy network namespace and binds 127.0.0.1:8080, forwarding to namespace-local Traefik:80. The runner checks exact labeled Docker sidecar state/exit code and makes a bounded no-secret /debug/ready HTTP 200 probe on forwarded port 8080 using Host: localhost:8080. A failed probe stops before provisioning and prints only safe stage/status, not token/cookie/query/sensitive HTTP bodies.
  4. Provisioner status-only readiness: tests/ci/oidc_e2e/provision.py::wait_until_ready() checks HTTP 200 from the private issuer. It no longer attempts to parse the readiness body as JSON. Actual official API project/client/human creation continues to parse validated JSON and must not bypass authentication.
  5. Cleanup: unchanged existing tests/ci/oidc_e2e/cleanup.sh still enforces numeric Gitea run ownership, exact sidecar/secret labels, backend Compose cleanup, and complete absence verification. No host published ports.

How acceptance is determined

The single already-approved manual Gitea workflow p05-oidc-acceptance.yml must prove private proxy/forwarder readiness and then actual official client/user provisioning, original Login V2 Chromium password flow, genuine Auth.js authorization-code PKCE/state/nonce callback, protected Account session and API user ID, anonymous and invalid callback rejection, local sign-out, and successful mandatory owned cleanup.

If any check is blocked, document exact job/run/stage and do not claim PASS for unexecuted steps. One Gitea cycle only; no repeat or local tests. No screenshots, real accounts, private secrets, production deployment, MFA/passkey or production HTTPS acceptance. Detailed plan/evidence: notes/P05-OIDC-02.md. Developer design: project/OIDC-E2E-ARCHITECTURE.md.

Actual Gitea Run #91 — FAILURE / authentication BLOCKED

The single authorized manual Gitea Run #91 tested source SHA 4831165548feabc2c0a0d39d25c40e0d1bc23bb2, job #198 overall FAILURE.

PASS: all four disposable backend services healthy; no published host ports; exact private Traefik:80 / Host: localhost:8080 returned HTTP 200; versioned prebuilt socat entrypoint and image digest verified.

FAIL: the private socat forwarder container exited immediately with exit code 1 (OIDC_CI_FORWARDER_NOT_RUNNING_STATE=exited EXIT_CODE=1). Its precise internal error is not yet established. The private forwarded 8080 readiness, real OIDC client/human creation, Chromium Login V2 and Auth.js authenticated callback/session/positive and negative checks were NOT EXECUTED.

Safety PASS: Gitea mandatory always() cleanup step #3 passed with ZITPLANE_BACKEND_CLEANUP_VERIFIED_PASS and ZITPLANE_OIDC_ALL_RESOURCES_CLEANED_PASS; owned database/bootstrap/credentials/containers/volumes/network removed. No real users, local tests or production touched; no CI rerun.

Next: P05-OIDC-03, only after separate approval, to classify the sidecar's safe startup failure and fix the private CI-only forwarding process (potential official Python stdlib TCP forwarder) before another single isolated acceptance. Never disable PKCE, change production Auth.js, expose a host port or call metadata/cleanup PASS an authenticated login PASS. Exact full evidence: notes/P05-OIDC-02.md.