Skip to content

YARA · ditekSHen detection

DITEKSHEN_MALWARE_Win_Qnapcrypt

Detects QnapCrypt/Lockedv1/Cryptfile2 ransomware

MalwareQnapcryptditekSHen detectionBSD 2-Clause LicenseCompiles with YARA-X
Author
ditekSHen
Date
2020-11-06
Modified
2024-11-01
Score / Quality
75 / 73

What this rule detects

Detects QnapCrypt/Lockedv1/Cryptfile2 ransomware

Associated malware family: Qnapcrypt.

Targets: Windows PE.

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

Summary generated from the rule's metadata and condition.

Rule source

malware-win-qnapcrypt.yarBSD 2-Clause License
rule DITEKSHEN_MALWARE_Win_Qnapcrypt : FILE
{
	meta:
		description = "Detects QnapCrypt/Lockedv1/Cryptfile2 ransomware"
		author = "ditekSHen"
		id = "3ef5643a-f2af-5d62-8927-e46679e069c2"
		date = "2020-11-06"
		modified = "2024-11-01"
		reference = "https://github.com/ditekshen/detection"
		source_url = "https://github.com/ditekshen/detection/blob/e76c93dcdedff04076380ffc60ea54e45b313635/yara/malware.yar#L3579-L3607"
		license_url = "https://github.com/ditekshen/detection/blob/e76c93dcdedff04076380ffc60ea54e45b313635/LICENSE.txt"
		logic_hash = "68fc3f0503d82295ffa5bfb49bda8b790142913217775a2812e3965a6c9a1fe1"
		score = 75
		quality = 73
		tags = "FILE"

	strings:
		$go = "Go build ID:" ascii
		$s1 = "Encrypting %s..." ascii
		$s2 = "\\Start Menu\\Programs\\StartUp\\READMEV" ascii
		$s3 = "main.deleteRecycleBin" ascii
		$s4 = "main.encryptFiles" ascii
		$s5 = "main.antiVirtualBox" ascii
		$s6 = "main.antiVmware" ascii
		$s7 = "main.deleteShadows" ascii
		$s8 = "main.delUAC" ascii
		$s9 = "main.KillProcess" ascii
		$s10 = "main.delExploit" ascii
		$s11 = "main.encrypt" ascii
		$s12 = "main.ClearLogDownload" ascii
		$s13 = "main.ClearLog" ascii
		$s14 = "main.EndEncrypt" ascii
		$s15 = "main.RunFuckLogAndSoft" ascii
		$s16 = "main.ClearUsercache" ascii
		$s17 = "main.FirstDuty" ascii
		$s18 = ".lockedv1" ascii
		$s19 = "WSAStartup\\clear.bat\\ngrok.exe\\video.mp4" ascii
		$s20 = "net stop " ascii

	condition:
		uint16( 0 ) == 0x5a4d and $go and 6 of ( $s* )
}

Strings (21 patterns)

IdentifierTypeValueModifiers
$gotext"Go build ID:"ascii
$s1text"Encrypting %s..."ascii
$s2text"\\Start Menu\\Programs\\StartUp\\READMEV"ascii
$s3text"main.deleteRecycleBin"ascii
$s4text"main.encryptFiles"ascii
$s5text"main.antiVirtualBox"ascii
$s6text"main.antiVmware"ascii
$s7text"main.deleteShadows"ascii
$s8text"main.delUAC"ascii
$s9text"main.KillProcess"ascii
$s10text"main.delExploit"ascii
$s11text"main.encrypt"ascii
$s12text"main.ClearLogDownload"ascii
$s13text"main.ClearLog"ascii
$s14text"main.EndEncrypt"ascii
$s15text"main.RunFuckLogAndSoft"ascii
$s16text"main.ClearUsercache"ascii
$s17text"main.FirstDuty"ascii
$s18text".lockedv1"ascii
$s19text"WSAStartup\\clear.bat\\ngrok.exe\\video.mp4"ascii
$s20text"net stop "ascii

Condition

uint16( 0 ) == 0x5a4d and $go and 6 of ( $s* )

In plain words (Heuristic)

  • The file must start with “MZ” — a Windows executable (PE).
  • At least 6 patterns in ( $s* ) must match.
  • Pattern $go must be present.

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: ditekSHen

Source repository: ditekSHen detection @ e76c93dcde

Licence: BSD 2-Clause License (repository licence)

Copyright notice: Copyright 2021 by ditekSHen (https://github.com/ditekshen/detection).

Original rule

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

Rule id: 3ef5643a-f2af-5d62-8927-e46679e069c2

Tags:FILE

More Qnapcrypt rules