YARA · SEKOIA.IO Community
SEKOIA_Tool_Gsocket_Strings
Detects Gsocket based on strings
- Autor
- Sekoia.io
- Fecha
- 2024-06-10
- Modificada
- 2024-12-19
- Puntuación / Calidad
- 75 / 80
Qué detecta esta regla
Detects Gsocket based on strings
Objetivos: PE de Windows, ELF de Linux, Mach-O de macOS.
Define 6 patrones (6 de texto, 0 hex, 0 regex).
Resumen generado a partir de los metadatos y la condición de la regla.
Código de la regla
tool-gsocket-strings.yarDetection Rule License 1.1
rule SEKOIA_Tool_Gsocket_Strings : FILE
{
meta:
= "Detects Gsocket based on strings"
= "Sekoia.io"
= "55fb2f2b-1074-4b6d-9113-48eaeb0e1e27"
= "2024-06-10"
= "2024-12-19"
= "https://github.com/SEKOIA-IO/Community"
= "https://github.com/SEKOIA-IO/Community/blob/a438a5901a211c2abdf75da9c93921ef187473d1/yara_rules/tool_gsocket_strings.yar#L1-L28"
= "https://github.com/SEKOIA-IO/Community/blob/a438a5901a211c2abdf75da9c93921ef187473d1/LICENSE.md"
= "c54308293a9f64b571282eac9fba01e4671ba6b0cd45936fab92d4d9af904bbb"
= 75
= 80
= "FILE"
= "1.0"
= "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
}
Cadenas (6 patrones)
| Identificador | Tipo | Valor | Modificadores |
|---|---|---|---|
| $ | texto | "proxy. It allows multiple gs-netcat clients to (securely) relay" | |
| $ | texto | "GS-NETCAT(1) General Commands Manual GS-NETCAT(1)" | |
| $ | texto | "-T Use TOR. The gs-netcat tool will connect via TOR to the GSRN." | |
| $ | texto | "-D Daemon & Watchdog mode. Start gs-netcat as a background process" | |
| $ | texto | "gs-netcat [-rlgvqwCTSDiu] [-s secret] [-k keyfile] [-L logfile] [-d IP]" | |
| $ | texto | "The gs-netcat utility is a re-implementation of netcat." |
Condición
( 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 themEn palabras sencillas (Heurística)
- El archivo debe empezar por «MZ»: un ejecutable de Windows (PE).
- El archivo debe empezar por la cabecera ELF: un ejecutable de Linux/Unix.
- El archivo debe empezar por una firma Mach-O / fat: un ejecutable de macOS.
- El archivo debe ocupar menos de 6MB (un límite barato que descarta archivos grandes).
- El archivo debe ocupar más de 2MB.
- Deben coincidir al menos 2 patrones de la regla.
Prueba esta regla en tu navegador
Arrastra un archivo para escanearlo con esta regla usando YARA-X compilado a WebAssembly. No se sube nada.
Arrastra un archivo aquí o haz clic para elegirSe escanea en local con YARA-X. Archivos de hasta 200 MB.
Referencias
Licencia y atribución
Autor: Sekoia.io
Repositorio de origen: SEKOIA.IO Community @ a438a5901a
Licencia: Detection Rule License 1.1 (licencia del repositorio)
Obtenida a través de YARA Forge 20260927, que añade a los nombres el prefijo de la fuente y campos meta normalizados.
Id de la regla: 55fb2f2b-1074-4b6d-9113-48eaeb0e1e27
Metadatos
| version | 1.0 |
|---|---|
| classification | TLP:CLEAR |
Etiquetas:FILE
Reglas relacionadas
- Herramienta ofensivaSEKOIA.IO Community· Sekoia.io· 2024-09-06
- Herramienta ofensivaSEKOIA.IO Community· Sekoia.io· 2024-02-29
- Herramienta ofensivaSEKOIA.IO Community· Sekoia.io· 2023-12-05
- Herramienta ofensivaSEKOIA.IO Community· Sekoia.io· 2023-11-15
- Herramienta ofensivaSEKOIA.IO Community· Sekoia.io· 2023-08-23
- Herramienta ofensivaSEKOIA.IO Community· Sekoia.io· 2022-02-08
- Herramienta ofensivaSEKOIA.IO Community· Sekoia.io· 2022-07-22
- Herramienta ofensivaSEKOIA.IO Community· Sekoia.io· 2022-09-09