Skip to content
WETNav
SecurityProcess ExecutionIn-depth analysis

Event ID 4698: A scheduled task was created

Event 4698 logs the creation of new scheduled tasks on Windows systems. Attackers frequently use scheduled tasks for persistence, privilege escalation, and executing malicious code at specific times. This event is critical for detecting post-exploitation activity.

Channel
Security
Logged by default
No
Written on
Target host
Volume
Low
Needs a SACL
No

To have this event

  • Enable Other Object Access Events: auditpol /set /subcategory:"Other Object Access Events" /success:enable /failure:enable

Key fields

Exact XML field names, as they appear in <Data Name="…"> and in SIEM field extractions.

SubjectUserNameAccount that created the task
SubjectDomainNameDomain of the account
SubjectLogonIdLogon ID for correlation
TaskNameName of the scheduled task
TaskContentXML content defining the task (includes action, trigger, principal)
Have one of these events? Paste it into the decoder

In an investigation

Event 4698 is generated whenever a new scheduled task is registered on a Windows system, providing defenders with visibility into one of the most common persistence mechanisms used by adversaries. This event captures the task name, the user account that created it, and the complete XML definition of the task including the executable path, arguments, triggers, and privileges under which it will run. Threat actors favor scheduled tasks because they survive reboots, can execute with SYSTEM privileges, run without user interaction, and integrate seamlessly with legitimate Windows administrative activity. The event's XML content reveals critical indicators of malicious activity such as tasks configured to run with highest privileges, executables launched from temporary directories, tasks with names that mimic legitimate Windows task names to blend in, or tasks with immediate or very frequent triggers designed to ensure rapid re-infection. Security analysts should examine the task's action parameters for suspicious command lines, especially PowerShell with encoded commands, scripts from user-writable directories, or network-based file paths. The combination of Event 4698 with process creation (4688) when the task executes provides a complete picture of scheduled task abuse.

What it can reveal

  • Scheduled tasks running from temporary directories, user profiles, or C:\ProgramData are highly suspicious
  • Tasks configured with SYSTEM privileges but created by non-administrative accounts indicate privilege escalation
  • Task names that mimic legitimate Windows tasks (e.g., 'MicrosoftUpdate') but have different executables are malicious
  • Tasks with immediate triggers or very short intervals (every few minutes) suggest aggressive persistence
  • Remote task creation via AT or SCHTASKS commands often indicates lateral movement or remote execution

How to detect with it

Establish a baseline of legitimate scheduled tasks in your environment and alert on new task creation outside change windows. Monitor for tasks that execute from unusual locations, especially user-writable directories like Downloads, AppData, or Temp folders. Flag tasks created with administrative privileges but by non-admin accounts. Examine task XML for suspicious command patterns including PowerShell encodedCommand, rundll32 with unusual DLLs, or network UNC paths. Alert on tasks with names that closely match legitimate Windows tasks but have different executables or parameters. Correlate task creation with the creating user's recent activity to verify legitimacy. Track tasks that execute during off-hours or immediately after creation. SIEM detection rules and parsers for task XML content will be provided in subsequent updates.

Attack patterns

  • Scheduled task persistence attack pattern: malware registers a task whose name imitates a Windows component and whose action runs rundll32.exe or regsvr32.exe against a DLL under %AppData%; the task XML in 4698 shows the full path
  • Ransomware deployment attack pattern: operators push the same scheduled task to many hosts at once, running cmd.exe with a batch script from a network share, so one task name appears in 4698 on many machines within minutes
  • FIN7 group uses scheduled tasks to execute PowerShell Empire stagers that beacon to command-and-control servers

Compared withMonitor 4698 alongside 4688 (process creation) and 4624 (logon) to understand who created the task and when it executes. Event 4699 logs task deletion, which attackers use to clean up traces.

Pull this event

Retrieval queries for a live host, a collected .evtx file and common SIEMs. Filter further on the key fields above.

Get-WinEvent -LogName 'Security' -FilterXPath "*[System[(EventID=4698)]]" -MaxEvents 50 |
  Select-Object TimeCreated, Id, MachineName, Message

-FilterXPath supports exact matches only. For substring matching, filter in Where-Object.

Where it shows up

Investigations, attack signals and lateral movement techniques that rely on this event.

ATT&CK mapping

Techniques this event can help detect. Most of these depend on specific field values; the event alone does not mean the technique happened.

Common questions

What does Windows event ID 4698 mean?
Event 4698 logs the creation of new scheduled tasks on Windows systems. Attackers frequently use scheduled tasks for persistence, privilege escalation, and executing malicious code at specific times. This event is critical for detecting post-exploitation activity.
Is event 4698 logged by default?
No. It must be enabled before it is recorded. It is controlled by the "Other Object Access Events" Advanced Audit Policy subcategory (Object Access).
Where is event 4698 recorded?
In the Security channel on the target host.

Event 4698 logs the creation of new scheduled tasks on Windows systems. Attackers frequently use scheduled tasks for persistence, privilege escalation, and executing malicious code at specific times. This event is critical for detecting post-exploitation activity.