npm Mirrors Used for Fake Cloudflare CAPTCHA Phish

The Hacker News · Medium sophistication
Last updated August 26, 2026

Researchers found a real phishing campaign abusing npm packages and unpkg mirrors to host a convincing fake Cloudflare CAPTCHA page on a trusted domain. Victims who click the mirrored link are redirected to attacker-controlled infrastructure that could deliver ClickFix-style prompts or credential theft. The actors also rotated their backend from a Microsoft typosquat domain to a legitimate KeyVal service to hide the final redirect destination.

How the Attack Worked

Attackers published 24 npm packages, each containing a single HTML page. The goal was not to infect developers through package installation, but to use npm and mirror services like unpkg as trusted, validated storage for phishing content. Once mirrored, the HTML file renders as a live, fully rendered fake Cloudflare CAPTCHA page hosted on a domain that most users and security tools consider trustworthy. After a victim completes the fake verification step, the page redirects them to attacker-controlled infrastructure, which could deliver ClickFix-style prompts or credential theft.

Hiding the Redirect Behind Legitimate Services

The page embeds JavaScript that contacts a remote server to determine where to send the victim next. Early versions of this logic pointed to a typosquat domain impersonating the Microsoft login page. After that domain was added to a browser Safe Browsing blocklist, the actors switched to a legitimate third-party service to resolve the final redirect, turning it into what researchers describe as a dead drop resolver. This domain rotation shows how quickly attackers can adapt when one piece of infrastructure gets blocked.

Why It Succeeded

The campaign relies on misplaced trust in domain reputation. A CAPTCHA hosted on a known developer mirror looks legitimate at a glance, and the redirect logic is hidden behind a backend call rather than visible in the link itself. Because the current redirect destination is benign, the page can pass casual inspection while remaining ready to be repointed to malicious content.

What to Watch For

  • Verification or CAPTCHA pages hosted on package mirrors or CDNs instead of expected company domains
  • Verification steps that redirect immediately to an external website
  • Links containing unusual versioned package paths

Building Resistance

Treat any CAPTCHA or verification prompt that redirects elsewhere as suspicious, regardless of the hosting domain's reputation. Encourage employees and developers to report unexpected verification pages so security teams can investigate before the redirect logic is weaponized against benign destinations.

Key findings

  • Attackers published 24 npm packages containing a single HTML page, not to infect developers via install, but to use npm and mirrors as "safe, validated storage" for phishing content.
  • The mirrored HTML (e.g., on unpkg) renders a fake Cloudflare CAPTCHA page on a trusted domain and then redirects victims to attacker-controlled infrastructure.
  • Early versions contacted a Microsoft-impersonating typosquat domain (login.microsofte.live) but later switched to the legitimate KeyVal service (api.keyval.org) to resolve the final redirect.
  • Researchers warn the current redirect destination is benign (ChatGPT) but could be reconfigured to send victims to ClickFix or other phishing pages.

Who’s being targeted

  • Commonly targeted roles: All employees, Developers, IT support/helpdesk, Security awareness and SOC teams.
  • Affected industries: Software development, Technology / IT, Any organization whose users click links to trusted developer CDNs/mirrors.
  • Attack channels: email, website.
  • Impersonated: Cloudflare verification (hosted via unpkg mirror), Cloudflare verification page + backend resolver.

Red flags to watch for

  • The 'Cloudflare CAPTCHA' is hosted on a developer package mirror (unpkg) instead of a company-owned or expected domain.
  • The page performs an unexpected redirect to an external site after the CAPTCHA step.
  • The link originates from an unusual npm package path/versioned URL.
  • Page uses a 'trusted' brand verification theme but relies on unusual third-party lookups to resolve where to send the user next.
  • The backend changes over time (domain rotation) to avoid blocking.
  • Redirect destination is not visible up front and can be swapped by the attacker.
Try Mirage

Mirage safely runs attacks like this one against your own team, so you find out what happens before a real adversary does.

Get a demo

Frequently asked questions

How did attackers use npm packages in this campaign?

They published 24 npm packages containing a single HTML page, not to infect developers who install them, but to use npm and mirrors like unpkg as trusted, validated storage for phishing content.

What happens after a victim sees the fake CAPTCHA?

The mirrored HTML renders a fake Cloudflare CAPTCHA page on a trusted domain and then redirects victims to attacker-controlled infrastructure, which could deliver ClickFix-style prompts or credential theft.

Why did the attackers switch backend domains?

Early versions contacted a Microsoft-impersonating typosquat domain, but after it was added to a Safe Browsing blocklist, the actors switched to a legitimate service to hide the final redirect destination.

Is the current redirect destination dangerous?

Researchers note the current redirect goes to a benign destination, but warn it could be reconfigured at any time to send victims to phishing or malware pages.

Read the video transcript

You click a link, see a Cloudflare CAPTCHA on a trusted site, and think, "Safe." That’s exactly the trap. Attackers published npm packages that are just one HTML file. When mirrored on unpkg, that file becomes a fake Cloudflare page that then silently sends you off to their next site. Behind that page, scripts call out to backends like login.microsofte.live or api.keyval.org to decide where to send you next. Today it might land on ChatGPT; tomorrow it could be a ClickFix credential phish. If you ever see a Cloudflare-style CAPTCHA on an unpkg, npm, or other package mirror URL, stop and report it to security, don’t click through.

Categories

Similar attacks

Phished npm Maintainer Led to Debug/Chalk Hijack

Phished npm Maintainer Led to Debug/Chalk Hijack

Amazon says North Korea-linked actors compromised widely used npm packages (including debug and chalk) by tricking a trusted maintainer into signing in through a lookalike npm domain. After gaining that trusted access, the attackers published malicious updates that altered crypto wallet…

July 30, 2026
Fake reCAPTCHA “Fix” Spreads MaaS Malware

Fake reCAPTCHA “Fix” Spreads MaaS Malware

Researchers observed real campaigns using compromised WordPress sites to show fake verification/BSOD-style prompts that trick users into running a copied PowerShell command. The technique (ClickFix) was paired with MaaS tools (ErrTraffic and Cruciferra) to deliver malware while attempting to kill…

August 19, 2026
Fake ChatGPT Billing Emails Steal Card Details

Fake ChatGPT Billing Emails Steal Card Details

Check Point reports that scammers are now impersonating ChatGPT/OpenAI in phishing campaigns, reflecting how mainstream the service has become. One documented example used a fake “ChatGPT Plus payment failure” notice that sent victims to a fraudulent payment page designed to capture full credit…

July 28, 2026
Fake ChatGPT Billing Emails Steal Card Details

Fake ChatGPT Billing Emails Steal Card Details

Check Point reports that OpenAI’s ChatGPT became a top-10 most impersonated brand in Q2 2026 phishing. One observed example used a fake “ChatGPT Plus payment failed” billing email to drive victims to a credit-card theft page. The report also notes other brand-impersonation scams using cloned stores…

July 24, 2026
Phish Adds Passkey That Survives Reset

Phish Adds Passkey That Survives Reset

Researchers described iAuthFlow v2, a phishing toolkit that steals a live Google login session and then uses that access to enroll an attacker-controlled passkey. Because passkeys are separate login methods, the attacker can often get back into the account even after the victim changes their…

August 24, 2026
Attackers Phish via Teams & Slack, Not Email

Attackers Phish via Teams & Slack, Not Email

Research and incident examples show attackers increasingly using trusted collaboration tools (like Microsoft Teams and Slack) to impersonate IT/support or known community members, then push victims to phishing sites, approve MFA prompts, or run malicious files. Because messages come through…

August 20, 2026