mirror of
https://github.com/openai/codex.git
synced 2026-12-04 00:51:02 +00:00
## Why A guest alias needs to expose only the claims selected by policy. Refresh also needs a way to detect changes to claims the guest never sees. ## What changed Add a test-only helper that reads expiry from a trusted source JWT and builds fresh JWT-shaped aliases containing only selected scalar claims. Each alias uses a random placeholder in the signature segment. Hash all stable claims, including undisclosed ones, in deterministic JSON order. Exclude `exp`, `nbf`, `iat`, and `jti` so changes to those fields during refresh preserve the digest. ## Testing Cover selective disclosure, alias freshness, and refresh comparisons. Exercise rejection of malformed tokens, duplicate keys, invalid validity fields, ambiguous numbers, and disallowed disclosures. GitOrigin-RevId: 48bc19ac57601e28d5c2cb8881f0ac0f5563aca9