Skip to content

chore: scrub committed API keys + security baseline - #1409

Merged
tieubao merged 3 commits into
developfrom
chore/harden-mochi-api
Aug 27, 2026
Merged

chore: scrub committed API keys + security baseline#1409
tieubao merged 3 commits into
developfrom
chore/harden-mochi-api

Conversation

@tieubao

@tieubao tieubao commented Jun 24, 2026

Copy link
Copy Markdown
Contributor

Console Labs consolidation hardening pass (sub-goal 05), lighter adoption.

SECURITY (action needed): pkg/config/config.go hardcoded two live third-party API keys as viper defaults in this PUBLIC repo (SOLSCAN_TOKEN, BIRDEYE_API_KEY). This PR scrubs them to "" (env-only; prod already injects via env). They are still in git history, so rotate both keys at SolScan + Birdeye. Values are not reproduced anywhere. Pre-merge: confirm prod supplies both via env. See docs/SECURITY-AUDIT-2026-06-25.md.

Also:

  • .gitleaks.toml allowlists test/seed/sample fixtures (47 gitleaks false positives) so the CI gate fires on real leaks; gitleaks now clean.
  • .github/workflows/security.yml: gitleaks + govulncheck on PRs.
  • CLAUDE.md + docs/ARCHITECTURE.md: agent guidance + reindex.
  • Flagged (not fixed): Go module is still github.com/defipod/mochi (orphan defipod URL; renaming is breaking, follow-up).

No other logic touched, no dependency bumped. Reviewable + reversible.

tieubao and others added 3 commits August 27, 2026 13:23
Console Labs consolidation hardening (lighter adoption).
- SECURITY: pkg/config/config.go hardcoded SOLSCAN_TOKEN + BIRDEYE_API_KEY as
  viper defaults in this PUBLIC repo. Scrubbed to "" (env-only). The exposed
  keys must be ROTATED at the providers (still in git history). See
  docs/SECURITY-AUDIT-2026-06-25.md.
- .gitleaks.toml: allowlist test/seed/sample fixtures (47 false positives) so
  CI gates on real leaks; gitleaks now clean.
- .github/workflows/security.yml: gitleaks + govulncheck on PRs.
- CLAUDE.md + docs/ARCHITECTURE.md: repo guidance + reindex.
No other logic touched, no dependency bumped.

Co-Authored-By: Claude Opus 4.8 (1M context) <noreply@anthropic.com>
Additive (consolidation hardening): points at CLAUDE.md + ARCHITECTURE +
security baseline + build/test. Existing 7KB README preserved.

Co-Authored-By: Claude Opus 4.8 (1M context) <noreply@anthropic.com>
The SOLSCAN_TOKEN/BIRDEYE_API_KEY scrub and the gitleaks/govulncheck
CI setup this PR originally proposed were both superseded upstream by
the time it rebased onto develop. Update the two doc files to
describe what actually landed instead of what the original diff
proposed.
@tieubao
tieubao force-pushed the chore/harden-mochi-api branch from 559ffa1 to 23720b9 Compare August 27, 2026 06:25
@tieubao
tieubao merged commit ef07723 into develop Aug 27, 2026
5 checks passed
@tieubao
tieubao deleted the chore/harden-mochi-api branch August 27, 2026 06:29
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.

1 participant