esm.shの脆弱性、認証なしで任意のファイルを読み取られるおそれ
Summary
esm.shのweb.NewHandlerに、URLエンコードされたドットセグメントを使ったパストラバーサルの脆弱性が見つかりました。サーバー版137_7より前の版が影響を受け、認証なしの遠隔からアプリケーションのディレクトリ外にあるファイルを読み取られるおそれがあります。修正版はサーバー版137_7で、更新を行ってください。
AI summary
Produced by SecPulse using an external AI model; it may contain mistakes. Check the original description and references below before acting on it.
esm.shのweb.NewHandlerに、URLエンコードされたドットセグメントを使ったパストラバーサルの脆弱性が見つかりました。サーバー版137_7より前の版が影響を受け、認証なしの遠隔からアプリケーションのディレクトリ外にあるファイルを読み取られるおそれがあります。修正版はサーバー版137_7で、更新を行ってください。
Affected packages
| Package | Affected → Fixed | |
|---|---|---|
| esm-devesm.sh | — | Not listed |
| gogithub.com/esm-dev/esm.sh/web |
< 0.2.0→ 0.2.0 |
0.2.0 |
| Gogithub.com/esm-dev/esm.sh |
< 0.2.0→ 0.2.0 |
0.2.0 |
Original description The description as published by the source.
esm.sh is a no-build content delivery network (CDN) for web development. Prior to server version 137_7, the documented web.NewHandler static file server in web/handler.go joins the URL-decoded r.URL.Path with Config.AppDir without verifying that the result remains inside the configured application directory. URL-encoded dot segments such as %2e%2e bypass the plain traversal redirect performed by Go's ServeMux, allowing an unauthenticated remote attacker to make the server open and return files outside Config.AppDir that are readable by the server process. The confirmed impact is file disclosure only, and the issue is reachable with Dev disabled. This issue is fixed in server version 137_7.
Source: CVE.org (CVE Program・cvelistV5) NVD GitHub Advisory
References
- advisory github.com
- advisory github.com
- advisory nvd.nist.gov
- package github.com
- patch github.com
- patch github.com
- patch github.com
- web github.com
- web github.com
- web github.com