MIYAGAWA (Tatsuhiko Miyagawa)のPlack::Middleware::Xsendfileにおける複数の脆弱性
タイトル MIYAGAWA (Tatsuhiko Miyagawa)のPlack::Middleware::Xsendfileにおける複数の脆弱性
概要

Plack::Middleware::XSendfileのPerl用バージョン1.0053以前には、クライアントが制御するパス書き換えを許可する脆弱性が存在します。Plack::Middleware::XSendfileは、ミドルウェアのコンストラクタやPlack環境で適切に考慮されていない場合、クライアントがX-Sendfile-Typeヘッダーを介してsendfileタイプのバリエーション設定を行える状態となっています。悪意のあるクライアントは、nginxリバースプロキシの背後で動作するサービスに対してX-Sendfile-Typeヘッダーを"X-Accel-Redirect"に設定し、その後X-Accel-Mappingを設定してサーバー上の任意のファイルにパスをマッピングすることが可能です。バージョン1.0053以降、Plack::Middleware::XSendfileは非推奨となり、今後のPlackのリリースから削除される予定です。これはRack::Sendfileの類似の問題に関連していますが、Plack::Middleware::XSendfileにはいくつかの軽減策が存在します。

想定される影響 当該ソフトウェアが扱う全ての情報が外部に漏れる可能性があります。 また、当該ソフトウェアが扱う全ての情報が書き換えられる可能性があります。 さらに、当該ソフトウェアは停止しません。 そして、この脆弱性を悪用した攻撃の影響は、他のソフトウェアには及びません。 
対策

リリース情報、またはパッチ情報が公開されています。参考情報を参照して適切な対策を実施してください。

公表日 2026年4月29日0:00
登録日 2026年5月8日12:09
最終更新日 2026年5月8日12:09
CVSS3.0 : 緊急
スコア 9.1
ベクター CVSS:3.0/AV:N/AC:L/PR:N/UI:N/S:U/C:H/I:H/A:N
影響を受けるシステム
MIYAGAWA (Tatsuhiko Miyagawa)
Plack::Middleware::Xsendfile 1.0053 およびそれ以前
CVE (情報セキュリティ 共通脆弱性識別子)
CWE (共通脆弱性タイプ一覧)
その他
変更履歴
No 変更内容 変更日
1 [2026年05月08日]
  掲載
2026年5月8日12:09

NVD脆弱性情報
CVE-2026-7381
概要

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.

公表日 2026年4月30日8:16
登録日 2026年5月1日4:06
最終更新日 2026年5月7日11:10
影響を受けるソフトウェアの構成
構成1 以上 以下 より上 未満
cpe:2.3:a:miyagawa:plack\:\:middleware\:\:xsendfile:*:*:*:*:*:perl:*:* 1.0053
関連情報、対策とツール
共通脆弱性一覧