Repository navigation
feat(age): report auto-lock countdown in age agent status - #3656
Merged
Merged
Conversation
`gopass age agent status` only reported whether the agent was running and locked, leaving users unable to tell how long an unlocked session would last before the inactivity timer cleared the cached identities. Add a read-only `lock-in` command to the agent protocol that answers `OK <seconds>` until the inactivity timer fires, or `OK -1` when no auto-lock is scheduled (the timer is disabled or the agent is already locked). The agent tracks the timer deadline and reports it without ever arming, resetting or disarming the timer, so polling cannot keep a session alive. The command is advertised as a capability token, derived from the dispatch table like every other command. The client fetches status, lock-in and hello over the existing single connection; a legacy agent's ERR on lock-in degrades to -1 and is treated as "countdown unavailable" rather than an error. `age agent status` prints the remaining time only when the agent is unlocked and advertises the capability, so a legacy agent is never misreported as "auto-lock disabled". Signed-off-by: Dominik Schulz <dominik.schulz@gauner.org>
dominikschulz
force-pushed
the
feat/ageautolock
branch
from
October 10, 2026 07:55
effc682 to
002c9c6
Compare
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
gopass age agent statusonly reported whether the agent was running and locked, leaving users unable to tell how long an unlocked session would last before the inactivity timer cleared the cached identities.Add a read-only
lock-incommand to the agent protocol that answersOK <seconds>until the inactivity timer fires, orOK -1when no auto-lock is scheduled (the timer is disabled or the agent is already locked). The agent tracks the timer deadline and reports it without ever arming, resetting or disarming the timer, so polling cannot keep a session alive. The command is advertised as a capability token, derived from the dispatch table like every other command.The client fetches status, lock-in and hello over the existing single connection; a legacy agent's ERR on lock-in degrades to -1 and is treated as "countdown unavailable" rather than an error.
age agent statusprints the remaining time only when the agent is unlocked and advertises the capability, so a legacy agent is never misreported as "auto-lock disabled".