#13454: security: audit all configured channel accounts
commands
docker
stale
Cluster:
Session Management and Fixes
## Summary
- audit channel security across all discovered/configured accounts, not just the default account
- append per-account suffixes to channel security check IDs for multi-account plugins to keep findings unique
- include account labels in doctor security output/findings when multiple accounts exist
- add regression tests for non-default account coverage in doctor and security audit paths
## Validation
- pnpm -C /Users/davidahmann/Projects/agent-ecosystem/openclaw exec vitest run src/commands/doctor-security.test.ts src/security/audit.test.ts
<!-- greptile_comment -->
<h2>Greptile Overview</h2>
<h3>Greptile Summary</h3>
This PR expands channel security checks (doctor + `security audit`) to run across all discovered/configured accounts for multi-account channel plugins instead of only the default account.
Key changes:
- Iterate over `plugin.config.listAccountIds()` (plus the resolved default) and include per-account labels in outputs when more than one account exists.
- Append a per-account suffix to `checkId`s for channel findings so multiple accounts don’t overwrite/duplicate IDs.
- Add regression tests covering non-default account auditing paths.
<h3>Confidence Score: 3/5</h3>
- Mostly safe to merge, but checkId uniqueness across accounts can still break in real multi-account setups.
- Core iteration over discovered accounts looks correct and is covered by regression tests, but the current checkId suffix sanitization can cause collisions between distinct account IDs, undermining the stated goal of unique per-account findings.
- src/security/audit.ts (sanitizeCheckIdPart / checkId suffix generation)
<!-- greptile_other_comments_section -->
<sub>(2/5) Greptile learns from your feedback when you react with thumbs up/down!</sub>
<!-- /greptile_comment -->
Most Similar PRs
#15794: docs(security): comprehensive security audit report
by kinder-world · 2026-02-13
75.7%
#13881: fix: Address Greptile feedback - test isolation and channel resolution
by trevorgordon981 · 2026-02-11
73.1%
#11659: fix: Clarify session.dmScope is global in security audit warning
by veast · 2026-02-08
71.3%
#11110: fix(line): false 'not configured' warnings when tokenSource=file
by lailoo · 2026-02-07
71.3%
#11132: fix(telegram): guard command menu overflow and doctor warnings
by kiminbean · 2026-02-07
71.1%
#8024: fix(slack): resolve channel names via directory for cross-account m...
by emma-digital-assistant · 2026-02-03
70.8%
#11048: fix: address repository issues (env, author, CI comments, security ...
by cavula · 2026-02-07
70.7%
#19690: fix: security audit suppression, MoE false positive, and hook prefi...
by adityuhkapoor · 2026-02-18
70.4%
#21271: fix(commands): pass channel/capabilities/shell/os to runtime in com...
by evansantos · 2026-02-19
70.3%
#23165: fix(security): detect plaintext credentials in security audit
by ihsanmokhlisse · 2026-02-22
70.2%