Plack\Application · Miyagawa

CVE-2026-7381

CRITICAL · 9.1 CVSS v3.1 Published 2026-04-29
Fix available
A fix is available. Upgrade to after 1.0053 or later.
See remediation →
100/100
Remediation priority · Urgent
Remotely reachable No privileges Zero-click

Official description Straight from the sourceThe vendor's or NVD's own wording, published unedited. Authoritative, but often terse — it says what broke, rarely what to do.

NVD · unedited
Plack::Middleware::XSendfile versions through 1.0053 for Perl can allow client-controlled path rewriting. Plack::Middleware::XSendfile allows the variation setting (sendfile type) to be set by the client via the X-Sendfile-Type header, if it is not considered in the middleware constructor or the Plack environment. A malicious client can set the X-Sendfile-Type header to "X-Accel-Redirect" to services running behind nginx reverse proxies, and then set the X-Accel-Mapping to map the path to an arbitrary file on the server. Since 1.0053, Plack::Middleware::XSendfile is deprecated and will be removed from future releases of Plack. This is similar to CVE-2025-61780 for Rack::Sendfile, although Plack::Middleware::XSendfile has some mitigations that disallow regular expressions to be used in the mapping, and only apply the mapping for the "X-Accel-Redirect" type.

Technical summary Written by usOur analysis, written from the advisory, the CVSS vector and the affected-version data. It adds context the advisory leaves out, and never invents facts that are not in the source.

dbcve analysis · high confidence

Plack::Middleware::XSendfile allows attackers to control the X-Sendfile-Type HTTP header, enabling them to set it to 'X-Accel-Redirect' for nginx reverse proxies and abuse the X-Accel-Mapping configuration to read arbitrary files on the server by manipulating file paths.

MitigationUpgrade to version 1.0054 or later if available, otherwise remove or disable Plack::Middleware::XSendfile; alternatively, ensure the X-Sendfile-Type header cannot be set by clients and is validated server-side in the middleware constructor.

Verify against the referenced sources before acting — the references below are authoritative for this CVE, this summary is not.

Affected products & versions What the vendor confirmedThe version ranges the vendor confirmed as vulnerable. If your version sits inside a range here, treat yourself as exposed until you have upgraded.

NVD · CPE data
Plack\Application
Affected:<= 1.0053

CVSS breakdown How the score is builtThe industry scoring standard. It rates how the flaw is reached, what it takes to exploit, and what an attacker gains — the score is derived from those, not the other way round.

From the vector
Attack vector
Network
Complexity
Low
Privileges
None
User interaction
None
Scope
Unchanged
Confidentiality
High
Integrity
High
Availability
None

CVSS:3.1/AV:N/AC:L/PR:N/UI:N/S:U/C:H/I:H/A:N

Am I affected? How to checkSteps we derive from the advisory and the affected-version data, so you can decide whether this CVE reaches your setup. They are a guide, not a scan — your own configuration is the authority.

dbcve checks

Work through these to decide whether this CVE applies to you.

  1. Check installed Plack version
    Run `perl -MPlack -e 'print $Plack::VERSION . "\n"'` or use your Perl distribution's module manager to query the Plack version
    Affected if The version is 1.0053 or lower
  2. Identify if XSendfile middleware is loaded
    Search your Plack application configuration (psgi files, startup scripts) for 'Plack::Middleware::XSendfile' or 'enable "XSendfile"'
    Affected if The middleware is explicitly loaded in your application configuration
  3. Verify if client headers can control sendfile behavior
    Inspect your Plack application code and middleware stack to determine whether HTTP headers X-Sendfile-Type and X-Accel-Mapping from client requests are passed to the XSendfile middleware without sanitization
    Affected if The application accepts and processes X-Sendfile-Type or X-Accel-Mapping headers directly from incoming HTTP requests without server-side validation
  4. Confirm nginx proxy configuration
    If using nginx as a reverse proxy, check if X-Accel-Redirect handling is enabled and whether the application has defined X-Accel-Mappings that could be overridden
    Affected if nginx is configured to honor X-Accel-Redirect headers from the backend application

You are affected if you run Plack version 1.0053 or lower with the XSendfile middleware enabled and your application processes X-Sendfile-Type or X-Accel-Mapping headers from client requests without server-side validation.

Generated from the published advisory. Verify against your own configuration.

Check your environment

Paste your version and any relevant configuration and it will be compared against the affected criteria above. Do not include secrets or credentials.

AI-assisted, checked against the advisory. Informational, not a guarantee.

Remediation Closing itWhat it takes to close this. Where a vendor fix exists we point at it; where none exists we say so plainly, and can build one. Effort estimates are scoped from the advisory, not from your codebase.

dbcve · scoped
Upgrade available Upgrade to a release after 1.0053
Interim mitigation

Upgrade to version 1.0054 or later if available, otherwise remove or disable Plack::Middleware::XSendfile; alternatively, ensure the X-Sendfile-Type header cannot be set by clients and is validated server-side in the middleware constructor.

Recommended fix High confidence
  1. 1. Stop using Plack::Middleware::XSendfile - the module is deprecated and will be removed from future Plack releases.
  2. 2. Review your application for any dependencies on X-Sendfile/X-Accel-Redirect functionality.
  3. 3. Implement file serving directly through your application code or use your web server's native mechanisms instead.
  4. 4. Remove the Plack::Middleware::XSendfile middleware from your Plack middleware stack.
  5. 5. If you require sendfile functionality, evaluate alternative approaches compatible with your deployment environment.
Caveat Plack::Middleware::XSendfile is deprecated with no planned replacement; applications using this middleware must be refactored to remove this dependency.

Generated from the published advisory — verify against the referenced sources before acting.

Fix this in Plack\ Scoped from the published advisory
  • Consultation4.0 h
  • Implementation8.0 h
  • Testing6.0 h
  • Review / QA3.0 h
21.0 hours of engineering $3,680
Get the upgrade done

An estimate, not a bill — we confirm scope with you before any work starts. Need it this week? Rush from $5,888.

Scan for this in your stack

Free · runs locally
dbcve dependency scanner

Check whether your project pulls in CVE-2026-7381 — or any other known-vulnerable package — straight from your lock files. Free and open source; it runs locally and uploads nothing.

References Go to the primary sourcePrimary sources — vendor advisories, patches and trackers. Where our summary and a reference disagree, the reference wins.

Primary sources

Practitioner notes

Contributed

Peer-ranked notes from engineers who’ve handled CVE-2026-7381 in production — separate from our analysis above.

No notes yet

Be the first to add a field note for this CVE — a mitigation you’ve verified, a version caveat, or a link to a working fix. Sign in above to contribute.

What this is

A place for practitioners to share what actually worked: a mitigation you’ve tested, a configuration change, a version- or environment-specific caveat, or a link to a verified patch. The most useful notes rise to the top as peers upvote them, so the signal stays high.

What belongs here
  • Verified mitigations, workarounds, and config changes
  • Version or environment caveats, and links to real fixes
  • No weaponised exploit code, or anything meant to cause harm
  • No spam, self-promotion, credentials, or personal data