Attack ChainAIDerived
Hypothetical attack flow derived from CVE metadata – not a confirmed exploit chain
-
AccessSend HTTP request to guard-protected route
-
DeliveryBefore hook dies to refuse request
-
ExploitException handler halts response
-
ExecutionCleanup discards request/response/session
-
PersistDispatcher runs the refused route
-
ImpactUnauthorized route writes land
Vulnerability Assessment
| Weakness |
CWE
OWASP Top 10:2025
A10:2025 - Mishandling of Exceptional Conditions
ASVS 5.0
V16 - Security Logging and Error Handling Exception cleanup procedures
|
| Exploitation Conditions | Requires a Dancer2 application on 2.0.0 through 2.1.x that (1) enforces a security or authorization check by having a 'before' hook die to refuse the request, AND (2) registers an on_hook_exception handler that halts the response (by calling the response's halt method or setting is_halted). Only under this exact pattern does the post-exception cleanup discard the request/response/session so the refused route executes anyway. The limiting factor is this non-default application design: apps that do not refuse via dying hooks, or whose exception handler does not halt, are not affected. When the pattern is present, triggering it is a single ordinary request (AV:N, AC:L, PR:N, UI:N). |
| Impact | This is a security-control-bypass in the Dancer2 Perl web framework (2.0.0 before 2.2.0, CWE-460 improper cleanup on thrown exception). Signals point to a LOW real-world priority despite the 7.5 base score: EPSS is 0.17% (7th percentile), there is NO CISA KEV listing and NO public exploit code, and SSVC records Exploitation:none (Automatable:yes, Technical Impact:partial). The vendor CVSS vector (AV:N/AC:L/PR:N/UI:N/S:U/C:N/I:N/A:H) is internally inconsistent with the description: the flaw does not cause loss of availability - instead a before-hook refusal is silently bypassed so 'the route body runs and its writes land,' which is an INTEGRITY/access-control impact, not A:H. The 'Information Disclosure' tag is also questionable because the description states 'the caller gets the refusal' (the attacker receives the refusal response, not the route output), so no data is returned to the attacker. Net: a genuine logic bug confirmed by the source diff, but exploitability is gated on a specific application pattern (a dying before-hook used to refuse a request PLUS an on_hook_exception handler that halts), so treat as a routine patch-when-convenient item rather than an urgent priority. Verify the true impact type with the vendor advisory - A:H appears misapplied. |
| Exploit ScenarioDerived | A Dancer2 app enforces authorization by having a before hook die (refuse) unauthorized requests, and registers an on_hook_exception handler that halts the response to return a clean refusal. Because the halt does not stop the post-exception cleanup, the discarded request/response/session lets the dispatcher run the very route the hook meant to block: the attacker sends an ordinary HTTP request, receives the 'refused' response, yet the protected route body executes and its writes are committed. No public exploit code exists at time of analysis. |
Get an e-mail when this CVE is exploited, patched or re-scored. Free account.
Alert meAnalysisAIv1 – Sep 22, 2026
Security-control bypass in the Dancer2 Perl web framework (2.0.0 through 2.1.x) lets a refused route execute anyway: when an application enforces an authorization or security check by having a 'before' hook die and also registers an on_hook_exception handler that halts the response, the post-exception cleanup still runs and destroys the request, response and session the dispatcher needs, so the route body the hook meant to refuse runs and its writes land. The flaw requires that specific non-default application design - apps that do not refuse via dying hooks, or whose exception handler does not halt the response, are not affected - and, when the pattern is present, a single unauthenticated remote request is enough to trigger it (AV:N/AC:L/PR:N/UI:N), giving a high integrity impact on denial-protected state changes. EPSS is 0.17% (7th percentile) and there is no public exploit identified at time of analysis; CISA's SSVC rates exploitation as none, automatable as yes, technical impact partial. Vendor-released patch: Dancer2 2.2.0, which adds a halt check to the cleanup guard and makes hook compilation idempotent.
RemediationAI
Upgrade to Dancer2 2.2.0, the vendor-released patch version, which makes compile_hooks idempotent via a per-hook _compiled_hooks registry (keyed by Scalar::Util::refaddr with a retained reference) and adds '|| $is_halted' to the cleanup guard so a halted response is never destroyed (see the advisory at https://github.com/PerlDancer/Dancer2/security/advisories/GHSA-v527-r4px-7vx7 and the commit at https://github.com/PerlDancer/Dancer2/commit/8fd31a32798f9aa25e4fccbd6c7cb9dd3a0c1029.patch, plus the release notes at https://metacpan.org/release/CROMEDOME/Dancer2-2.2.0/changes). If upgrading cannot be done immediately, the reliable workaround is to stop refusing requests via a dying 'before' hook and instead refuse with the halt keyword or by setting the response's halted state inside the before hook itself - halt unwinds through with_return before cleanup runs, so the refused route never dispatches - at the cost of changing the refusal response body/status seen by clients and altering how on_hook_exception logging behaves. Alternatively, remove the offending on_hook_exception handler's object-level halting and let the exception propagate to the 500 handler, accepting that the handler's custom error response is lost. For defense in depth, enforce authorization in a Plack middleware placed ahead of the Dancer2 app, or inside the route handlers themselves, so a refusal returns before hook cleanup and dispatch can interfere; this duplicates logic and must be kept in sync with the hook-based checks. Debian users tracking the four affected releases should apply the distribution's updated package once available rather than relying on local backports. No vendor-released patch is missing here, so no other compensating control should be treated as equivalent to upgrading to 2.2.0.
Affected ProductsAI
Dancer2 for Perl versions from 2.0.0 before 2.2.0 - effectively the 2.0.0 through 2.1.x series - are affected; the fix landed in Dancer2 2.2.0 (see the metacpan changes file for CROMEDOME/Dancer2-2.2.0 and the GitHub security advisory GHSA-v527-r4px-7vx7). Applications are only exploitable if they implement a security or authorization refusal by dying inside a 'before' hook AND register an on_hook_exception handler that halts the response object (halt method or is_halted); this is a non-default application design, so libraries or apps that do not use that pattern are unaffected even on vulnerable framework versions. Downstream distribution exposure includes Debian, which tracks four releases of the package, plus any CPAN-based deployment pinned below 2.2.0; the advisory, the oss-security/Openwall threads and the EUVD entry EUVD-2026-84256 (mapped to NVD CVE-2026-93710) all describe the same version range. No CPE identifiers were supplied in the source data, so exact platform strings could not be confirmed from the input.
Affects your stack
Find out whether the stacks and servers you run are on an affected version.
Checking this CVE against your own stacks and servers is part of the Basic plan and up.
Technical ContextAI · show details
Dancer2 is a Perl/PSGI web framework; every application hook registered through its DSL is wrapped by Dancer2::Core::App::compile_hooks (lib/Dancer2/Core/App.pm, around line 1313). The wrapper skips a hook if the response is already halted, fires core.app.hook_exception when the hook dies, and decides whether to keep the response the exception handler produced or croak on to the 500 handler. The defect is CWE-460 (Improper Cleanup on Thrown Exception): after core.app.hook_exception fires for a dying hook, the wrapper invoked cleanup unless the failing hook was the exception handler itself - but the guard did not consider the halted state. A handler that halts by calling the response object's halt method or setting is_halted recorded 'this response is final' in the response, while cleanup nonetheless discarded the request, response and session the dispatcher had not yet read, so route dispatch proceeded and the previously refused route body executed. Notably, the halt keyword is safe from this path because it unwinds through with_return before cleanup runs; only object-level halting inside the exception handler exposes the bug. The same code carried a second, related defect: compile_hooks could run more than once (to_app() calls finish() on each invocation), and because it re-wrapped already-wrapped hooks, a single dying hook reported itself once per layer - hook_exception firing once, then twice, then three times. NVD's CVSS 7.5 vector describes this as availability-only (C:N/I:N/A:H), whereas our independent assessment scores it as integrity (C:N/I:H/A:N) because the concrete consequence is an authorization decision being bypassed and the denied route's writes being persisted; CWE-460 and the fix location in the hook wrapper are the authoritative technical signals.
Know when Perl gets its next vulnerability
- Watch products and get an email when something new is published
- Check this CVE against your own stack and servers
- Exploit and PoC references, threat intelligence from 22 sources
No credit card · 7-day full trial
Severity by source
AV:N/AC:L/PR:N/UI:N/S:U/C:N/I:N/A:H
Remote unauthenticated request bypasses a dying-before-hook refusal so the route's writes land (integrity); caller only gets the refusal (C:N) and there is no availability loss, contradicting the vendor's A:H.
Primary rating from Vendor (CPANSec).
CVSS VectorVendor: CPANSec
Lifecycle Timeline
3DescriptionCVE.org
Dancer2 versions from 2.0.0 before 2.2.0 for Perl dispatch a route that a dying hook refused when the exception handler halts the response in compile_hooks.
A hook that dies fires core.app.hook_exception, then calls cleanup unless the failing hook is the exception handler. A handler that halts does not stop that cleanup, which discards the request, response and session the dispatcher has yet to read, so the refused route runs.
The handler has to halt the response object by calling its halt method or setting is_halted: the halt keyword unwinds through with_return before cleanup runs.
A check in a before hook is not enforced: the caller gets the refusal, while the route body runs and its writes land.
Technical POC Analysis
Bug class: improper cleanup on a thrown exception (the CVE record maps this to CWE-460; the vendor advisory itself lists CWE-755 Improper Handling of Exceptional Conditions and CWE-863 Incorrect Auth…
Full technical POC analysis - root cause, step-by-step exploitation and patch breakdown - is part of the Pro and Business plans.
Executive ViewAI
Dancer2, an open-source Perl web framework used to build custom web applications and APIs, contains a security-control bypass (CVE-2026-93710) that can allow a request the application intended to refuse to execute anyway, letting unauthorized state changes land. The flaw only manifests in applications that combine authorization 'before' hooks that die with an on_hook_exception handler that halts the response - a non-default design - but where that pattern exists, a single unauthenticated remote request is sufficient to bypass the check and write data the application meant to protect. Leadership should care because the control being defeated is the integrity of protected state changes in applications that may be internal or customer-facing; no public exploit code or confirmed active exploitation has been identified at time of analysis, and a vendor patch is available.
Apply vendor patch.
Threat Intelligence Overview
How this decision was reached
The engine reads each signal below and applies a fixed list of rules from top to bottom. The first rule that matches sets the recommended action – like a statement, every line is shown.
What every action level means
SSVC AssessmentENISA
Priority Score
Attack Technique
Information disclosure occurs when an application unintentionally exposes sensitive data that aids attackers in reconnaissance or directly compromises security.
Related Vulnerabilities in Dancer2 Perl Framework Multiple Vulnerabilities
View all 4The _compile function in Maketext.pm in the Locale::Maketext implementation in Perl before 5.17.7 does not properly hand
Stack-based buffer overflow in the CPerlHost::Add method in win32/perlhost.h in Perl before 5.24.3-RC1 and 5.26.x before
The VDir::MapPathA and VDir::MapPathW functions in Perl 5.22 allow remote attackers to cause a denial of service (out-of
Perl before 5.26.3 has a buffer overflow via a crafted regular expression that triggers invalid write operations. Rated
Perl before 5.26.3 and 5.28.0 before 5.28.1 has a buffer overflow via a crafted regular expression that triggers invalid
Silently incorrect regular-expression matching in the Perl interpreter (all versions through 5.43.9) lets an oversized a
Perl before 5.26.3 has a buffer over-read via a crafted regular expression that triggers disclosure of sensitive informa
Perl might allow context-dependent attackers to bypass the taint protection mechanism in a child process via duplicate e
CPAN.pm before 2.35 does not verify TLS certificates when downloading distributions over HTTPS. Rated high severity (CVS
The XSLoader::load method in XSLoader in Perl does not properly locate .so files when called in a string eval, which mig
In Perl through 5.26.2, the Archive::Tar module allows remote attackers to bypass a directory-traversal protection mecha
Perl before 5.30.3 on 32-bit platforms allows a heap-based buffer overflow because nested regular expression quantifiers
Same weakness CWE-460 – Improper Cleanup on Thrown Exception
View allSame technique Information Disclosure
View allVendor StatusVendor
Debian
| Release | Status | Fixed Version | Urgency |
|---|---|---|---|
| bookworm | not-affected | - | - |
| trixie | not-affected | - | - |
| forky, sid | vulnerable | 2.1.0-1 | - |
| (unstable) | fixed | (unfixed) | - |
EUVD-2026-84256
GHSA-qp5m-r6hx-rjhj
NVD
CVE.org
EPSS
Vulnrichment
Exploit-DB