Commit fc0cced
authored
Simplify Compose control-plane authentication (#38)
## Summary
`bb apps` previously exchanged the normal opaque bbidentity session for
a Compose-specific purpose token, then cached, refreshed, and retried
requests with that token. The new contract moves that exchange to public
ingress: while the request is paused, ingress sends the bbidentity
session to the authorizer and replaces it with a short-lived Compose JWT
before forwarding.
The CLI now sends `Authorization: BBIdentity <credential>` only to the
exact staging and production Compose control-plane hosts over HTTPS.
Redirects stay disabled, cookies and legacy identity headers are
omitted, and reflected credentials are redacted from errors. Apps
commands require an already-valid stored session in every mode;
otherwise they fail promptly with `auth_required` and direct the caller
to explicit `bb auth login`. Only the explicit auth command owns the
browser login flow. The old exchange, cache, refresh, and retry
machinery is removed.
The staging infrastructure still needs to be activated before this can
be smoke-tested end to end. Merging this PR also does not update an
installed `bb` binary: Berd ships the CLI through its normal pinned
release process.
### Related issue
N/A. This replaces auth work from the archived pre-OSS repository.
### Testing
- `cd bb-cli && source ./bin/activate-hermit && just check`
- `cd bb-cli && source ./bin/activate-hermit && just build-bb-release`1 parent 9fefd79 commit fc0cced
11 files changed
Lines changed: 1449 additions & 1635 deletions
File tree
- bb-cli
- src
- bb
- tests
- crates/builderbot-auth/src
Some generated files are not rendered by default. Learn more about customizing how changed files appear on GitHub.
| Original file line number | Diff line number | Diff line change | |
|---|---|---|---|
| |||
19 | 19 | | |
20 | 20 | | |
21 | 21 | | |
22 | | - | |
23 | 22 | | |
24 | 23 | | |
25 | 24 | | |
| |||
| Original file line number | Diff line number | Diff line change | |
|---|---|---|---|
| |||
104 | 104 | | |
105 | 105 | | |
106 | 106 | | |
107 | | - | |
| 107 | + | |
108 | 108 | | |
109 | 109 | | |
110 | 110 | | |
| |||
0 commit comments