Schtasks.exe
Schedule periodic tasks
Full path
c:\windows\system32\schtasks.exe
c:\windows\syswow64\schtasks.exeCommands
Create a recurring task to keep reverse shell session(s) alive
schtasks /create /sc minute /mo 1 /tn "Reverse shell" /tr "{CMD}"Create a recurring task to execute every minute.
os: Windows 7, Windows 8, Windows 8.1, Windows 10, Windows 11
Create a remote task to run daily relative to the the time of creation
schtasks /create /s targetmachine /tn "MyTask" /tr "{CMD}" /sc dailyCreate a scheduled task on a remote computer for persistence/lateral movement
os: Windows 7, Windows 8, Windows 8.1, Windows 10, Windows 11
Detection
- Sigma https://github.com/SigmaHQ/sigma/blob/c04bef2fbbe8beff6c7620d5d7ea6872dbe7acba/rules/windows/process_creation/proc_creation_win_schtasks_creation.yml
- Elastic https://github.com/elastic/detection-rules/blob/ef7548f04c4341e0d1a172810330d59453f46a21/rules/windows/persistence_local_scheduled_task_creation.toml
- Splunk https://github.com/splunk/security_content/blob/18f63553a9dc1a34122fa123deae2b2f9b9ea391/detections/endpoint/schtasks_scheduling_job_on_remote_system.yml
- IOCSuspicious task creation events