Skip to content
WETNav
Windows PowerShellScript Execution

Event ID 400: Engine state changed to Available (engine start)

Written in the classic Windows PowerShell log each time a PowerShell engine starts. Its detail text records the host and, critically, the engine version of the session.

Channel
Windows PowerShell
Logged by default
Yes
Written on
Any host
Volume
High
Provider
PowerShell
Needs a SACL
No

Key fields

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

EngineVersionVersion of the PowerShell engine that started (within the event detail text). EngineVersion 2.0 on a modern host is the hallmark of a deliberate downgrade to evade script block logging
HostVersionVersion of the host application (within the event detail text); also exposes 2.0 downgrades via '-Version 2'
HostNameName of the host that started the engine (e.g. ConsoleHost, Windows PowerShell ISE Host), within the detail text
HostApplicationFull command line of the process hosting the engine (within the detail text); shows how PowerShell was launched
RunspaceIdGUID of the runspace, for correlating lifecycle events
NewEngineStateNew engine state (Available); PreviousEngineState shows the transition
Have one of these events? Paste it into the decoder

Analyst notes

  • 01400 is present by default, so it provides PowerShell coverage even where Operational script block logging is off.
  • 02Hunt for EngineVersion/HostVersion 2.0: PowerShell 2.0 predates script block logging and AMSI, so a downgrade is a common evasion. Pair with the presence of the .NET 2.0 / PowerShell 2.0 feature.
  • 03HostApplication reveals launches such as 'powershell -version 2 -nop -enc ...'; this field is the main investigative value of 400.
  • 04The rich detail lives in the event's detail text as key=value lines, not as separate XML Data attributes.

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 'Windows PowerShell' -FilterXPath "*[System[(EventID=400)]]" -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 400 mean?
Written in the classic Windows PowerShell log each time a PowerShell engine starts. Its detail text records the host and, critically, the engine version of the session. It is written to the Windows PowerShell log (Windows PowerShell).
Is event 400 logged by default?
Yes, a default Windows installation records it.
Where is event 400 recorded?
In the Windows PowerShell channel on the any host.

Written in the classic Windows PowerShell log each time a PowerShell engine starts. Its detail text records the host and, critically, the engine version of the session. Key fields, logging requirements, ATT&CK mapping and ready-to-run queries.