T06 · System Persistence
- Location
SKILL.md:548- Finding
Persistent Scheduled Execution Through Cron, systemd, and launchd
- Content
View full analysis
/dev/null ``` ```bash # Create service: ~/.config/systemd/user/clawdbot-backup.service cat > ~/.config/systemd/user/clawdbot-backup.service << 'EOF' [Unit] Description=ClawdBot Backup [Service] Type=oneshot ExecStart=/home/user/.local/bin/clawdbot-backup backup full EOF # Create timer: ~/.config/systemd/user/clawdbot-backup.timer cat > ~/.config/systemd/user/clawdbot-backup.timer << 'EOF' [Unit] Description=Daily ClawdBot Backup [Timer] OnCalendar=daily Persistent=true [Install] WantedBy=timers.target EOF # Enable systemctl --user enable clawdbot-backup.timer systemctl --user start clawdbot-backup.timer ``` ```bash # Create plist: ~/Library/LaunchAgents/com.clawdbot.backup.plist cat > ~/Library/LaunchAgents/com.clawdbot.backup.plist << 'EOF' Label com.clawdbot.backup ProgramArguments /Users/username/.local/bin/clawdbot-backup backup full StartCalendarInterval Hour 2 Minute 0 EOF # Load launchctl load ~/Library/LaunchAgents/com.clawdbot.backup.plist ``` ### Technical Analysis ...[truncated 1818 chars]- Remediation
View remediation
