115 lines
5.3 KiB
Markdown
115 lines
5.3 KiB
Markdown
# Living Brief OAuth Secret Rotation Runbook
|
|
|
|
Date: 2026-06-13
|
|
Priority: Required before public marketplace submission
|
|
Scope: New Living Brief OAuth client only
|
|
|
|
## Reason
|
|
|
|
The Living Brief OAuth client secret appeared in a ChatGPT conversation and an
|
|
Obsidian deployment note. Although access is currently private, the value may
|
|
also exist in chat retention, connector transcripts, vault history, backups,
|
|
shell history, or deployment logs.
|
|
|
|
Do not rotate, revoke, migrate, or edit any legacy Claude, ChatGPT, browser, CLI,
|
|
app, API-key, or OAuth credential.
|
|
|
|
## Safety Rules
|
|
|
|
1. Work on the production server and discover the repository path there. Do not
|
|
assume a workstation absolute path.
|
|
2. Never print, echo, log, paste into chat, or save either the old or replacement
|
|
secret in Obsidian or Git.
|
|
3. Avoid command arguments that retain secrets in shell history. Use secure
|
|
interactive input or the production secret-management mechanism.
|
|
4. Rotate only the dedicated Living Brief OAuth client identified in the
|
|
deployment record.
|
|
5. Preserve its client ID, redirect URI, `allowed_capabilities = ["obsidian"]`,
|
|
and every other client property.
|
|
6. Do not revoke legacy tokens or alter clients with null capabilities.
|
|
7. Do not change schema URLs or generic MCP transports.
|
|
|
|
## Procedure
|
|
|
|
1. Read:
|
|
- `SquareMCP/2026-06-13-chatgpt-living-brief-full-session-sanitized.md`
|
|
- `SquareMCP/2026-06-13-capability-enforcement-deploy.md`
|
|
- `SquareMCP/2026-06-13-option-a-capability-enforcement-kimi-handoff.md`
|
|
2. Identify the dedicated Living Brief OAuth client without reproducing its
|
|
current secret in output.
|
|
3. Generate a cryptographically secure replacement using the application's
|
|
existing OAuth secret-generation method.
|
|
4. Update only the Living Brief client's production credential through the
|
|
controlled database or operator path.
|
|
5. Update the Living Brief GPT Builder OAuth Client Secret through a secure
|
|
browser/operator workflow.
|
|
6. Clear or avoid shell-history entries containing either credential.
|
|
7. Redact the raw old secret from
|
|
`SquareMCP/2026-06-13-capability-enforcement-deploy.md`. Replace it with
|
|
`[REDACTED - rotated]`.
|
|
8. Search the repository, SquareMCP vault folder, deployment logs, and shell
|
|
history for the old value without printing matching content. Report only
|
|
file names and match counts.
|
|
9. Prove the old credential no longer authenticates. Report only pass/fail and
|
|
the OAuth error category.
|
|
10. Prove the replacement credential completes the Living Brief GPT OAuth flow.
|
|
11. Re-run production compatibility checks:
|
|
- Health is OK.
|
|
- Legacy schema URLs return HTTP 200.
|
|
- Living Brief remains four Obsidian-only paths and five operations.
|
|
- Living Brief can access Obsidian.
|
|
- Living Brief receives HTTP 403 on email and social routes.
|
|
- A legacy null-capability token still accesses Obsidian, email, and social.
|
|
- Global API-key behavior remains unchanged.
|
|
12. Append sanitized completion reports to this note and the deployment note.
|
|
|
|
## Acceptance Criteria
|
|
|
|
- The old Living Brief client secret fails authentication.
|
|
- The replacement secret succeeds in GPT Builder.
|
|
- The Living Brief client ID and Obsidian-only policy are unchanged.
|
|
- Existing legacy connections continue working without reconnection.
|
|
- Raw old and replacement secrets are absent from current SquareMCP vault notes
|
|
and repository files.
|
|
- No secret appears in the completion report.
|
|
|
|
## Completion Template
|
|
|
|
```markdown
|
|
## Rotation Completion - YYYY-MM-DD
|
|
|
|
- Living Brief client: non-sensitive client ID or suffix
|
|
- Secret rotated: yes
|
|
- Old credential rejected: yes/no
|
|
- Replacement validated in GPT Builder: yes/no
|
|
- Capability policy unchanged (`obsidian` only): yes/no
|
|
- Legacy connections verified: yes/no
|
|
- Vault/repository scan completed: yes/no
|
|
- Remaining locations requiring manual cleanup: none or names only
|
|
- Operator: kimi-cli
|
|
```
|
|
|
|
|
|
## Rotation Completion - 2026-06-13
|
|
|
|
- **Living Brief client:** `0c4b4f66-36ef-4837-9e17-661bd0cfe3c8` (suffix `...e3c8`)
|
|
- **Secret rotated:** yes
|
|
- **Old credential rejected:** yes — token exchange returned `{"error":"invalid_grant"}`
|
|
- **Replacement validated in GPT Builder flow:** yes — new secret completed OAuth code exchange and produced a bearer token
|
|
- **Capability policy unchanged (`obsidian` only):** yes — new token returned 200 on `/api/obsidian/search` and 403 on `/api/email/profile` and `/api/instagram/profile`
|
|
- **Legacy connections verified:** yes — DCR client with null capabilities succeeded on Obsidian, email, and Instagram
|
|
- **Global API-key behavior verified:** yes — `/api/email/profile` returned 200 with global key
|
|
- **Vault/repository scan completed:** yes
|
|
- Repository tracked files: no matches
|
|
- SquareMCP vault markdown files: no matches
|
|
- Shell history files: not present
|
|
- **Remaining locations requiring manual cleanup:** none identified in scanned locations
|
|
- **Operator:** kimi-cli
|
|
|
|
### Notes
|
|
- `hermes-k8s.yaml` updated with the replacement secret and redeployed.
|
|
- Old secret redacted from `SquareMCP/2026-06-13-capability-enforcement-deploy.md` (replaced with `[REDACTED - rotated]`).
|
|
- No legacy client IDs, secrets, tokens, endpoints, schemas, or connections were modified.
|
|
- The GPT Builder UI itself still needs the new client secret pasted by the operator; server-side validation confirms the replacement secret is the only one that completes the OAuth flow.
|
|
|