From 8599ae86468a4a4f4965ee117b1be9b6db9173c9 Mon Sep 17 00:00:00 2001 From: Chris Burns <29541485+ChrisJBurns@users.noreply.github.com> Date: Sat, 21 Nov 2026 17:37:47 +0000 Subject: [PATCH] docs(agent-identity): compare AS-2 and AS-1 issuers including the path The configured AS-2 issuer rule said "the same server" but listed only scheme, host, and port, while its trailing-slash rule and the check it records compare the path too. Say it is the same issuer, and why two issuers on one host with different paths are distinct. Co-authored-by: Mecatl --- docs/drafts/agent-identity/credentials-and-lifecycle.md | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/docs/drafts/agent-identity/credentials-and-lifecycle.md b/docs/drafts/agent-identity/credentials-and-lifecycle.md index e4db122ea8..add6d1a8a0 100644 --- a/docs/drafts/agent-identity/credentials-and-lifecycle.md +++ b/docs/drafts/agent-identity/credentials-and-lifecycle.md @@ -556,7 +556,7 @@ ID-JAG makes a refresh token as subject token optional (ยง4.3: an IdP "MAY addit 6. The SVID passes the [SVID checks](#4-agent-instance-jwt-svid). 7. AS-1 authorizes the combination of client, subject, actor, and target. -**Configured AS-2 issuers.** No AS-2 issuer configured for `mecatl` names the same server as AS-1's issuer, comparing scheme and host case-insensitively, a default port as equal to none, and ignoring a trailing slash. `mecatl` authenticates to both servers with the same key, so a shared issuer would let a client assertion or an ID-JAG meant for one server be accepted by the other. Mecatl refuses such a configuration at startup. +**Configured AS-2 issuers.** No AS-2 issuer configured for `mecatl` is the same issuer as AS-1's, comparing scheme and host case-insensitively, a default port as equal to none, and the path ignoring a trailing slash. `mecatl` authenticates to both servers with the same key, so a shared issuer would let a client assertion or an ID-JAG meant for one server be accepted by the other. Two issuers on one host with different paths are distinct: each server accepts only an `aud` that names its own issuer. Mecatl refuses a shared issuer at startup. **How AS-1 runs check 6.** AS-1 does not know Mecatl's instance registry. For client `mecatl`, AS-1 calls its pluggable actor-token validator ([stacklok/toolhive#6899](https://github.com/stacklok/toolhive/issues/6899)). AS-1 passes the SVID, the client, and the grant's user: `sub` and `sub_id` from `RT-A42`'s record. Mecatl's validator runs in the broker. It runs the SVID checks, and check 8 checks that the instance's session is open and compares its owner with that `sub_id`. It returns the instance's SPIFFE ID, `spiffe:///agent/`, as the agent ID, and the SVID's `exp`. AS-1 puts the agent ID in `act.sub`, sets `act.iss` to the issuer registered with the validator, the agent trust domain `spiffe://`, and caps the ID-JAG's `exp` at the SVID's `exp`. AS-1 never falls back to its built-in actor-token handling.