Zum Inhalt springen

YARA · SEKOIA.IO Community

SEKOIA_Tool_Gsocket_Strings

Detects Gsocket based on strings

HacktoolSEKOIA.IO CommunityDetection Rule License 1.1Kompiliert mit YARA-X
Autor
Sekoia.io
Datum
2024-06-10
Geändert
2024-12-19
Score / Qualität
75 / 80

Was diese Regel erkennt

Detects Gsocket based on strings

Ziele: Windows-PE, Linux-ELF, macOS-Mach-O.

Sie definiert 6 Muster (6 Text, 0 Hex, 0 Regex).

Zusammenfassung aus den Metadaten und der Bedingung der Regel erzeugt.

Regelquelltext

tool-gsocket-strings.yarDetection Rule License 1.1
rule SEKOIA_Tool_Gsocket_Strings : FILE
{
	meta:
		description = "Detects Gsocket based on strings"
		author = "Sekoia.io"
		id = "55fb2f2b-1074-4b6d-9113-48eaeb0e1e27"
		date = "2024-06-10"
		modified = "2024-12-19"
		reference = "https://github.com/SEKOIA-IO/Community"
		source_url = "https://github.com/SEKOIA-IO/Community/blob/a438a5901a211c2abdf75da9c93921ef187473d1/yara_rules/tool_gsocket_strings.yar#L1-L28"
		license_url = "https://github.com/SEKOIA-IO/Community/blob/a438a5901a211c2abdf75da9c93921ef187473d1/LICENSE.md"
		logic_hash = "c54308293a9f64b571282eac9fba01e4671ba6b0cd45936fab92d4d9af904bbb"
		score = 75
		quality = 80
		tags = "FILE"
		version = "1.0"
		classification = "TLP:CLEAR"

	strings:
		$ = "proxy. It allows multiple gs-netcat clients to (securely) relay"
		$ = "GS-NETCAT(1)            General Commands Manual          GS-NETCAT(1)"
		$ = "-T      Use TOR. The gs-netcat tool will connect via TOR to the GSRN."
		$ = "-D      Daemon & Watchdog mode. Start gs-netcat as a background process"
		$ = "gs-netcat [-rlgvqwCTSDiu] [-s secret] [-k keyfile] [-L logfile] [-d IP]"
		$ = "The gs-netcat utility is a re-implementation of netcat."

	condition:
		( uint32be( 0 ) == 0x7f454c46 or uint16be( 0 ) == 0x4d5a or uint32be( 0 ) == 0xfeedface or uint32be( 0 ) == 0xcffaedfe or uint32be( 0 ) == 0xcafebabe ) and filesize > 2MB and filesize < 6MB and 2 of them
}

Strings (6 Muster)

BezeichnerTypWertModifikatoren
$Text"proxy. It allows multiple gs-netcat clients to (securely) relay"
$Text"GS-NETCAT(1) General Commands Manual GS-NETCAT(1)"
$Text"-T Use TOR. The gs-netcat tool will connect via TOR to the GSRN."
$Text"-D Daemon & Watchdog mode. Start gs-netcat as a background process"
$Text"gs-netcat [-rlgvqwCTSDiu] [-s secret] [-k keyfile] [-L logfile] [-d IP]"
$Text"The gs-netcat utility is a re-implementation of netcat."

Bedingung

( uint32be( 0 ) == 0x7f454c46 or uint16be( 0 ) == 0x4d5a or uint32be( 0 ) == 0xfeedface or uint32be( 0 ) == 0xcffaedfe or uint32be( 0 ) == 0xcafebabe ) and filesize > 2MB and filesize < 6MB and 2 of them

In Worten (Heuristik)

  • Die Datei muss mit „MZ“ beginnen — eine Windows-Programmdatei (PE).
  • Die Datei muss mit dem ELF-Header beginnen — eine Linux/Unix-Programmdatei.
  • Die Datei muss mit einer Mach-O-/Fat-Signatur beginnen — eine macOS-Programmdatei.
  • Die Datei muss kleiner als 6MB sein (eine günstige Grenze, die große Dateien ausschließt).
  • Die Datei muss größer als 2MB sein.
  • Mindestens 2 Muster aus der Regel müssen treffen.

Diese Regel im Browser testen

Legen Sie eine Datei ab, um sie mit dieser Regel und YARA-X als WebAssembly zu scannen. Nichts wird hochgeladen.

Datei hier ablegen oder klicken zum AuswählenLokal mit YARA-X gescannt. Dateien bis 200 MB.

Im Editor öffnen

Referenzen

Lizenz & Namensnennung

Autor: Sekoia.io

Quell-Repository: SEKOIA.IO Community @ a438a5901a

Lizenz: Detection Rule License 1.1 (Repository-Lizenz)

Originalregel

Gespiegelt über YARA Forge 20260927, das Regelnamen mit der Quelle präfixiert und normalisierte Meta-Felder ergänzt.

Regel-ID: 55fb2f2b-1074-4b6d-9113-48eaeb0e1e27

Metadaten

version1.0
classificationTLP:CLEAR

Tags:FILE