Scheduled task deleted. Indicates cleanup of a used task.
Attack cleanup (T1070). Created-used-deleted chain indicates backdoor task lifecycle.
Correlate with 4698. Alert: task deleted within 24 h of creation. Alert: deletion of tasks created by unexpected accounts.
SubjectUserNameTargetUserNameLogonTypeIpAddressWorkstationName | Tactic | Technique |
|---|---|
| Defense Evasion | Indicator Removal (T1070) |
Starting points — adapt the log source, projected fields and thresholds for your environment.
SecurityEvent
| where EventID == 4699 // A scheduled task was deleted
| project TimeGenerated, Computer, SubjectUserName, TargetUserName, LogonType, IpAddress, WorkstationName
| sort by TimeGenerated desc
index=* sourcetype="WinEventLog:Security" EventCode=4699
| stats count earliest(_time) as first_seen latest(_time) as last_seen by ComputerName
| sort - count `# A scheduled task was deleted — add EventData fields: SubjectUserName, TargetUserName, LogonType, IpAddress`
A scheduled task was deleted. Scheduled task deleted. Indicates cleanup of a used task.
Event 4699 is written to the Security channel by Microsoft-Windows-Security-Auditing. Advanced Audit Policy — enable the 'Policy Change' subcategory (Success and/or Failure).
Event 4699 is associated with: Indicator Removal (T1070).
Correlate with 4698. Alert: task deleted within 24 h of creation. Alert: deletion of tasks created by unexpected accounts.