SponsoredHorizon3.ai

Proactive Security for the AI Era

NodeZero continuously and autonomously pentests infrastructure, identity, cloud, and now web applications, chaining weaknesses across every domain the way real attackers do. Every finding ships with replayable proof showing exploitable business impact, not theoretical risk.

See NodeZero WebApp in action

Decryption Digest has already covered quishing at the general level: how QR-code phishing bypasses text-based URL filters because the malicious link lives inside an image rather than a hyperlink. That earlier post, Quishing: How QR Code Phishing Bypasses Email Security and How to Stop It, is the right starting point for general background if your organization has not yet enabled any QR decoding on its email gateway.

This guide picks up where that gap analysis stops. It assumes your gateway already decodes QR images and checks the extracted URL, and it addresses a narrower, more current problem: attackers have started building QR codes specifically to defeat that decode-and-check pipeline. Barracuda's threat research team documented two techniques in active phishing-as-a-service campaigns in mid-2025, split QR codes (used by the Gabagool kit) and nested QR codes (used by Tycoon 2FA), both aimed at Microsoft credential harvesting. Neither technique requires the attacker to hide the QR code from the human victim. Both are built to confuse or starve the automated decoder that runs before the message reaches an inbox.

Problem Statement: Exactly How Nested QR Codes Defeat Standard Gateway Scanning

Most gateway QR handling today follows the same shape: an image classifier flags a likely QR symbol in the message, an optical decoder (typically a standard library such as ZXing or ZBar under the hood) attempts a single decode pass, and if it returns a URL, that URL is submitted to the same reputation and sandboxing pipeline used for text-based hyperlinks. This closed the original quishing gap, where the failure mode was simply never attempting a decode at all.

Nested and split QR codes attack the decode step itself, not the reputation step downstream.

Nested QR codes place a second, functional QR code inside or overlapping the finder patterns of a first QR code in the same image. Barracuda's research describes the outer code resolving to a malicious URL while an inner code resolves to something legitimate, such as a Google URL. A single-pass decoder scanning left to right or center-out returns whichever symbol its algorithm locks onto first. That produces one of three outcomes for the gateway: it decodes the benign code and clears the message, it decodes the malicious code and (if reputation checks the URL correctly) catches it, or it detects two overlapping/conflicting symbol patterns, fails to get a clean read, and passes the image through as undecodable rather than blocking on an inconclusive result. Attackers are optimizing for the first and third outcomes. A human eye and a phone camera app, by contrast, tend to resolve the more visually dominant or better-aligned code, which is the one the attacker controls.

Split QR codes take a different route to the same result. The Gabagool kit divides one complete QR payload across two separate image files placed side by side or stacked in the message body, styled as fake Microsoft password reset notifications. Each individual image is a partial, non-decodable QR fragment. Gateways that classify and decode images independently see two images that each fail to produce a valid QR read, so no URL is ever extracted from either one. The full code only reconstructs visually once rendered together in an actual mail client, which is precisely where the human victim, not the gateway, encounters it.

A third, closely related evasion path matters even when the decode step succeeds cleanly: the decoded URL itself can be a legitimate-looking first hop. Attackers increasingly route the QR payload through a URL shortener, a cloud storage share link, an open redirect on a trusted domain, or a CAPTCHA-gated interstitial before the actual credential-harvesting page. If your gateway's reputation check evaluates only the first-hop domain and does not follow the redirect chain, a technically correct decode still clears a malicious campaign because the string it checked was never itself flagged as bad.

Prerequisites

Before starting the implementation procedure below, confirm the following. Skipping this check means you are debugging the wrong layer.

  • An email security gateway or add-on that already performs QR decoding. This includes Microsoft Defender for Office 365 (Plan 2, Safe Links extended to QR-extracted URLs), Proofpoint Targeted Attack Protection, Mimecast URL Protect, Abnormal Security, or Perception Point. If your gateway does not decode QR images at all, fix that gap first: the techniques in this guide are meaningless against a pipeline with zero QR-decoding capability.
  • Confirmed knowledge of what your current QR-scanning logic actually does. Specifically: does it attempt more than one decode pass per image, does it flag images containing multiple overlapping QR-like patterns as suspicious on their own, and does it resolve the decoded URL through any redirect hops before reputation scoring, or only check the literal string extracted from the code. Most vendors do not document this level of detail publicly; get it from your account team or a support ticket, not the marketing page.
  • Log access to review what the gateway extracted from a known QR-bearing message, whether from message trace, a security event export, or a SIEM integration, so you can verify results in the validation phase rather than assuming success.
  • The ability to add a secondary scanning layer (a sandbox platform, a SOAR playbook, or a secondary vendor product) if your primary gateway's vendor has not yet shipped multi-symbol or redirect-chain handling. Not every gateway can be reconfigured internally to close this gap; some require a compensating layer instead.
