T06 · System Persistence
Error
- Location
- SKILL.md:289
- Finding
- Recurring Cron Job Creates Cross-Session Persistence## Vulnerability Details **File Location**: `SKILL.md`, lines 289–297 **Vulnerability Type**: Scheduled task persistence **Risk Level**: High **Vulnerable Code:** ```bash # Add to OpenClaw cron python3 skills/obsidian-ontology-sync/scripts/setup-cron.py # Or manually via cron tool cron add \ --schedule "0 */3 * * *" \ --task "python3 skills/obsidian-ontology-sync/scripts/sync.py extract" \ --label "Obsidian → Ontology Sync" ``` ### Technical Analysis The Skill instructions direct the agent or user to register a recurring cron task that executes the extraction script every three hours. This scheduled task survives the original Skill run and continues executing across sessions, meeting the definition of system persistence. The referenced `setup-cron.py` file is not included in the audited project, so its behavior could not be verified. Nevertheless, the documented manual `cron add` command is independently actionable and explicitly establishes recurring execution. When invoked, `scripts/sync.py` recursively reads Markdown files from configured vault source directories. It extracts data such as names, email addresses, telephone numbers, organizations, projects, and source paths, then appends derived records to `graph.jsonl`. The scheduled process therefore causes repeated processing and duplication of potentially sensitive personal and business data without requiring confirmation for each run. No network communication, remote payload retrieval, subprocess execution from `sync.py`, privilege escalation, or data exfiltration was identified. The scheduled task runs with the permissions of the account under which it is registered. ### Attack Path 1. A user or agent loads the Skill and follows its automatic synchronization instructions. 2. The user runs the undocumented `setup-cron.py` command from another installation source, or executes the provided `cron add` command. 3. A recurring job is registered to run ...[truncated 1254 chars]
- Remediation
- ## Remediation Suggestions 1. Make scheduled synchronization explicitly opt-in rather than presenting it as a routine installation step. 2. Require clear user confirmation immediately before creating each recurring job. 3. Display the exact command, schedule, executable path, data sources, output location, and execution identity before registration. 4. Include documented commands to list, disable, and permanently remove every scheduled job created by the Skill. 5. Use absolute, validated script and configuration paths so path replacement or working-directory manipulation cannot redirect execution. 6. Run the task under a dedicated least-privileged account with access limited to the required vault directories and ontology output. 7. Add file locking, deduplication, and retention controls to prevent unbounded append-only storage growth. 8. Document which personal and business fields are extracted, how long derived data is retained, and where it is stored. 9. Do not instruct users to execute `setup-cron.py` unless that file is included and available for security review. 10. Prefer an on-demand synchronization command where persistence is not essential.
