Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Add foreground window check.yml #812

Merged
merged 4 commits into from
Aug 11, 2023
Merged
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
Original file line number Diff line number Diff line change
@@ -0,0 +1,23 @@
rule:
meta:
name: check for foreground window switch
namespace: anti-analysis/anti-vm/vm-detection
authors:
- [email protected]
description: Detect usage of GetForegroundWindow and Sleep APIs to check if there is any foreground window switch. Typically, sandboxes do not switch the foreground window like a user would in a normal environment.
scope: function
att&ck:
- Defense Evasion::Virtualization/Sandbox Evasion::User Activity Based Checks [T1497.002]
references:
- https://www.trendmicro.com/en_us/research/22/k/earth-preta-spear-phishing-governments-worldwide.html
- https://unprotect.it/technique/getforegroundwindow/
examples:
- 2855ba06b90e7c64d9bce888e47baf6d:0x4112A3
features:
- and:
- count(api(GetForegroundWindow)): 2 or more
- api: Sleep
- mnemonic: cmp
- or:
- characteristic: loop
- characteristic: tight loop
Loading