Repository navigation
Agentao 0.5.23
Shell permission rules get harder to slip past. A custom allow on a shell
command no longer allows a chained or expanding command, and a deny or
ask now also catches other spellings and other letter case of the same
command. The interactive CLI gains new commands for looking at and managing a
session. agentao run handles signals for the whole run and exits 143 on
SIGTERM, and a cancel now stops a model request that hangs on the network.
Several of these change behaviour. They are listed under "Behaviour
changes" at the end.
Shell permission rules
-
A custom
allowapplies only to a simple command. A rule such as
{"tool": "run_shell_command", "args": {"command": "^git "}, "action": "allow"}
used to match the start of the text, so it also allowed
git status && curl … | sh. A customallowwith anargs.command
condition now applies only to a command with no chaining, redirection,
subshell, substitution, leading variable assignment, or variable, glob or
brace expansion, read in the dialect of the shell that runs it. On any
other command the rule is skipped and the rules after it decide. Name the
subcommands you mean and anchor the end:{"rules": [{"tool": "run_shell_command", "args": {"command": "^git (status|branch)$"}, "action": "allow"}]} -
A
denyoraskmatches in any case.GIT pushruns git on macOS's
and Windows' default filesystems, and PowerShell and cmd ignore case, so it
used to get past adenyongit push. Write(?-i:-x)to keep part of a
pattern exact. -
A
denyoraskalso sees other spellings. Quotes and escapes
(g''it push, cmd'sg^it push, PowerShell'sg`it push), a program
path (/usr/bin/git push), an.exesuffix and extra spaces no longer get
a command past it. A wrapper in front of the program (env git push) or
an option before the subcommand (git -C . push) is still not caught, so
treat a commanddenyas best-effort. -
The
workspace-write/planpreset now denies a recursive forcermin
any flag spelling (rm -fr,rm -Rf,rm --recursive --force). It asked
before.
An allow still matches case-sensitively and sees only the raw text, so none
of this grants anything that was not granted before.
New in the interactive CLI
/permission also shows where the mode came from, and the policy sources
/plugins hooks the plugin hooks this session loaded, and plugins that failed to load
/sessions rename name the current session
/sessions clone save a resumable copy of a session
/export <path> save the conversation as a local Markdown file
/diff staged, unstaged and untracked changes in the repository
/mcp verbose each MCP server's command or URL, sign-in, tools, resources and skills
/skills manage a checkbox picker to enable and disable skills
/permissionand/plugins hooksreport what the session recorded at
startup and at each mode switch. A config file edited later does not change
them, and opening them runs no hook. Hook commands, prompts and URLs are
never shown./exportleaves out system instructions, reasoning, runtime notes and tool
calls unless you pass--tools. It never overwrites a file without
--force./diffsends no model request and does not touch the index or the working
tree./mcp verbosehides env and header values, and everything in a URL after
scheme://host[:port]. It masks credentials it recognises in args; a bare
token passed as a positional arg is not caught.- On a terminal, bare
/skillsnow opens the picker. The list moved to
/skills list.
agentao run and cancelling
- Exit
143on SIGTERM. A run stopped bykill, systemd, a container or
a CI shutdown exits143withinterrupted (sigterm). Ctrl+C still exits
130. - Signals are handled for the whole run. A signal during the agent build,
a session hook or the result write used to kill the process with no result
document. A second signal, at least 0.5 s after the first, now exits at
once. - A setup error is reported in the result document, as
runtime_error
with exit1, and no longer as a traceback. - A cancel stops a hung model request. A provider that never answered
held the turn until the request timed out. The request now runs on a
worker thread, and the turn checks for a cancel every 0.1 s, so an
agentao runsignal, an ACPsession/canceland the interactive CLI end
the turn. - ACP clients see LLM retries. Each retry is sent as an
agent_thought_chunksuch as[retry 1/4: status=503, retrying in 7.5s].
Fixes
- A
"mode": "plan"saved in.agentao/settings.jsonno longer starts the
CLI in a broken plan state. It falls back toworkspace-write, and
/permissionsays why. The CLI never savesplan. - Leaving
/planduring the temporary full-access grant (answering2)
restores the same mode as/sessions resume, not whatever
settings.jsonhappened to hold. settings.json,mcp.jsonandgoal.jsonare written atomically, so a
crash mid-write no longer leaves a truncated file.
For hosts
agentao.embedding.sessions:clone_session(),clone_agent_session()
andclone_saved_session(), which raiseSessionLimitReachedwhen 10
sessions are saved.save_session()andpersist_agent_session()take a
keyword-onlyname=, and eachlist_sessions()entry has anamekey.CancellationToken.cancel_from_signal(reason)cancels from a signal
handler without deadlocking.- Plan mode entry, plan mode exit and a session reset now emit
PERMISSION_MODE_CHANGEDwith their owncause:cli-plan,
cli-plan-exitandcli-reset.
Behaviour changes
- A custom shell
allowwritten for one chained command
(^make build && make test$) now asks. - A shell
denyoraskpattern can catch a flag it did not mean: a deny on
curl -xalso refusescurl -X POST. - On cmd, the read-only preset list no longer runs
echo %VAR%without
asking. - A wrapper that read exit
130as "stopped by any signal" must also accept
143. - A second signal before the result is written now exits at once, without
the result document or cleanup. - Bare
/skillson a terminal opens the picker; use/skills listfor the
list. - A consumer that matched
cause == "cli"no longer sees plan mode exits or
session resets, and replay files now record plan mode entry.
See CHANGELOG.md for the full entries.