Skip to content

rotate-key: key path resolution differs from keygen, with no override flag #46

Description

@solomonneas

What

keygen honors -out (cmd/agentpantry/main.go:173). rotate-key (:190-232) resolves from the config's key_path, else the config dir's psk.key, and exposes no -key/-out flag.

Why

An operator who ran keygen -out <custom> and then rotate-key without a matching config could rotate a different file, conditional on another default key existing. Add a -key flag (selecting which file only; it must not change the grace-window semantics, where the old key stays accepted until -finish), or document the resolution order at README.md:282-302. Fits the SC-12 key-lifecycle control set, NIST SP 800-53 Rev. 5 (doi:10.6028/NIST.SP.800-53r5).

Effort

S

Source: three-lane research sweep (repo audit + comparables + literature), independently reviewed before filing; run 20260724-040709-e9fc6818.

Metadata

Metadata

Assignees

Labels

enhancementNew feature or requestsize/SSmall: under an hour

Type

No type

Projects

No projects

Milestone

No milestone

Relationships

None yet

Development

No branches or pull requests

Issue actions