# NousResearch/hermes-agent · key_cmd shell injection hardening via argv fixes

## Open now

- 1 issue, 1 PR open on GitHub.
- #98831: \[P0\] key_cmd implicit shell + wrapper re-entry — trusted-operator hardening (hostile-writer allowlist tracked in #98910)
- PR #98913: fix(security): harden key_cmd argv — trusted-operator hardening beyond 97217 (Fixes #98831, tracks #98910)

These items address a security concern about key_cmd executing with implicit shell invocation, with fixes focused on switching to shell=False and native argv to reduce injection risk. Multiple related fix attempts and a tracking issue are grouped here.

## TL;DR

- 5 member(s): 1 open issue(s), 0 closed issue(s), 1 open PR(s), 0 merged PR(s), 3 PR(s) closed without merging.
- No fix has been merged to main; one or more PRs were attempted (see below).
- **Recommended:** review the prior/competing PR(s) below. A fix was attempted but not merged; your case may extend or revive that work.

## Maintainer resolution verdict

- Internal-tracker verdict over this cluster's issue members: `unresolved`. This is distinct from the fix status above. Weigh it yourself.

## How this cluster was grouped

- Link evidence (`STRUCTURAL_SPANNING`): every member is connected by structural evidence: shared changed files, or a closing/superseded reference.
- Pairwise link density `0.40`: the share of member pairs that carry a link, counting a structural link in full and a relevance-only link at 0.36. `1.00` means every pair is linked.

## Open related issues

- #98831: \[P0\] key_cmd implicit shell + wrapper re-entry — trusted-operator hardening (hostile-writer allowlist tracked in #98910)

## Prior & competing PRs

- **#98837: fix(security): harden key_cmd argv — trusted-operator hardening beyond 97217 (Fixes #98831, tracks #98910)**. closed without merge
  - maintainer direction: category `wontfix_bydesign`; implication `wontfix`; refs `#97217`, `#98831`
- **#98913: fix(security): harden key_cmd argv — trusted-operator hardening beyond 97217 (Fixes #98831, tracks #98910)**. open
  - maintainer direction: category `superseded_by_pr`; implication `superseded`; refs `#97217`
  - files: `agent/command_token_source.py`, `cli-config.yaml.example`, `tests/agent/test_command_token_source.py`, `website/docs/integrations/providers.md`
- **#103052: fix(security): prevent shell injection in key_cmd via shell=False on POSIX (#98831)**. closed without merge
  - maintainer direction: category `partial_fix`; implication `needs_llm`; refs `d93ce5f44411212adb14a925a6396932042078c4`, `13e72fb205b735df679e0fd5f5996a34ac4accc6`, `#98831`, `#98910`, `#97217`, `#98913`
- **#103695: fix(security): key_cmd runs as native argv - no shell, no wrappers (#98831)**. closed without merge
  - maintainer direction: category `superseded_by_pr`; implication `superseded`; refs `#98913`

## Fix status

- No merged fix on record.
- Subsystem: `agent`
