This hunt targets adversaries executing pw-inspector.exe, a known Chinese hacktool often used for credential harvesting and system reconnaissance during early-stage intrusions. Proactively searching for this artifact in Azure Sentinel is critical to identify potential supply chain compromises or targeted espionage activities that may evade standard signature-based detections due to the tool’s legitimate appearance.
rule pw_inspector {
meta:
description = "Chinese Hacktool Set - file pw-inspector.exe"
author = "Florian Roth"
reference = "http://tools.zjqhr.com/"
date = "2015-06-13"
hash = "4f8e3e101098fc3da65ed06117b3cb73c0a66215"
strings:
$s1 = "-m MINLEN minimum length of a valid password" fullword ascii
$s2 = "http://www.thc.org" fullword ascii
$s3 = "Use for hacking: trim your dictionary file to the pw requirements of the target." fullword ascii
condition:
uint16(0) == 0x5a4d and filesize < 460KB and all of them
}
This YARA rule can be deployed in the following contexts:
This rule contains 3 string patterns in its detection logic.
Here are 4 specific false positive scenarios for the detection rule Chinese Hacktool Set - file pw-inspreter.exe, along with suggested filters or exclusions:
Scenario: Legitimate Enterprise Password Auditor Deployment
pw-inspector.exe. This tool runs periodically to scan local user profiles for weak passwords and generate compliance reports.Scenario: Scheduled Group Policy Software Installation
pw-inspector.exe as a prerequisite installer for the “Chinese Hacktool” suite intended for specific regional branches. The file is extracted to a temporary folder (C:\Windows\CCMCache) before installation.ccmsetup.exe or smsagenthost.exe and the File Path starts with C:\Windows\CCMCache\. Additionally, restrict this exclusion to business hours (e.g., 08:00–18:00) if the deployment is time-bound.Scenario: Legacy Application Migration Task