Free daily briefing

Briefings like this, every morning before 9am.

Threat intel, active CVEs, and campaign alerts, distilled for practitioners. 50,000+ subscribers. No noise.

Implementation Procedure: Closing the Nested/Split QR Detection Gap

Work through these steps in order. Steps 1 through 3 are gateway-native configuration checks; steps 4 through 6 add the compensating detection layer that catches what native decoding still misses.

Subscribe to unlock Remediation & Mitigation steps

Free subscribers unlock full IOC lists, Sigma detection rules, remediation steps, and every daily briefing.

Validation: Testing the Fix Against a Real Nested-QR Sample

Configuration changes are worthless until you have proven they change the outcome on an actual nested or split QR sample, not just a plain single-code test message.

Constructing a safe test nested QR code: Generate two valid QR codes with any free QR generator, one encoding a known-benign internal test URL and one encoding a second known-benign URL from a different domain. Overlay them in an image editor so the two symbols visually overlap or share finder-pattern space, approximating the structure Barracuda describes (an outer and inner code in the same graphic). Do not use a live malicious sample from a public threat intel feed for this test; a safe synthetic overlap is sufficient to validate decoder behavior.

Constructing a safe test split QR code: Generate a single QR code encoding a benign test URL, then physically cut or crop the resulting image into two roughly equal fragments and place them as two separate image files in a test email, positioned adjacently as they would render in a mail client.

What to check after sending each test through your pipeline:

  • Did the gateway's classifier flag either test image as QR-like content at all, even without a clean decode
  • For the nested test, which of the two encoded URLs (if either) appears in the extracted-URL log, and does the log show any indicator that more than one symbol was detected in the image
  • For the split test, did the message get held, quarantined, or flagged for the undecodable multi-image pattern, or did it pass through silently
  • If you implemented Step 3's redirect-chain following, send a QR code encoding a URL that redirects at least twice before reaching a test landing page, and confirm the final hop, not just the first, drives the reputation verdict
  • Repeat the full test set after any vendor policy change or platform update, since decoder behavior for edge cases like this is not guaranteed to be stable across releases

Failure Cases: How This Technique Can Still Evade Improved Detection

Closing this gap reduces exposure; it does not eliminate the underlying architectural problem, which is that a QR code is fundamentally a rendered image and the ground truth of what it decodes to can depend on decoder implementation, image resolution, and rendering context in ways that are hard to fully standardize.

  • Decoder-specific blind spots persist. An attacker who tests their nested or split QR construction against the same open-source decoder libraries commonly used in gateway products (ZXing, ZBar) can iterate until they find a symbol layout that reliably favors the malicious code on that specific library, while still resolving to the malicious code on the far more permissive decoders built into iOS and Android camera apps.
  • Rendering-dependent attacks persist even after compositing. If a secondary scanner composites multi-part images at a different resolution, scale, or color depth than the recipient's actual mail client will use, a split QR code tuned for a specific rendering size may still fail to reconstruct correctly in the scanner even though it reconstructs correctly for the human recipient.
  • Redirect chains can be time-delayed or geofenced. A redirect chain that resolves to a benign page when crawled by a security vendor's sandbox IP range or immediately after send, but flips to the malicious landing page after a delay or only for requests from residential IP ranges and mobile user agents, defeats redirect-following detonation even when it correctly follows multiple hops. This is a known evasion pattern in broader phishing infrastructure and applies equally to QR-encoded redirect chains.
  • Out-of-band delivery bypasses email scanning entirely. None of the controls in this guide apply to a nested or split QR code delivered via a channel your email gateway never touches: a physical sticker, a Teams or Slack message, an SMS image, or a QR code embedded in a PDF hosted on a legitimate but compromised or lookalike third-party site rather than attached to the email itself.
  • CAPTCHA and interaction gates block automated follow-through outright. A redirect chain ending in a CAPTCHA challenge or a JavaScript-gated interstitial defeats sandboxed URL crawling regardless of how many hops the sandbox is configured to follow, since the sandbox typically cannot solve the challenge and will either see a blank page or stall before reaching the actual credential harvesting page. This is the same fake-verification pattern covered in ClickFix Detection: Stopping Fake CAPTCHA Malware Delivery, and it applies equally well as a quishing redirect endpoint as it does to malware delivery.

