Commit 8adb986
authored
feat(auth): add scoped OAuth access and browser-based CLI login (#7488)
Add scoped OAuth authorization-code login with PKCE, rotating token families, consent and revocation, and operation-level API scope enforcement. Preserve existing API-key, session, connector OAuth, and browserless CLI authentication.
Use the existing global AppConfig oauth-provider flag for request-time rollout control, with the environment variable as its standard fallback. Share the database lifecycle between migration and db:push, bound token cleanup, and document rollout sequencing.
Validation includes the full app, CLI, and database suites; both PostgreSQL provisioning paths; live browser and CLI authentication; API-key regression checks; and AppConfig off/on/off changes without restarting the app.1 parent ea3f6ba commit 8adb986
274 files changed
Lines changed: 38525 additions & 1504 deletions
File tree
- .github/workflows
- apps
- docs
- content/docs
- api-reference
- cli
- platform
- enterprise
- self-hosting
- sim
- app
- (auth)
- components
- oauth
- consent
- sign-in
- .well-known/oauth-authorization-server
- api/auth
- api
- auth
- .well-known/oauth-authorization-server
- [...all]
- oauth2
- authorize
- revoke
- token
- cron/cleanup-oauth-tokens
- files/uploads
- users/me/authorized-apps
- [clientId]
- v1
- knowledge
- v2
- chat-deployments
- chat
- files
- bulk-download
- knowledge
- [knowledgeBaseId]/documents
- [documentId]
- uploads/[uploadId]/complete
- search
- lib
- mcp-servers
- [mcpServerId]
- meta
- skills
- [skillId]
- editors
- tables/[tableId]
- query
- count
- rows/search
- workflows/[workflowId]
- deployments/chat
- deploy
- execute
- runs/[runId]
- cli/auth/done
- workspace/[workspaceId]/settings
- [section]
- components/authorized-apps
- background
- components/settings
- hooks/queries
- lib
- api
- application
- contracts
- v2
- __tests__
- openapi
- openapi
- server/routes
- audit-logs/application
- auth
- billing/application
- catalog/application
- chat-deployments/application
- copilot/application
- core
- application
- config
- credential-groups/application
- credentials/application
- custom-tools/application
- function-execution/application
- integrations
- knowledge/application
- logs/application
- mcp/application
- memory/application
- permission-groups
- platform-context/application
- sandboxes/application
- secrets/application
- selectors/application
- skills/application
- table/application
- tool-execution/application
- uploads/upload-session
- users
- application
- workflows
- application
- workspace-files/application
- workspaces/application
- scripts
- docker
- helm/sim
- packages
- audit/src
- auth/src
- db
- migrations
- meta
- script-migrations
- scripts
- sim-cli
- src
- auth
- commands
- config
- contract
- generated
- http
- runtime
- testing/src/mocks
- scripts
- openapi
Some content is hidden
Large Commits have some content hidden by default. Use the searchbox below for content that may be hidden.
| Original file line number | Diff line number | Diff line change | |
|---|---|---|---|
| |||
8 | 8 | | |
9 | 9 | | |
10 | 10 | | |
| 11 | + | |
| 12 | + | |
| 13 | + | |
| 14 | + | |
| 15 | + | |
| 16 | + | |
| 17 | + | |
| 18 | + | |
| 19 | + | |
| 20 | + | |
| 21 | + | |
| 22 | + | |
| 23 | + | |
| 24 | + | |
| 25 | + | |
| 26 | + | |
| 27 | + | |
| 28 | + | |
| 29 | + | |
| 30 | + | |
| 31 | + | |
| 32 | + | |
| 33 | + | |
| 34 | + | |
| 35 | + | |
| 36 | + | |
| 37 | + | |
| 38 | + | |
| 39 | + | |
| 40 | + | |
| 41 | + | |
| 42 | + | |
| 43 | + | |
| 44 | + | |
| 45 | + | |
| 46 | + | |
| 47 | + | |
| 48 | + | |
| 49 | + | |
| 50 | + | |
| 51 | + | |
| 52 | + | |
| 53 | + | |
| 54 | + | |
| 55 | + | |
| 56 | + | |
| 57 | + | |
| 58 | + | |
| 59 | + | |
| 60 | + | |
| 61 | + | |
| 62 | + | |
| 63 | + | |
| 64 | + | |
| 65 | + | |
| 66 | + | |
| 67 | + | |
| 68 | + | |
| 69 | + | |
| 70 | + | |
| 71 | + | |
| 72 | + | |
| 73 | + | |
| 74 | + | |
| 75 | + | |
| 76 | + | |
| 77 | + | |
| 78 | + | |
| 79 | + | |
| 80 | + | |
| 81 | + | |
| 82 | + | |
| 83 | + | |
| 84 | + | |
11 | 85 | | |
12 | 86 | | |
13 | 87 | | |
| |||
| Original file line number | Diff line number | Diff line change | |
|---|---|---|---|
| |||
1 | 1 | | |
2 | 2 | | |
3 | | - | |
| 3 | + | |
4 | 4 | | |
5 | 5 | | |
6 | 6 | | |
7 | 7 | | |
8 | 8 | | |
9 | | - | |
| 9 | + | |
| 10 | + | |
| 11 | + | |
10 | 12 | | |
11 | 13 | | |
12 | 14 | | |
| |||
87 | 89 | | |
88 | 90 | | |
89 | 91 | | |
| 92 | + | |
| 93 | + | |
| 94 | + | |
| 95 | + | |
| 96 | + | |
| 97 | + | |
| 98 | + | |
| 99 | + | |
| 100 | + | |
| 101 | + | |
| 102 | + | |
| 103 | + | |
| 104 | + | |
| 105 | + | |
| 106 | + | |
| 107 | + | |
| 108 | + | |
| 109 | + | |
| 110 | + | |
| 111 | + | |
| 112 | + | |
90 | 113 | | |
91 | 114 | | |
92 | 115 | | |
| |||
| Original file line number | Diff line number | Diff line change | |
|---|---|---|---|
| |||
26 | 26 | | |
27 | 27 | | |
28 | 28 | | |
29 | | - | |
| 29 | + | |
30 | 30 | | |
31 | 31 | | |
32 | 32 | | |
| |||
| Original file line number | Diff line number | Diff line change | |
|---|---|---|---|
| |||
15 | 15 | | |
16 | 16 | | |
17 | 17 | | |
18 | | - | |
| 18 | + | |
19 | 19 | | |
20 | 20 | | |
21 | 21 | | |
| |||
33 | 33 | | |
34 | 34 | | |
35 | 35 | | |
36 | | - | |
| 36 | + | |
37 | 37 | | |
38 | 38 | | |
39 | 39 | | |
| |||
43 | 43 | | |
44 | 44 | | |
45 | 45 | | |
46 | | - | |
| 46 | + | |
47 | 47 | | |
48 | 48 | | |
49 | 49 | | |
| |||
59 | 59 | | |
60 | 60 | | |
61 | 61 | | |
62 | | - | |
| 62 | + | |
63 | 63 | | |
64 | | - | |
| 64 | + | |
65 | 65 | | |
66 | 66 | | |
0 commit comments