AAK-ROUTINE-002: Routine schedule interpolates unsanitized input
- Severity
- MEDIUM
- Category
- Agent Config (
agent-config) - Scanner
agent_audit_kit/scanners/routines.py- Auto-fixable
- No.
- SARIF name
RoutineScheduleInjection
What it detects
A routine's cron expression, HTTP webhook URL, or GitHub event filter is built from a user-controlled value. Schedule injection can repurpose the routine at off-hours without review.
How to fix
Treat schedule expressions as static constants; never build them from runtime state.
To confirm the finding is gone, report only this rule:
agent-audit-kit scan . --rules AAK-ROUTINE-002
Limitations
Reads the first of schedule, cron or trigger that is set, and only when it is a string containing ${, {{ or %{, so a static schedule hides an interpolated trigger beside it. A trigger written as a mapping (type: webhook with a url holding ${TENANT}), a webhook URL in a key of its own, and $(...) substitution are not read. A routine file over 1 MB is not read.
References
- OWASP Agentic Top 10: ASI10 (Rogue Agents)
- Adversa AI MCP Top 25 (AAK-defined ids): ADV-AGENCY-02
All rules. This page is generated from the rule registry when the documentation is built; to change it, change the rule in agent_audit_kit/rules/builtin.py. To give the rule a hand-written write-up, add docs/rules/AAK-ROUTINE-002.md: the page then shows that text, with the registry reference appended under it.