x

XML filter for username in Event Viewer

When querying for event 4625 (user lockout) or other similar events on DCs, you can filter by username using the below XML query in addition to whatever else might be necessary.

<QueryList>
  <Query Id="0" Path="Security">
    <Select Path="Security">* [EventData[Data[@Name='TargetUserName']='myuser']]</Select>
  </Query>
</QueryList>
Left-click: follow link, Right-click: select node, Scroll: zoom
x