Skip to content

[CRED-2815] Document PAT/SAT scope, TTL, and app-key restrictions#38326

Draft
emubello wants to merge 2 commits into
masterfrom
emu/cred-2815/update-docs-pat-constraints
Draft

[CRED-2815] Document PAT/SAT scope, TTL, and app-key restrictions#38326
emubello wants to merge 2 commits into
masterfrom
emu/cred-2815/update-docs-pat-constraints

Conversation

@emubello

@emubello emubello commented Jul 20, 2026

Copy link
Copy Markdown

What does this PR do? What is the motivation?

Adds a Restrictions section to the Personal Access Tokens and Service Access Tokens pages documenting new containment rules for API calls authenticated with a PAT or SAT:

  • Cannot create or update application keys (revoke is still allowed)
  • Cannot mint or update another PAT/SAT with scopes broader than its own
  • Cannot create a PAT/SAT with a longer TTL than its own

Calls that violate these restrictions return a 403 Forbidden response.

Add a Restrictions section to the Personal Access Tokens and Service
Access Tokens pages describing the new containment rules: PATs/SATs
cannot create or update application keys, cannot mint or update
another PAT/SAT with broader scopes than their own, and cannot create
a PAT/SAT with a longer TTL than their own.
@github-actions

Copy link
Copy Markdown
Contributor

@emubello
emubello requested review from a team, jackakeller and tyjet July 20, 2026 18:24

- **Application keys**: A PAT cannot create or update application keys. Revoking application keys is still allowed.
- **Scopes on new tokens**: A PAT can create or update another PAT or a SAT only if the new token's scopes are a subset of its own scopes.
- **Time-to-live (TTL) on new tokens**: A PAT cannot create a PAT or a SAT with a TTL that outlives itself.

Copy link
Copy Markdown

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

question (blocking): My interpretation of this is that if my PAT is expiring and I want to mint a new PAT for myself, I cannot use the expiring PAT to do so. Is this correct.

Copy link
Copy Markdown
Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Yes this is correct

Copy link
Copy Markdown
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

This is why having a "rotate" endpoint would be useful. WDTY @tyjet?

Comment thread content/en/account_management/service-access-tokens.md Outdated
Comment thread content/en/account_management/service-access-tokens.md Outdated
A SAT cannot create a PAT, since PAT creation is always scoped to the
authenticated caller. Remove that language from the SAT restrictions
section.
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

3 participants