Matsnu
- Type
- Backdoor
- Capabilities
- PersistencePost exploitationDefense evasionReconnaissanceProcess injection
- Platforms
- Windows
Matsnu is a Windows x86 backdoor that establishes command-and-control access following infection. It uses both hard-coded domains and a wordlist-based domain generation algorithm to locate command-and-control infrastructure, generating candidate domains for the current and preceding days. Client data is protected with RSA encryption and Base64 encoding over HTTP, while server responses use AES and an additional XOR-based transformation.
Matsnu profiles infected hosts by collecting user, host, operating-system, language, processor, graphics, storage, antivirus, and virtualization-related information. It supports commands to pause activity, retrieve configuration and process or DLL listings, execute supplied payloads, and download, install, or upgrade additional binaries. The malware persists by copying itself to user-writable locations and configuring Windows Run or RunOnce autostart entries. It also uses mutexes to track execution and infection state.
Matsnu employs layered packing, on-demand string decryption, anti-debugging, and anti-disassembly techniques. It can transfer execution into a suspended child process after modifying its memory and thread context. Matsnu command-and-control communications were supported by the Avalanche fast-flux criminal infrastructure, which was disrupted in 2016.
Techniques & procedures
29 distinct techniques documented for this family, organized by ATT&CK tactic.
Initial Access
4 techniques
Initial Access
Browsing Website : - Compromised website : one website has been compromised either using a vulnerability (usually on outdated CMS) or using stolen credentials from owner, modified to redirect visitors to the infection.
Chat/mail - link to compromised website or exploit kit - binary as attachement, or document with link to the exploit kit
La distribution de « Matsnu » peut notamment s’appuyer sur des campagnes de spam et de phishing, au cours desquelles le malware peut être diffusé sous la forme de pièces jointes malveillantes.
Chat/mail - link to compromised website or exploit kit
Execution
2 techniques
Execution
sa fonction principale consiste à établir une capacité de contrôle à distance sur un système compromis afin de permettre à l’opérateur de réaliser différentes actions malveillantes, notamment l’exécution de commandes
EXECUTE This command is responsible for executing the data sent by the C&C server.
Persistence
1 technique
Persistence
mécanismes de persistance, notamment par la modification du registre Windows afin de provoquer l’exécution automatique du malware au démarrage du système
Privilege Escalation
2 techniques
Privilege Escalation
Allocate two memory chunks with sizes 0x50 and 0x13e00 bytes in the newly created process. Copy the code in the newly allocated region of memory... Set the newly created process thread context (EIP register is set to the address of the first payload) and resume thread execution.
mécanismes de persistance, notamment par la modification du registre Windows afin de provoquer l’exécution automatique du malware au démarrage du système
Stealth
7 techniques
Stealth
The malware is packed multiple times using manual and UPX encryption. All strings are encrypted and encoded in the process memory. Decryption takes place only when needed by the malware.
Each packet sent by the client to the C&C server is encrypted using an RSA public key and stored in memory. After encryption, the data is base64 encoded and sent as an HTTP packet content to the server.
Select a new process name that will start in a suspended state. The malware has a predefined base64-encoded and encrypted list of processes. The infected process name is chosen using a random generator.
Allocate two memory chunks with sizes 0x50 and 0x13e00 bytes in the newly created process. Copy the code in the newly allocated region of memory... Set the newly created process thread context (EIP register is set to the address of the first payload) and resume thread execution.
The infected process tries to delete the original malware file via the “DeleteFile” and “MoveFileEx” (which uses “MOVEFILE_DELAY_UNTIL_REBOOT” flag) functions.
Information about the virtual environment use of registry keys: “HARDWARE\ACPI\DSDT\PTLTD_” “HARDWARE\ACPI\DSDT\VBOX__” “HARDWARE\ACPI\DSDT\AMIBI”
To prevent process debugging, the malware uses the following technique: An SEH handler is set on the stack. Next, an INT1 interrupt is performed...
Defense Impairment
1 technique
Defense Impairment
Certaines variantes peuvent également modifier ou désactiver des fonctionnalités de sécurité et des outils système, tels que le Gestionnaire des tâches ou l’Éditeur du Registre
Credential Access
1 technique
Credential Access
Millions of private and business computer systems were also infected with malware, enabling the criminals operating the network to harvest bank and e-mail passwords.
Discovery
5 techniques
Discovery
PROCLIST Specifies names of processes. If at least one specified process is present in the system, information is sent to the C&C server with a list of the processes present.
Lors de son exécution, « Matsnu » effectue une phase initiale de reconnaissance de l’environnement compromis
DLLLIST Specifies names of files. If at least one specified file is present in the system, information is sent to the C&C server with a list of the files present.
Information about the virtual environment use of registry keys: “HARDWARE\ACPI\DSDT\PTLTD_” “HARDWARE\ACPI\DSDT\VBOX__” “HARDWARE\ACPI\DSDT\AMIBI”
To prevent process debugging, the malware uses the following technique: An SEH handler is set on the stack. Next, an INT1 interrupt is performed...
Collection
1 technique
Collection
les données identifiées sont généralement agrégées et préparées pour l’exfiltration
Command and Control
6 techniques
Command and Control
The Matsnu malware is an x86 infector that acts as a backdoor after it infiltrates a computer system. The malware uses DGA to communicate with the C&C server.
The following URL is used: (http|ftp|htpps)://${domain-name}/${resource}${RESOURCE_QUERY_PARAM}
Avalanche used fast-flux DNS, a technique to hide the criminal servers, behind a constantly changing network of compromised systems acting as proxies.
le téléchargement et l’exécution de charges supplémentaires
Avalanche used fast-flux DNS, a technique to hide the criminal servers, behind a constantly changing network of compromised systems acting as proxies.
To generate domains, the malware uses two predefined dictionaries, a few constants and variables, and the number of days since the epoch. Domains are generated for the current day as well as the previous two days.
Exfiltration
1 technique
Exfiltration
puis transmises vers une infrastructure C2 contrôlée par l’opérateur du malware
Impact
2 techniques
Impact
supprimer certains mécanismes de restauration afin de compliquer les opérations de remédiation
To submit an upgrade, the malware attempts to reboot the operating system with this command: shutdown.exe -r -f -t 0
Observables
279 indicators attributed across vendor reports, sandbox runs, and researcher write-ups. Values are masked here and available in full in Mallory.
Recent activity
11 sources tracked across advisories, community write-ups, and news. New activity surfaces here as Mallory finds it.