BADAUDIO

Chinese Hackers Use “BadAudio” Malware to Break Into Thousands of Websites

BADAUDIO has emerged as one of the most active and dangerous malware tools tied to Chinese cyber espionage, powering a long running operation that uses compromised websites, poisoned supply chains, and realistic browser update scams to infect Windows users around the world. The campaign began in late 2022 with scattered website compromises but has since escalated into a coordinated ecosystem capable of reaching thousands of sites, infiltrating a major digital marketing provider in Taiwan, and delivering hidden malware to victims through trusted channels. The persistence, scale, and sophistication behind this operation place BADAUDIO among the most significant espionage threats uncovered in recent years.

Researchers at the Google Threat Intelligence Group have tracked the campaign for nearly three years and found that the threat actor, believed to be China linked, has continuously evolved its tactics. The group shifted from basic JavaScript injection and phishing into a structured, multi vector operation that blends supply chain compromise, environment fingerprinting, social engineering, and stealthy in memory malware execution. As the campaign expanded, the attackers gained access to a Taiwan based marketing provider whose JavaScript libraries were embedded across more than one thousand websites, giving them automated and long term access to a wide audience.

BADAUDIO overview
BADAUDIO campaign overview (Source: Google)

The initial infection vector relied on malicious JavaScript injected into compromised websites. These scripts filtered users based on operating system and browser type, selecting only Windows systems while avoiding macOS, iOS, Android, and older browsers. When a valid target loaded the page, the JavaScript retrieved the FingerprintJS library to generate a detailed profile of the visitor’s device. This fingerprint was sent to an attacker controlled server, which decided whether to proceed with the attack. If approved, the visitor was served a fake Chrome update prompt that looked identical to a real browser notification. Many users could not distinguish the fraudulent prompt from a legitimate update, especially since modern browsers update silently and often without user interaction.

Victims who clicked the prompt downloaded the BADAUDIO loader. BADAUDIO is a C++ based first stage downloader designed for stealth and flexibility. It collects reconnaissance data such as machine name, username, and CPU architecture, encrypts it with a hard coded AES key, and embeds the encrypted block inside an HTTP cookie. This makes its outbound traffic appear like ordinary browsing. The server responds with an AES encrypted payload that BADAUDIO decrypts and executes directly in memory. One confirmed secondary payload was a Cobalt Strike Beacon variant containing a unique watermark linked to previous campaigns by the same actor. Because BADAUDIO operates entirely in memory, it bypasses many file based detection tools.

The malware is frequently delivered through DLL sideloading, a technique that places a malicious DLL next to a legitimate executable so Windows loads it first. This lets the malware disguise itself behind trusted software. Internally, BADAUDIO uses heavy control flow flattening, breaking normal program flow into many small routines that route through a dispatcher. This structure slows analysts and confuses automated detection systems, strengthening the malware’s ability to avoid scrutiny.

The most impactful part of the operation came when the attackers infiltrated a digital marketing provider in Taiwan whose JavaScript resources were embedded across more than one thousand websites. Once the provider’s scripts were compromised, every client site loading those scripts automatically served the attacker’s modified code. This type of supply chain attack is difficult to detect because website owners often assume their marketing and analytics scripts are safe. In later stages of the campaign, the attackers hid malicious code inside JSON files, which the marketing company’s JavaScript automatically loaded. Because JSON does not usually contain executable code, this technique helped the malware remain unnoticed even under manual review.

The attackers also used targeted phishing campaigns to complement their broader website based distribution. Some phishing emails pretended to be from animal rescue groups and encouraged recipients to download documents from attacker domains. Other campaigns delivered encrypted archives through Google Drive or OneDrive, taking advantage of the trust many users place in cloud storage platforms. Pixel tracking images inside the emails alerted the attackers when a target opened a message, allowing them to prioritize victims who appeared more likely to engage.

The BADAUDIO operation stands out because it merges multiple techniques into a single, long lasting system. It uses malicious JavaScript, supply chain infiltration, fake browser updates, phishing, cloud hosted payloads, DLL sideloading, and in memory execution. The ability to compromise trusted digital pathways such as third party scripts and embedded marketing libraries gives the attackers reach far beyond traditional phishing or direct malware campaigns. The focus on Taiwan aligns with broader intelligence activities attributed to Chinese espionage, but the infrastructure and methods can be adapted for targets in any region.

Organizations that include third party JavaScript libraries, embedded analytics, cloud hosted assets, or outsourced development in their infrastructure face higher risk from operations like this. Many of these components run silently in the background and are rarely audited, creating blind spots attackers can exploit for long periods. The BADAUDIO campaign shows how modern threat groups capitalize on these overlooked entry points to carry out large scale espionage without drawing immediate attention.

Strengthening monitoring for third party scripts, enforcing strict content loading rules, and improving user awareness about fake browser updates can reduce exposure to threats like BADAUDIO. As long as websites continue to rely on interconnected code ecosystems and automated delivery pipelines, attackers will keep finding ways to weaponize those trusted relationships for long term access and silent malware distribution.

Sean Doyle

Sean is a tech author and security researcher with more than 20 years of experience in cybersecurity, privacy, malware analysis, analytics, and online marketing. He focuses on clear reporting, deep technical investigation, and practical guidance that helps readers stay safe in a fast-moving digital landscape. His work continues to appear in respected publications, including articles written for Private Internet Access. Through Botcrawl and his ongoing cybersecurity coverage, Sean provides trusted insights on data breaches, malware threats, and online safety for individuals and businesses worldwide.

More Reading

Post navigation

Leave a Reply

This site uses Akismet to reduce spam. Learn how your comment data is processed.