Skip to content
This repository was archived by the owner on Nov 16, 2023. It is now read-only.

Commit 4123c76

Browse files
authored
Merge pull request #246 from martyav/adwind-java
Added Adwind queries
2 parents a8451cd + 0e92475 commit 4123c76

File tree

2 files changed

+88
-0
lines changed

2 files changed

+88
-0
lines changed
Lines changed: 43 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,43 @@
1+
# Hiding a Java class file
2+
3+
This query was originally published in the threat analytics report, *Adwind utilizes Java for cross-platform impact*.
4+
5+
Adwind is a remote access tool (RAT) that takes advantage of the cross-platform capabilities of the Java framework. It can check which operating system a target is running and adapt accordingly, allowing it to successfully compromise both Windows and macOS devices.
6+
7+
The query below checks for attempts to disguise Java class files (i.e., complied code with a *.class* extension). Although the behavior detected by this query is typical of attacks that use Adwind malware, unrelated attacks may use the same or similar defense evasion techniques.
8+
9+
See [Detecting a JAR attachment](../Initial%20access/jar-attachments.md) for an additional query that detects behavior associated with Adwind attacks.
10+
11+
## Query
12+
13+
```kusto
14+
union DeviceFileEvents, DeviceProcessEvents
15+
| where ProcessCommandLine has "attrib +h +s +r "
16+
and ProcessCommandLine contains ".class"
17+
```
18+
19+
## Category
20+
21+
This query can be used to detect the following attack techniques and tactics ([see MITRE ATT&CK framework](https://attack.mitre.org/)) or security configuration states.
22+
23+
| Technique, tactic, or state | Covered? (v=yes) | Notes |
24+
|-|-|-|
25+
| Initial access | | |
26+
| Execution | | |
27+
| Persistence | | |
28+
| Privilege escalation | | |
29+
| Defense evasion | v | |
30+
| Credential Access | | |
31+
| Discovery | | |
32+
| Lateral movement | | |
33+
| Collection | | |
34+
| Command and control | | |
35+
| Exfiltration | | |
36+
| Impact | | |
37+
| Vulnerability | | |
38+
| Misconfiguration | | |
39+
| Malware, component | | |
40+
41+
## Contributor info
42+
43+
**Contributor:** Microsoft Threat Protection team

Initial access/jar-attachments.md

Lines changed: 45 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,45 @@
1+
# Detecting a JAR attachment
2+
3+
This query was originally published in the threat analytics report, *Adwind utilizes Java for cross-platform impact*.
4+
5+
Adwind is a remote access tool (RAT) that takes advantage of the cross-platform capabilities of the Java framework. It can check which operating system a target is running and adapt accordingly, allowing it to successfully compromise both Windows and macOS devices.
6+
7+
The query below must be run in Microsoft 365 Defender. This query detects events where a single Java archive, or JAR file, was attached to an incoming email. Since Adwind is distributed as a JAR file, this can help detect the initial access stage of a Adwind attack. Note that, although the behavior detected by this query is typical of attacks that use Adwind malware, unrelated attacks may use the same or similar techniques. Also note that JAR attachments are not necessarily or even often malware, and that further research will be needed to determine if query results are associated with malicious behavior.
8+
9+
See [Hiding a Java class file](../Defense%20evasion/hiding-java-class-file.md) for an additional query that detects behavior associated with Adwind attacks.
10+
11+
## Query
12+
13+
```kusto
14+
let mailsHTML = EmailAttachmentInfo
15+
| where FileType startswith "Jar"
16+
| distinct NetworkMessageId;
17+
EmailEvents
18+
| where NetworkMessageId in (mailsHTML) and AttachmentCount > 0
19+
```
20+
21+
## Category
22+
23+
This query can be used to detect the following attack techniques and tactics ([see MITRE ATT&CK framework](https://attack.mitre.org/)) or security configuration states.
24+
25+
| Technique, tactic, or state | Covered? (v=yes) | Notes |
26+
|-|-|-|
27+
| Initial access | v | Microsoft 365 Defender exclusive |
28+
| Execution | | |
29+
| Persistence | | |
30+
| Privilege escalation | | |
31+
| Defense evasion | | |
32+
| Credential Access | | |
33+
| Discovery | | |
34+
| Lateral movement | | |
35+
| Collection | | |
36+
| Command and control | | |
37+
| Exfiltration | | |
38+
| Impact | | |
39+
| Vulnerability | | |
40+
| Misconfiguration | | |
41+
| Malware, component | | |
42+
43+
## Contributor info
44+
45+
**Contributor:** Microsoft Threat Protection team

0 commit comments

Comments
 (0)