Security Tradeoffs: False Positives vs. Coverage Gain

Every control recommended above increases the aggressiveness of image and QR analysis, and that comes with a real false positive cost that should be weighed deliberately rather than deployed blind.

Multi-symbol and overlap detection (Step 2) will flag legitimate compound graphics. Marketing emails, event materials, and vendor communications that legitimately place two QR codes in one graphic (for example, one for iOS and one for Android app store links) will trigger the same signal as a nested malicious code. Start this control in monitor/alert mode rather than automatic quarantine, and build an allowlist for known internal and vendor senders who use this pattern legitimately before enforcing a hard block.

Quarantining undecodable multi-image messages (Step 5) will catch legitimate split-image content. Newsletters, infographics, and design-heavy marketing emails routinely split a single visual across adjacent images for layout reasons unrelated to QR codes. Scope this rule narrowly to image pairs the classifier specifically identifies as partial QR-pattern fragments, not to any message containing multiple small adjacent images, or the false positive volume will overwhelm the SOC queue within days.

Full redirect-chain detonation (Step 3) increases latency and infrastructure cost. Following two to three hops per QR-extracted URL through a detonation sandbox is materially more expensive, in both processing time and licensing cost on consumption-priced sandboxing tiers, than a single reputation lookup. Message delivery delay for legitimate QR-bearing email (event tickets, boarding passes, genuine MFA setup flows) will increase measurably. Set a delivery hold SLA target (most vendors target under two minutes for full detonation) and monitor it, since a control that delays legitimate boarding passes by ten minutes will generate help desk tickets that erode trust in the security team faster than the phishing catch rate builds it.

OCR and image-structure analysis (Step 6) has the highest tuning burden of any control here. Distorted, low-resolution, or stylized QR codes in entirely legitimate contexts (scanned documents, faxed forms, print-to-PDF conversions with compression artifacts) can trigger the same visual-noise heuristics used to flag obfuscated malicious codes. Budget for an explicit tuning period with a human-reviewed sample set before this control moves from alerting to automatic action, and expect to revisit thresholds after any change to your mail client's image rendering or compression pipeline.

The bottom line

Nested and split QR codes are not a fundamentally new attack category. They are a direct, engineered response to the specific decode-and-check pipeline that most email gateways built in 2024 and 2025 to close the original quishing gap, and Barracuda's research confirms both techniques are already in active use by Tycoon 2FA and Gabagool phishing-as-a-service kits against Microsoft credential targets. Closing this narrower gap requires verifying, in writing from your vendor, whether your decoder handles multiple QR symbols per image and whether reputation scoring follows redirect chains rather than checking only the first hop, then layering in secondary decode passes, image compositing, and OCR/structure analysis for anything the primary pass cannot cleanly resolve. None of this replaces phishing-resistant MFA as the backstop control: a nested or split QR code that successfully reaches a user and harvests a password still produces a stolen credential, and only an authentication method bound to origin, not the email gateway, stops that credential from being used.

Frequently asked questions

What is the difference between a nested QR code and a split QR code in phishing attacks?

A nested QR code places a second, functional QR symbol inside or overlapping the finder patterns of a first QR code within the same image, so a single-pass decoder returns either the benign code, the malicious code, or an ambiguous failed read depending on which pattern it locks onto. A split QR code instead divides one complete malicious QR payload across two separate image files placed adjacently in the email body, so each individual image fails to decode on its own and the full code only reconstructs visually once rendered together in an actual mail client. Barracuda's research attributes nested QR codes to the Tycoon 2FA phishing-as-a-service kit and split QR codes to the Gabagool kit, both used in Microsoft credential phishing campaigns.

Can Microsoft Defender for Office 365 or Proofpoint detect nested QR codes out of the box?

Both platforms decode QR images and check the extracted URL against reputation and sandboxing pipelines, which closes the original quishing gap of never attempting a decode at all. Neither vendor has published documentation confirming their decoder extracts every distinct QR symbol present in a single image rather than only the first one it locks onto, which is the specific mechanism nested QR codes are built to exploit. Confirm this behavior directly with your vendor's support or account team rather than assuming it from general QR-detection marketing claims, since the answer determines whether you need additional compensating controls.

