Saturday, April 5, 2025
HomeCyber Security NewsLummaC2 Stealer Leverages Customized Control Flow Indirection For Execution

LummaC2 Stealer Leverages Customized Control Flow Indirection For Execution

Published on

SIEM as a Service

Follow Us on Google News

The LummaC2 obfuscator employs a novel control flow protection scheme designed specifically for its stealer component, which is part of a broader set of transformations, making it difficult for analysts to reverse engineer the binary. 

It introduces obfuscated code that is mixed with the original compiler-generated code, requiring a specialized deobfuscator for analysis.

The obfuscator’s authors appear to have a deep understanding of the LummaC2 stealer, as certain protections are tailored to specific components of the malware.

Dispatcher blocks overview

Dispatcher blocks a type of obfuscation technique used by malware, which breaks a function’s original control flow by inserting instructions that calculate jump destinations dynamically.

Free Webinar on How to Protect Small Businesses Against Advanced Cyberthreats -> Free Registration

The analysis identifies three main dispatcher block layouts: register-based (most common), memory-based, and mixed-order, where register-based layouts use registers for calculations and end with a jump to a register value. 

Memory-based layouts utilize both registers and stack values, and mixed-order layouts combine elements of both and can intersperse dispatcher instructions with original instructions, making deobfuscation harder. 

Register-based instruction dispatcher

The obfuscator uses conditional dispatchers to protect sensitive code logic, which are categorized into standard, loop, and syscall types, where standard dispatchers handle general conditional jumps, while loop dispatchers control loop execution. 

Syscall dispatchers evaluate NTSTATUS codes to determine Syscall success, and the obfuscator creates a table of branch targets indexed by the condition’s result. 

By evaluating the condition code and indexing the table, the obfuscator executes the appropriate branch, which effectively hides sensitive logic from analysis.

 A update-block loop

A method for deobfuscating a function’s control flow, as symbolic execution with Triton is used to distinguish between the original instructions and those injected by the obfuscator (dispatcher instructions). 

Backward slicing is performed on the destination register of an indirect jump to identify instructions influencing the final jump target. 

By analyzing the symbolic expressions generated during processing, dispatcher instructions responsible for the manipulation are isolated and the original function flow is pinpointed, which is effective regardless of dispatcher instruction placement.

ASTs of the destination register after the indirect jump instruction is processed

The deobfuscation process begins by recovering the original instructions and control flow using a depth-first search algorithm.

Conditional jumps are handled by assuming the condition is met and exploring the corresponding path, while alternative paths are stored for later exploration. 

The deobfuscated function is then rebuilt by overwriting the original instructions and replacing indirect jumps with direct ones or conditional jump pairs.

Finally, the offsets of memory-referencing instructions are adjusted to reflect their new locations, which effectively removes obfuscation and restores the original function’s semantics.

 Decompiler view of the subroutine at address 0x41EE50 after deobfuscation

Mandiant researchers developed a deobfuscation tool for LummaC2 by employing backward slicing and symbolic execution, which identify the original instructions obscured by the obfuscator’s indirect jumps, successfully remove dispatcher blocks, and reveal the program’s true control flow. 

Deobfuscated functions can then be recovered and decompiled using IDA Pro, enabling analysts to understand LummaC2’s functionalities, which highlights the effectiveness of backward slicing for binary analysis beyond the LummaC2 case study.

Analyse Any Suspicious Links Using ANY.RUN’s New Safe Browsing Tool: Try It for Free

Varshini
Varshini
Varshini is a Cyber Security expert in Threat Analysis, Vulnerability Assessment, and Research. Passionate about staying ahead of emerging Threats and Technologies.

Latest articles

Ivanti Fully Patched Connect Secure RCE Vulnerability That Actively Exploited in the Wild

Ivanti has issued an urgent security advisory for CVE-2025-22457, a critical vulnerability impacting Ivanti...

Beware! Weaponized Job Recruitment Emails Spreading BeaverTail and Tropidoor Malware

A concerning malware campaign was disclosed by the AhnLab Security Intelligence Center (ASEC), revealing...

EncryptHub Ransomware Uncovered Through ChatGPT Use and OPSEC Failures

EncryptHub, a rapidly evolving cybercriminal entity, has come under intense scrutiny following revelations of...

PoisonSeed Targets CRM and Bulk Email Providers in New Supply Chain Phishing Attack

A sophisticated phishing campaign, dubbed "PoisonSeed," has been identified targeting customer relationship management (CRM)...

Supply Chain Attack Prevention

Free Webinar - Supply Chain Attack Prevention

Recent attacks like Polyfill[.]io show how compromised third-party components become backdoors for hackers. PCI DSS 4.0’s Requirement 6.4.3 mandates stricter browser script controls, while Requirement 12.8 focuses on securing third-party providers.

Join Vivekanand Gopalan (VP of Products – Indusface) and Phani Deepak Akella (VP of Marketing – Indusface) as they break down these compliance requirements and share strategies to protect your applications from supply chain attacks.

Discussion points

Meeting PCI DSS 4.0 mandates.
Blocking malicious components and unauthorized JavaScript execution.
PIdentifying attack surfaces from third-party dependencies.
Preventing man-in-the-browser attacks with proactive monitoring.

More like this

Ivanti Fully Patched Connect Secure RCE Vulnerability That Actively Exploited in the Wild

Ivanti has issued an urgent security advisory for CVE-2025-22457, a critical vulnerability impacting Ivanti...

Beware! Weaponized Job Recruitment Emails Spreading BeaverTail and Tropidoor Malware

A concerning malware campaign was disclosed by the AhnLab Security Intelligence Center (ASEC), revealing...

EncryptHub Ransomware Uncovered Through ChatGPT Use and OPSEC Failures

EncryptHub, a rapidly evolving cybercriminal entity, has come under intense scrutiny following revelations of...