Bazar

Bazar is a downloader and backdoor that has been used since at least April 2020, with infections primarily against professional services, healthcare, manufacturing, IT, logistics and travel companies across the US and Europe. Bazar reportedly has ties to TrickBot campaigns and can be used to deploy additional malware, including ransomware, and to steal sensitive data.[1]

ID: S0534
Associated Software: KEGTAP, Team9, Bazaloader
Type: MALWARE
Platforms: Windows
Contributors: Cybereason Nocturnus, @nocturnus
Version: 2.0
Created: 18 November 2020
Last Modified: 04 December 2023

Associated Software Descriptions

Name Description
KEGTAP

[2][3]

Team9

[1][4]

Bazaloader

[5]

Techniques Used

Domain ID Name Use
Enterprise T1087 .001 Account Discovery: Local Account

Bazar can identify administrator accounts on an infected host.[4]

.002 Account Discovery: Domain Account

Bazar has the ability to identify domain administrator accounts.[4][6]

Enterprise T1071 .001 Application Layer Protocol: Web Protocols

Bazar can use HTTP and HTTPS over ports 80 and 443 in C2 communications.[1][4][7]

Enterprise T1197 BITS Jobs

Bazar has been downloaded via Windows BITS functionality.[4]

Enterprise T1547 .001 Boot or Logon Autostart Execution: Registry Run Keys / Startup Folder

Bazar can create or add files to Registry Run Keys to establish persistence.[1][4]

.004 Boot or Logon Autostart Execution: Winlogon Helper DLL

Bazar can use Winlogon Helper DLL to establish persistence.[8]

.009 Boot or Logon Autostart Execution: Shortcut Modification

Bazar can establish persistence by writing shortcuts to the Windows Startup folder.[1][4]

Enterprise T1059 .001 Command and Scripting Interpreter: PowerShell

Bazar can execute a PowerShell script received from C2.[4][3]

.003 Command and Scripting Interpreter: Windows Command Shell

Bazar can launch cmd.exe to perform reconnaissance commands.[1][8]

Enterprise T1005 Data from Local System

Bazar can retrieve information from the infected machine.[1]

Enterprise T1140 Deobfuscate/Decode Files or Information

Bazar can decrypt downloaded payloads. Bazar also resolves strings and other artifacts at runtime.[1][4]

Enterprise T1482 Domain Trust Discovery

Bazar can use Nltest tools to obtain information about the domain.[1][4]

Enterprise T1568 .002 Dynamic Resolution: Domain Generation Algorithms

Bazar can implement DGA using the current date as a seed variable.[1]

Enterprise T1573 .001 Encrypted Channel: Symmetric Cryptography

Bazar can send C2 communications with XOR encryption.[4]

.002 Encrypted Channel: Asymmetric Cryptography

Bazar can use TLS in C2 communications.[8]

Enterprise T1008 Fallback Channels

Bazar has the ability to use an alternative C2 server if the primary server fails.[4]

Enterprise T1083 File and Directory Discovery

Bazar can enumerate the victim's desktop.[1][4]

Enterprise T1562 .001 Impair Defenses: Disable or Modify Tools

Bazar has manually loaded ntdll from disk in order to identity and remove API hooks set by security products.[4]

Enterprise T1070 .004 Indicator Removal: File Deletion

Bazar can delete its loader using a batch file in the Windows temporary folder.[4]

.009 Indicator Removal: Clear Persistence

Bazar's loader can delete scheduled tasks created by a previous instance of the malware.[4]

Enterprise T1105 Ingress Tool Transfer

Bazar can download and deploy additional payloads, including ransomware and post-exploitation frameworks such as Cobalt Strike.[1][8][4][3]

Enterprise T1036 .004 Masquerading: Masquerade Task or Service

Bazar can create a task named to appear benign.[1]

.005 Masquerading: Match Legitimate Name or Location

The Bazar loader has named malicious shortcuts "adobe" and mimicked communications software.[1][4][3]

.007 Masquerading: Double File Extension

The Bazar loader has used dual-extension executable files such as PreviewReport.DOC.exe.[1]

Enterprise T1104 Multi-Stage Channels

The Bazar loader is used to download and execute the Bazar backdoor.[1][8]

Enterprise T1106 Native API

Bazar can use various APIs to allocate memory and facilitate code execution/injection.[1]

Enterprise T1135 Network Share Discovery

Bazar can enumerate shared drives on the domain.[4]

Enterprise T1027 .002 Obfuscated Files or Information: Software Packing

Bazar has a variant with a packed payload.[1][8]

.007 Obfuscated Files or Information: Dynamic API Resolution

Bazar can hash then resolve API calls at runtime.[1][4]

.013 Obfuscated Files or Information: Encrypted/Encoded File

Bazar has used XOR, RSA2, and RC4 encrypted files.[1][4][3]

Enterprise T1566 .002 Phishing: Spearphishing Link

Bazar has been spread via emails with embedded malicious links.[1][8][3]

Enterprise T1057 Process Discovery

Bazar can identity the current process on a compromised host.[1]

Enterprise T1055 Process Injection

Bazar can inject code through calling VirtualAllocExNuma.[1]

.012 Process Hollowing

Bazar can inject into a target process including Svchost, Explorer, and cmd using process hollowing.[1][4]

.013 Process Doppelgänging

Bazar can inject into a target process using process doppelgänging.[1][4]

Enterprise T1012 Query Registry

Bazar can query Windows\CurrentVersion\Uninstall for installed applications.[1][4]

Enterprise T1018 Remote System Discovery

Bazar can enumerate remote systems using Net View.[1]

Enterprise T1053 .005 Scheduled Task/Job: Scheduled Task

Bazar can create a scheduled task for persistence.[1][4]

Enterprise T1518 Software Discovery

Bazar can query the Registry for installed applications.[1]

.001 Security Software Discovery

Bazar can identify the installed antivirus engine.[1]

Enterprise T1553 .002 Subvert Trust Controls: Code Signing

Bazar has been signed with fake certificates including those appearing to be from VB CORPORATE PTY. LTD.[1]

Enterprise T1082 System Information Discovery

Bazar can fingerprint architecture, computer name, and OS version on the compromised host. Bazar can also check if the Russian language is installed on the infected machine and terminate if it is found.[1][4]

Enterprise T1614 .001 System Location Discovery: System Language Discovery

Bazar can perform a check to ensure that the operating system's keyboard and language settings are not set to Russian.[4]

Enterprise T1016 System Network Configuration Discovery

Bazar can collect the IP address and NetBIOS name of an infected machine.[1]

Enterprise T1033 System Owner/User Discovery

Bazar can identify the username of the infected user.[4]

Enterprise T1124 System Time Discovery

Bazar can collect the time on the compromised host.[1][4]

Enterprise T1204 .001 User Execution: Malicious Link

Bazar can gain execution after a user clicks on a malicious link to decoy landing pages hosted on Google Docs.[1][8][3]

Enterprise T1497 Virtualization/Sandbox Evasion

Bazar can attempt to overload sandbox analysis by sending 1550 calls to printf.[1]

.003 Time Based Evasion

Bazar can use a timer to delay execution of core functionality.[4]

Enterprise T1102 Web Service

Bazar downloads have been hosted on Google Docs.[1][8]

Enterprise T1047 Windows Management Instrumentation

Bazar can execute a WMI query to gather information about the installed antivirus engine.[1][6]

Groups That Use This Software

Campaigns

ID Name Description
C0015 C0015

[7]

References