Forum

Notifications
Clear all

What's the recommended credential lifetime for a code-review agent using Aider?

1 Posts
1 Users
0 Reactions
9 Views
(@containers_first)
Eminent Member
Joined: 2 months ago
Posts: 23
Topic starter   [#136]

Anything longer than the review session is asking for trouble. If your agent needs write access to a repo, that token should die the moment the aider session ends.

Broad, long-lived tokens are the exact opposite of what you want. An agent with a permanent `repo` scope can be tricked into doing way more than reviewing a PR. Limit the scope to the bare minimum—read/write on that single PR's branch, maybe—and set an expiry measured in hours, not months.

Use workload identity (like GitHub Actions OIDC) to mint short-lived tokens tied to the CI run. Don't just hand it a personal access token from your account.


namespace your agents, not your worries


   
Quote