Sunday, September 13, 2026

Hackers Target macOS Users with Fake Homebrew Websites to Deliver Malicious Payloads

In September 2025, Kandji’s security researchers uncovered a sophisticated campaign in which attackers deployed multiple spoofed Homebrew installer sites that perfectly mimic the official brew.sh page.

These counterfeit domains served a hidden malicious payload under the guise of the standard Homebrew installation script. This exposé delves into the tactics, infrastructure, and impact of this alarming trend.

Package managers have become a favorite target for supply-chain compromise over the past few years, with high-profile incidents involving NPM typosquatting and PyPI malicious packages dominating headlines.

Homebrew, the most widely used package manager on macOS, had remained unscathed until now—an oasis of stability amidst a storm of ecosystem compromises.

A quick web search for “Homebrew compromise” yields no recent incidents, unlike the deluge of articles on the Shai-Hulud package worm affecting NPM users. Yet threat actors have adapted, shifting to a different approach that targets end users directly by cloning the Homebrew website itself.

In just one week, Kandji analysts discovered four malicious domains—such as homebrewoneline[.]org—resolving to the IP address 38[.]146[.]27[.]144. Each domain presented a flawless carbon copy of the Homebrew homepage.

Unlike the real site, however, these replicas restricted all text selection and copying within the install command block, funneling victims into using a single “Copy” button that surreptitiously loaded an attacker-injected command into the clipboard.

Anatomy of the Attack

At the heart of the spoofed sites lies a snippet of embedded JavaScript that locks down the installation instructions and substitutes the user’s clipboard content.

When visitors click the Copy button, the script triggers the copyInstallCommand() function, which writes a hidden command to the clipboard before executing the legitimate Homebrew install line.

Simultaneously, a fetch request is sent to notify.php, logging metadata such as the click time and user environment. Russian-language comments within the code reveal placeholders for base64-encoded payloads and even suggest exfiltration endpoints like Telegram.

This modular design hints at a commodity-style operation, enabling the attacker to swap in different payloads at will.

Rather than relying on a single infection, the infrastructure also served the Odyssey Stealer in parallel, effectively combining credential theft with persistent malware implant.

Screenshot of the real Homebrew install page.
Screenshot of the real Homebrew install page.

Screenshots of both the authentic Homebrew install page and its spoofed counterpart highlight the only visual difference: the absence of manual copy functionality.

Screenshot of a spoofed Homebrew install page.
Screenshot of a spoofed Homebrew install page.

The true danger, however, lies in the unseen extra line in the clipboard, pulled into the victim’s terminal without their knowledge.

Mitigations

This campaign underscores a critical lesson for macOS developers and administrators: supply-chain security extends beyond packages to encompass the very tools that manage them. Developers often install Homebrew once and assume it remains trustworthy.

In reality, attackers can weaponize convenience by luring users to clone sites. To guard against such vectors, users should always verify install commands against trusted sources and avoid pasting shell snippets from unverified webpages.

Confirm the domain (brew.sh) and examine the clipboard contents before executing any command. Enterprise defenses should include endpoint monitoring that flags unexpected fetch calls or base64-encoded payloads triggered during installation.

Kandji Threat Intelligence continues to scour the internet for new spoofed domains, cataloging dozens more in a public repository maintained by Mikhail Kasimov.

By integrating these IOCs into security tooling and educating end users on safe installation practices, organizations can reduce their exposure to this emerging threat. As package-manager-based malware evolves, vigilance in verifying both package sources and installer sites remains the most effective defense.

Follow us on Google NewsLinkedIn, and X to Get Instant Updates and Set GBH as a Preferred Source in Google.

Mayura Kathir
Mayura Kathirhttps://gbhackers.com/
Mayura Kathir is a cybersecurity reporter at GBHackers News, covering daily incidents including data breaches, malware attacks, cybercrime, vulnerabilities, zero-day exploits, and more.

Hot this week

How To Access Dark Web Anonymously and know its Secretive and Mysterious Activities

What is Deep Web The deep web, invisible web, or...

How to Build and Run a Security Operations Center (SOC Guide) – 2023

Today’s Cyber security operations center (CSOC) should have everything...

Russian Hackers Bypass EDR to Deliver a Weaponized TeamViewer Component

TeamViewer's popularity and remote access capabilities make it an...

Web Server Penetration Testing Checklist – 2026

Web server pentesting is performed under three significant categories: identity,...

ATM Penetration Testing – Advanced Testing Methods to Find The Vulnerabilities

ATM Penetration testing, Hackers have found different approaches to...

Threat Actors Use Claude AI Agents to Automate Cyberattacks and Steal Sensitive Data

Threat actors are increasingly using Claude-based AI workflows to...

China-Linked Hackers Chain Chrome Zero-Day With Windows Kernel Flaw in Attacks

China-linked threat actors UTA0560 and JungleBamboo chained a Google...

New Phishing Campaign Abuses Windows Mshta.exe to Steal Credentials and Secrets

A newly identified phishing campaign is abusing the legitimate...

CISA Warns of Critical GitLab Vulnerability Exploited in Attacks

The U.S. Cybersecurity and Infrastructure Security Agency (CISA) has...

Researchers Uncover 10,000+ Malware Loaders Behind YouTube and SEO Poisoning Campaign

A long-running pay-per-install (PPI) operation that used YouTube gaming...

VLC Media Player Flaws Let Attackers Corrupt Memory and Leak Sensitive Data

Two security vulnerabilities in VLC media player versions 3.0.0...

CISA Adds Exploited MikroTik RouterOS Flaws to Security Alert

The U.S. Cybersecurity and Infrastructure Security Agency (CISA) has...

Related Articles

Recent News