You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
{{ message }}
Repository navigation
[SECURITY] Replace global os.environ overlay with async-safe per-org credential context #63
Multi-tenant credential isolation uses org_credentials() to temporarily mutate process-global os.environ. Collectors and tools then read keys via os.getenv().
Under FastAPI concurrent request handling, org A API keys can leak into org B in-flight requests. The queue worker, webhooks, Slack actions, and MCP calls share one DevOpsAgent singleton in the same process.
execute_approved_action() also runs without org scoping.
Impact
Cross-tenant credential bleed in multi-org deployments. A webhook for org acme could cause the agent to use contoso GitHub token or Anthropic key.
Proposed solution
Introduce an explicit CredentialContext passed through agent, collectors, and tools
Stop mutating os.environ for per-request org switching
Wrap execute_approved_action with org lookup and scoped credentials
Add concurrency tests: two orgs with distinct keys, overlapping requests, assert no cross-use
Activity