molecule-core/platform
rabbitblood 95d0bc25a3 fix(slack): address code review — 6 critical + improvement fixes
Code review findings addressed:

Critical:
1. Bot echo loop: add bot_id + subtype='bot_message' check in ParseWebhook
   to prevent outbound auto-posts from triggering inbound → infinite loop
2. Connection leak: close resp.Body immediately after reading instead of
   defer inside loop (was holding N connections open for N chunks)
3. Cancelled context: auto-post goroutine now uses context.Background()
   with 30s timeout instead of inheriting fireCtx (which gets cancelled
   by deferred cancel() when fireSchedule returns)
4. Slug validation: regex ^[a-zA-Z0-9 _-]+$ rejects path traversal and
   special chars in [slug] routing

Improvements:
5. Shared HTTP client (slackHTTPClient) for connection pooling instead of
   per-request &http.Client{}
6. Rune-safe truncation in BroadcastToWorkspaceChannels for CJK/emoji
7. Log async HandleInbound errors instead of silently discarding
8. url_verification challenge properly returned (c.JSON with challenge)

Co-Authored-By: Claude Opus 4.6 (1M context) <noreply@anthropic.com>
2026-04-17 14:15:51 -07:00
..
cmd/server feat(slack): Level 1 auto-post + Level 2 inbound routing 2026-04-17 14:15:51 -07:00
docs/adr fix(wsauth): restore ValidateAnyToken removed-workspace JOIN (#682 defense-in-depth), restore ADR-001 blast-radius docs 2026-04-17 12:25:44 +00:00
internal fix(slack): address code review — 6 critical + improvement fixes 2026-04-17 14:15:51 -07:00
migrations feat(slack): upgrade adapter to Bot API with per-agent identity + fix pgvector migration 2026-04-17 14:15:51 -07:00
pkg/provisionhook fix(github): refresh installation token when TTL < 10 min (#547) (#567) 2026-04-17 00:47:03 +00:00
Dockerfile fix: address all code review findings + remove exposed secrets 2026-04-16 05:05:49 -07:00
Dockerfile.tenant fix: address all code review findings + remove exposed secrets 2026-04-16 05:05:49 -07:00
entrypoint-tenant.sh feat(platform): auto-detect SaaS tenant → control plane provisioner 2026-04-16 11:50:52 -07:00
go.mod feat(platform): wire github-app-auth plugin for per-installation tokens 2026-04-16 12:52:20 -07:00
go.sum feat(platform): wire github-app-auth plugin for per-installation tokens 2026-04-16 12:52:20 -07:00