Why does a QR code that decodes to a benign URL still get flagged as risky in this guide's approach?

Because the decoded string being benign only tells you what the first hop resolves to, not what the full redirect chain or the code's structural context indicates. Attackers route QR payloads through URL shorteners, cloud storage links, or open redirects on trusted domains specifically so the first-hop domain passes reputation checks, with the malicious landing page appearing only after one or more redirects. A nested QR code can also legitimately decode to a benign URL on one pass while a second, malicious symbol in the same image goes unread. This guide recommends treating structural anomalies (multiple QR-like patterns in one image, undecodable image fragments, redirect chains beyond the first hop) as risk signals independent of whether the single decoded string looks clean.

How do I safely test whether my email gateway catches nested or split QR codes without using live malware?

Construct synthetic test samples using only known-benign URLs. For a nested QR test, generate two valid QR codes encoding different benign test URLs and overlay them in an image editor so the symbols visually overlap, then send the composite through your gateway and check the extraction log for which URL (if any) was captured and whether multiple symbols were flagged. For a split QR test, generate one QR code encoding a benign URL, crop it into two fragments, and place them as separate adjacent images in a test message to see whether the gateway flags the undecodable fragments rather than passing them through silently. Never use a live malicious sample pulled from a threat intel feed for this kind of internal pipeline testing.

What compensating control matters most if my email gateway vendor has not yet added nested/split QR handling?

Phishing-resistant MFA (FIDO2 hardware keys or passkeys) matters most because it addresses the outcome of a successful quishing attack rather than the delivery mechanism. Even a well-tuned detection pipeline will not catch every nested or split QR variant, particularly redirect chains that are time-delayed or geofenced to evade sandbox crawling. If credentials are stolen through a QR code that reached the end user, phishing-resistant MFA prevents those credentials from being used because the authentication response is bound to the legitimate domain and will not respond on an attacker-controlled phishing page, regardless of how the victim was routed there.

Will adding OCR and image-structure analysis for QR codes cause a lot of false positives?

Yes, and this tradeoff needs explicit tuning before enforcement. Distorted, low-resolution, faxed, or heavily compressed QR codes in entirely legitimate documents can trigger the same visual-noise heuristics used to flag obfuscated malicious codes, and marketing or vendor emails that legitimately place two QR codes in one graphic (such as separate iOS and Android app store links) will trigger multi-symbol detection. Start these controls in monitor or alert mode with a human-reviewed sample set rather than automatic quarantine, build allowlists for known senders who use compound QR graphics legitimately, and only move to automatic enforcement after a defined tuning period.

Sources & references

  1. Barracuda Networks: Threat Spotlight - Split and Nested QR Codes Fuel New Generation of Quishing Attacks
  2. Microsoft Security Blog: How Microsoft Defender for Office 365 Innovated to Address QR Code Phishing Attacks
  3. Microsoft Tech Community: Hunting and Responding to QR Code-Based Phishing Attacks with Defender for Office 365
  4. ReversingLabs Blog: QR Code Phishing Evolves - How Your Detection Can Keep Up

Free resources

25
Free download

Critical CVE Reference Card 2025–2026

25 actively exploited vulnerabilities with CVSS scores, exploit status, and patch availability. Print it, pin it, share it with your SOC team.

No spam. Unsubscribe anytime.

Free download

Ransomware Incident Response Playbook

Step-by-step 24-hour IR checklist covering detection, containment, eradication, and recovery. Built for SOC teams, IR leads, and CISOs.

No spam. Unsubscribe anytime.

Free newsletter

Get threat intel before your inbox does.

50,000+ security professionals read Decryption Digest for early warnings on zero-days, ransomware, and nation-state campaigns. Free, daily, no spam.

Unsubscribe anytime. We never sell your data.

Eric Bang
Author

Founder & Cybersecurity Evangelist, Decryption Digest

Cybersecurity professional with expertise in threat intelligence, vulnerability research, and enterprise security. Covers zero-days, ransomware, and nation-state operations for 50,000+ security professionals every morning.

Giveaway: InfoSec World 2026 All Access Pass ($3,895 value)

Details →
Daily Briefing

Subscribe to enter the giveaway

Every subscriber is automatically entered. You also get daily threat intel every morning: zero-days, ransomware, and nation-state campaigns. Free. No spam.

Already subscribed? You're already entered.

Giveaway

Win a $3,895 InfoSec World 2026 pass.