Commit graph

22 commits

Author SHA1 Message Date
e521e7b715 feat(policy): adopt security zone stances
All checks were successful
CI Smoke / host-smoke (push) Successful in 0s
CI Smoke / container-smoke (push) Successful in 1s
Build and Publish Container Image / build-and-push (push) Successful in 33s
Assistant: codex
Assistant-Model: gpt-5.6-sol
Assistant-Session: 01a0291a-1e87-7151-9934-fcbfe3f65eb1
2026-08-22 15:17:13 +02:00
1e1e077b27 Implement inbound caller authentication (ADR 0004); close T03 and T05
TokenReview-based caller identity with audience-scoped tokens and exact
resource.system to ServiceAccount bindings, per ops-warden's recommendation.
Deletes the unwired tenant-engine live-roles adapter (T03) and adds
make verify-posture (T05). Source implements A2; running digest is still A0
until promotion, so tenancy.current.A stays 0.

Co-Authored-By: Claude Opus 5 <noreply@anthropic.com>
2026-08-18 15:22:52 +02:00
d2dc39a8b8 FLEX-WP-0008 T03-T04: tenant-engine live-lookup context adapter, close
All checks were successful
CI Smoke / host-smoke (push) Successful in 1s
CI Smoke / container-smoke (push) Successful in 3s
internal/adapters/tenantengine: HTTPClient.LiveRoles() calls tenant-engine's
GET /tenants/{id}/roles/live. LiveRolesResult.Available is the load-bearing
field -- false on any transport error, non-200, or malformed body, never
inferred as zero roles. AttachToContext() writes both tenant_roles and
tenant_roles_available into a CheckRequest.Context map; a consuming Rego
policy must check tenant_roles_available before trusting tenant_roles.

Architectural finding recorded in the workplan: engine.go's Check() has no
context-adapter hook, and none of the existing topaz/relationship/rule
adapters are wired into cmd/flex-auth either -- they're standalone packages
for downstream composition. This adapter is a request-preparation helper a
protected system's own request-building code calls before POST /v1/check,
not an engine-internal hook, matching that precedent exactly.

9 Go tests; gofmt/vet/build clean; go test ./... green repo-wide.

Verified as a real three-service chain: live flex-auth serve + live
tenant-engine, created a tenant and granted it a CUS role through the real
flex-auth-gated write path, then read it back through this adapter (via a
throwaway harness, not committed) -- known tenant: roles=[CUS]
available=true; unknown tenant: roles=[] available=false err="status 404".

FLEX-WP-0008 closed: T01-T04 all done. tenant-engine's write path is now
real end-to-end; any other protected system can pull live tenant capability
role context, fail-closed. Remaining open item unchanged from TEN-WP-0003:
KEY-WP-0005 (key-cape's IAM Profile core-claims gap).

Co-Authored-By: Claude Sonnet 5 <noreply@anthropic.com>
2026-07-23 23:33:34 +02:00
0fde95a87c FLEX-WP-0006: implement ops-warden signing gate policy 2026-06-23 21:17:42 +02:00
32933c71f9 Add directory group resolver adapters 2026-05-17 07:24:50 +02:00
360025e38b Add Keycloak authorization adapter path 2026-05-17 07:18:45 +02:00
ad4895187b Add rule PDP adapter boundary 2026-05-17 07:13:27 +02:00
4bb329c921 Add relationship PDP adapter boundary 2026-05-17 07:06:14 +02:00
1ce0181e8f Implement Topaz adapter 2026-05-17 06:58:04 +02:00
3d1967cb41 Add Markitect adapter contract tests 2026-05-17 06:36:52 +02:00
7e09a21c5f Add Markitect check fixtures 2026-05-17 06:32:05 +02:00
b6712850c3 Define Markitect action vocabulary 2026-05-17 06:26:13 +02:00
9e2591c1f4 Import Markitect resource manifests 2026-05-17 06:21:28 +02:00
18054bd160 Add CARING examples and coverage 2026-05-17 06:05:18 +02:00
61e113f8b6 Add CLI and service skeleton 2026-05-17 05:59:48 +02:00
2b103ea70b Add local decision log 2026-05-17 05:51:37 +02:00
faea068721 Implement list allowed and explain 2026-05-17 05:45:36 +02:00
54984585e3 Implement deterministic check APIs 2026-05-17 05:38:57 +02:00
550d096cb2 Implement policy package loader 2026-05-17 05:30:40 +02:00
3c4f8fc2b4 Implement local registry store 2026-05-17 05:10:17 +02:00
7fdf6d63d5 Implement canonical schema foundation 2026-05-17 04:59:18 +02:00
55120ec20a Land foundations: assessment, ADR-001/002/003, FLEX-WP-0005, Go skeleton
Pre-implementation assessment and boundary review
(docs/pre-implementation-assessment.md) lead to three ADRs:
- ADR-001 Go + repo skeleton
- ADR-002 Rego-in-Markdown policy package format
- ADR-003 Topaz-aligned MVP (Topaz spike moves into foundations)

New workplan FLEX-WP-0005 (Foundations and Topaz Alignment) is inserted
between WP-0001 (done) and WP-0002 (core). WP-0002 pins Rego-in-Markdown
for P2.3; WP-0004 P4.1 refocused from Topaz evaluation to Topaz adapter.

Go skeleton at repo root: cmd/flex-auth + internal/{registry,policy,
decision,audit,adapters} + pkg/api + Makefile + .golangci.yml + GitHub
Actions CI. make ci green locally; bin/flex-auth --version works.

INTENT/SCOPE cite the NetKingdom IAM Profile and add the ops-warden /
ops-bridge disjoint-surface clarifications.

Co-Authored-By: Claude Opus 4.7 <noreply@anthropic.com>
2026-05-16 01:54:44 +02:00