YARA · SEKOIA.IO Community
SEKOIA_Infostealer_Win_Solarmarker_Powershell
Finds SolarMarker PowerShell script based on characteristic strings
- Autor
- Sekoia.io
- Fecha
- 2022-12-09
- Modificada
- 2024-12-19
- Puntuación / Calidad
- 75 / 80
Qué detecta esta regla
Finds SolarMarker PowerShell script based on characteristic strings
Familia de malware asociada: Solarmarker.
Define 9 patrones (7 de texto, 0 hex, 2 regex).
Resumen generado a partir de los metadatos y la condición de la regla.
Código de la regla
infostealer-win-solarmarker-powershell.yarDetection Rule License 1.1
rule SEKOIA_Infostealer_Win_Solarmarker_Powershell : FILE
{
meta:
= "Finds SolarMarker PowerShell script based on characteristic strings"
= "Sekoia.io"
= "a2fe7f09-7134-4054-ba40-5ea66785a26d"
= "2022-12-09"
= "2024-12-19"
= "https://github.com/SEKOIA-IO/Community"
= "https://github.com/SEKOIA-IO/Community/blob/a438a5901a211c2abdf75da9c93921ef187473d1/yara_rules/infostealer_win_solarmarker_powershell.yar#L1-L25"
= "https://github.com/SEKOIA-IO/Community/blob/a438a5901a211c2abdf75da9c93921ef187473d1/LICENSE.md"
= "32267cf7e03ed65da969aeeff5ef5d7291e47446ea11a4b391f085967e8aa67d"
= 75
= 80
= "FILE"
= "1.0"
= "TLP:CLEAR"
strings:
$fun = "function " ascii
$ps0 = "return -join (0..(10..30|Get-Random)|%{[char]((65..90)+(97..122)|Get-Random)})" ascii
$ps1 = /new-item -path \$[a-zA-Z0-9_]* -itemtype registrykey -force;/
$ps2 = /set-item -path \$[a-zA-Z0-9_]* -value \$[a-zA-Z0-9_]*;/
$str0 = "[IO.File]::WriteAllText($" ascii
$str1 = "CreateShortcut($env:appdata+" ascii
$str2 = "Registry::HKEY_CURRENT_USER\\Software\\Classes\\" ascii
$str3 = "New-Object System.Security.Cryptography.AesCryptoServiceProvider" ascii
$str4 = "[Convert]::FromBase64String([IO.File]::ReadAllText(" ascii
condition:
$fun at 0 and 1 of ( $ps* ) and 2 of ( $str* )
}
Cadenas (9 patrones)
| Identificador | Tipo | Valor | Modificadores |
|---|---|---|---|
| $fun | texto | "function " | ascii |
| $ps0 | texto | "return -join (0..(10..30|Get-Random)|%{[char]((65..90)+(97..122)|Get-Random)})" | ascii |
| $ps1 | regex | /new-item -path \$[a-zA-Z0-9_]* -itemtype registrykey -force;/ | |
| $ps2 | regex | /set-item -path \$[a-zA-Z0-9_]* -value \$[a-zA-Z0-9_]*;/ | |
| $str0 | texto | "[IO.File]::WriteAllText($" | ascii |
| $str1 | texto | "CreateShortcut($env:appdata+" | ascii |
| $str2 | texto | "Registry::HKEY_CURRENT_USER\\Software\\Classes\\" | ascii |
| $str3 | texto | "New-Object System.Security.Cryptography.AesCryptoServiceProvider" | ascii |
| $str4 | texto | "[Convert]::FromBase64String([IO.File]::ReadAllText(" | ascii |
Condición
$fun at 0 and 1 of ( $ps* ) and 2 of ( $str* )En palabras sencillas (Heurística)
- Deben coincidir al menos 1 patrones de ( $ps* ).
- Deben coincidir al menos 2 patrones de ( $str* ).
- El patrón $fun debe estar en el offset 0.
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: a2fe7f09-7134-4054-ba40-5ea66785a26d
Metadatos
| version | 1.0 |
|---|---|
| classification | TLP:CLEAR |
Etiquetas:FILE
Reglas relacionadas
- MalwareSEKOIA.IO Community· Sekoia.io· 2022-12-09
- MalwareEmbee Research· Matthew @ Embee_Research· 2023-12-28
- MalwareditekSHen detection· ditekSHen· 2020-11-06
- RUSSIANPANDA_Solarmarker_Loader_PS2EXESolo metadatosMalwareRussianPanda· RussianPanda· 2024-01-04
- RUSSIANPANDA_SolardropperSolo metadatosMalwareRussianPanda· RussianPanda· 2023-06-22
- RUSSIANPANDA_Solarmarker_LoaderSolo metadatosMalwareRussianPanda· RussianPanda· 2024-01-04
- RUSSIANPANDA_Solarmarker_First_Stage_PayloadSolo metadatosMalwareRussianPanda· RussianPanda· 2024-01-30
- Sospechoso / huntingEmbee Research· Matthew @ Embee_Research· 2023-09-10