FortiAnalyzer
FortiAnalyzer can receive logs and Windows host events directly from endpoints connected to EMS, and you can use FortiAnalyzer to analyze the logs and run reports.
ck_FTNT
Staff
Staff
Article Id 204467
Description

This article describes how to use a custom event handler in FortiAnalyzer to raise alerts for incident response related to attacks that attempt to exploit a vulnerability in the Win32k.sys driver.

Scope This event handler and report help to detect attempts to gain privilege escalation through an exploit of the Win32k.sys driver based on logs from FortiGates, FortiClients, and FortiProxy.
Solution

The exploit allows a locally authenticated attacker to gain elevated local system or administrator privileges.

 

This vulnerability is assigned CVE-2022-21882.

 

For more information about this attack, see the following FortiGuard Outbreak Alert.

 

FortiGuard Outbreak Alert - Exploited Windows Local Privilege Escalation Vulnerability

 

What is included in Fortinet_Win32k_Privilege_Escalation.zip?

 

1) Win32k_Privilege_Escalation_event-handler.json

This event handler helps identify attacks that attempt to exploit a remote code execution vulnerability in the Microsoft HTTP protocol stack detected by FortiGate, FortiClient and FortiSandbox logs.

 

2) Win32k_Privilege_Escalation_report.dat

This report displays the findings on the HTTP protocol stack RCE outbreak from FortiGate, FortiClient and FortiSandbox logs.

 

3) fgt_Win32k_Privilege_Escalation_event-handler.json

The event handler for FortiGate ADOMs is configured for FortiGate logs only.

 

4) fgt_Win32k_Privilege_Escalation_report.dat

The report for FortiGate ADOMs includes FortiGate charts only.

 

All screenshots provided below for illustration purposes are taken from FortiAnalyzer 7.0.3.

 

1) Download the Fortinet_Win32k_Privilege_Escalation.zip file (contains 4 files).

 

2) Unzip Fortinet_Win32k_Privilege_Escalation.zip.

 

3) Import fgt_Win32k_Privilege_Escalation_event-handler.json or Win32k_Privilege_Escalation_event-handler.json event handler:

- Choose an ADOM (if ADOMs are enabled). The ADOM may be of type Fabric or FortiGate:

- Choose the FortiSOC module. 

- Select Event Handler List.

- Select the Import option under More.

- Select the appropriate event handler depending on your ADOM type.

FAZ_event_handler_import.PNG

 

Result:

The event handler is enabled and will be triggered if the appropriate logs are received following the import of the event handler. You may wish to edit the event handler to customize the notification section.

 

4) Import fgt_Win32k_Privilege_Escalation_report.dat or Win32k_Privilege_Escalation_report.dat to Reports:

- Choo

se an ADOM (if ADOMs are enabled). ADOM may be of type Fabric or FortiGate.
- Choose the Report module
- Select the Import option under "More"

- Select the appropriate file for the ADOM type to add the report to the ADOM.

 

FAZ_report_import.PNG

 

Result

The (fgt_)Win32k_Privilege_Escalation_report can be run anytime as determined by an admin user.