event.dataset: "o365.audit"
and event.action: "UserLoggedIn"
and o365.audit.ApplicationId: "aebc6443-996d-45c2-90f0-388ff96faa56"
and o365.audit.Target.ID: "00000003-0000-0000-c000-000000000000"
and o365.audit.ExtendedProperties.RequestType: "OAuth2:Authorize"
and o365.audit.ExtendedProperties.ResultStatusDetail: "Redirect"
and o365.audit.UserType: ("0" or "2" or "3" or "5" or "6" or "10")
Install detection rules in Elastic Security
Detect Microsoft 365 OAuth Phishing via Visual Studio Code Client in the Elastic Security detection engine by installing this rule into your Elastic Stack.
To setup this rule, check out the installation guide for Prebuilt Security Detection Rules(opens in a new tab or window).