Skip to content

YARA · SEKOIA.IO Community

SEKOIA_Tool_Win_Sharpshares

Finds sharpshares EXE based on strings

Hack toolSEKOIA.IO CommunityDetection Rule License 1.1Compiles with YARA-X
Author
Sekoia.io
Date
2024-06-10
Modified
2024-12-19
Score / Quality
75 / 80

What this rule detects

Finds sharpshares EXE based on strings

Targets: Windows PE.

It defines 11 patterns (11 text, 0 hex, 0 regex).

Summary generated from the rule's metadata and condition.

Rule source

tool-win-sharpshares.yarDetection Rule License 1.1
rule SEKOIA_Tool_Win_Sharpshares : FILE
{
	meta:
		description = "Finds sharpshares EXE based on strings"
		author = "Sekoia.io"
		id = "ef90d573-12f8-4216-9a9e-96e7d1e841d0"
		date = "2024-06-10"
		modified = "2024-12-19"
		reference = "https://github.com/mitchmoser/SharpShares/releases"
		source_url = "https://github.com/SEKOIA-IO/Community/blob/a438a5901a211c2abdf75da9c93921ef187473d1/yara_rules/tool_win_sharpshares.yar#L1-L26"
		license_url = "https://github.com/SEKOIA-IO/Community/blob/a438a5901a211c2abdf75da9c93921ef187473d1/LICENSE.md"
		logic_hash = "6aa96d7c24638451bde98497cc7c844c87612d81cc7826113729c80bd5180442"
		score = 75
		quality = 80
		tags = "FILE"
		version = "1.0"
		classification = "TLP:CLEAR"

	strings:
		$str01 = "<GetAllShares>b__0" ascii
		$str02 = "<SearchLDAP>b__0_0" ascii
		$str03 = "get_AccessControlType" ascii
		$str04 = "get_IdentityReference" ascii
		$str05 = "get_PropertiesToLoad" ascii
		$str06 = "SharpShares\\obj\\Release\\SharpShares.pdb" ascii
		$str07 = "/filter:SYSVOL,NETLOGON,IPC$,PRINT$" wide
		$str08 = "/threads:50 /ldap:servers" wide
		$str09 = "SharpShares.exe" ascii wide
		$str10 = "[+] LDAP Search Results:" wide
		$str11 = "[+] Finished Enumerating Shares" wide

	condition:
		uint16( 0 ) == 0x5A4D and 6 of them
}

Strings (11 patterns)

IdentifierTypeValueModifiers
$str01text"<GetAllShares>b__0"ascii
$str02text"<SearchLDAP>b__0_0"ascii
$str03text"get_AccessControlType"ascii
$str04text"get_IdentityReference"ascii
$str05text"get_PropertiesToLoad"ascii
$str06text"SharpShares\\obj\\Release\\SharpShares.pdb"ascii
$str07text"/filter:SYSVOL,NETLOGON,IPC$,PRINT$"wide
$str08text"/threads:50 /ldap:servers"wide
$str09text"SharpShares.exe"ascii wide
$str10text"[+] LDAP Search Results:"wide
$str11text"[+] Finished Enumerating Shares"wide

Condition

uint16( 0 ) == 0x5A4D and 6 of them

In plain words (Heuristic)

  • The file must start with “MZ” — a Windows executable (PE).
  • At least 6 patterns in the rule must match.

Test this rule in your browser

Drop a file to scan it with this rule using YARA-X compiled to WebAssembly. Nothing is uploaded.

Drop a file here or click to chooseScanned locally with YARA-X. Files up to 200 MB.

Open in editor

References

Licence & attribution

Author: Sekoia.io

Source repository: SEKOIA.IO Community @ a438a5901a

Licence: Detection Rule License 1.1 (repository licence)

Original rule

Mirrored via YARA Forge 20260927, which prefixes rule names with the source and adds normalised meta fields.

Rule id: ef90d573-12f8-4216-9a9e-96e7d1e841d0

Metadata

version1.0
classificationTLP:CLEAR

Tags:FILE