BabukRansomwareV3

YARA-2021-0172 Critical general Active

YARA rule for Babuk Ransomware v3

BabukRansomwareV3.yar Valid Syntax
rule BabukRansomwareV3 {
    meta:
        description = "YARA rule for Babuk Ransomware v3"
        reference = "http://chuongdong.com/reverse%20engineering/2021/01/16/BabukRansomware-v3/"
        author = "@cPeterr"
        date = "2021-01-16"
        rule_version = "v3"
        malware_type = "ransomware"
        tlp = "white"
    strings:
        $lanstr1 = "-lanfirst"
        $lanstr2 = "-nolan"
        $lanstr3 = "shares"
        $str1 = "BABUK LOCKER"
        $str2 = "babukq4e2p4wu4iq.onion"
        $str3 = "How To Restore Your Files.txt" wide
        $str4 = "babuk_v3"
        $str5 = ".babyk" wide
    condition:
        all of ($str*) and all of ($lanstr*)
}

Rule Metadata

description
YARA rule for Babuk Ransomware v3
reference
http://chuongdong.com/reverse%20engineering/2021/01/16/BabukRansomware-v3/
author
@cPeterr
date
2021-01-16
rule_version
v3
malware_type
ransomware
tlp
white

String Definitions

{"name":"$lanstr1","value":"\"-lanfirst\""}
{"name":"$lanstr2","value":"\"-nolan\""}
{"name":"$lanstr3","value":"\"shares\""}
{"name":"$str1","value":"\"BABUK LOCKER\""}
{"name":"$str2","value":"\"babukq4e2p4wu4iq.onion\""}
{"name":"$str3","value":"\"How To Restore Your Files.txt\" wide"}
{"name":"$str4","value":"\"babuk_v3\""}
{"name":"$str5","value":"\".babyk\" wide"}

Threat Analysis

This YARA rule is designed to detect general threats.

Severity Level: Critical

The rule uses pattern matching to identify specific byte sequences, strings, or behavioral patterns associated with malicious activity.

Detection Capabilities

  • File-based detection for executables and documents
  • Memory scanning for running processes
  • Network traffic analysis support

Command Line Usage

# Scan a single file
yara BabukRansomwareV3.yar /path/to/suspicious/file

# Scan a directory recursively
yara -r BabukRansomwareV3.yar /path/to/directory/

# Scan with metadata output
yara -m BabukRansomwareV3.yar target_file

# Scan process memory (Linux)
yara BabukRansomwareV3.yar /proc/[pid]/exe

Integration Examples

Python (yara-python)

import yara
rules = yara.compile(filepath='BabukRansomwareV3.yar')
matches = rules.match('/path/to/file')

ClamAV Integration

clamscan --yara-rules=BabukRansomwareV3.yar /path/to/scan

Rule Information

YARA ID
YARA-2021-0172
Author
Created
August 19, 2025
Last Updated
August 19, 2025
Last Imported
Never

Threat Intelligence

Risk Level Critical
Category general
Detection Confidence Analysis Pending
False Positive Rate Not Available
Last Seen in Wild No Data

Export Options