Skip to content

build(deps): bump github.com/labstack/echo/v5 from 5.4.6 to 5.4.7 in /backend in the go-patch group across 1 directory - #489

Merged
L8848-Li merged 1 commit into
mainfrom
dependabot/go_modules/backend/go-patch-746bbe60e9
Nov 30, 2026
Merged

L8848-Li merged 1 commit into
mainfrom
dependabot/go_modules/backend/go-patch-746bbe60e9

Conversation

@dependabot

@dependabot dependabot Bot commented on behalf of github Nov 23, 2026 •

Copy link
Copy Markdown
Contributor

Bumps the go-patch group with 1 update in the /backend directory: github.com/labstack/echo/v5.

Updates github.com/labstack/echo/v5 from 5.4.6 to 5.4.7

Release notes

Sourced from github.com/labstack/echo/v5's releases.

v5.4.7

Security

  • Proxy middleware: after routing, a . or .. path segment (also encoded as %2e) was resolved by Rewrite/RegexRewrite or by the upstream into a path the router never matched. GET /api/x/../admin/users matched an unprotected /api/* proxy group but reached the upstream as /admin/users, skipping middleware such as authentication on /api/admin. After routing, Proxy now returns 400 Bad Request for such paths, and rewrite targets in Proxy and the Rewrite middleware are applied literally instead of being resolved; a target with a dot segment or a leading // is rejected. Fixes GHSA-w5j2-g3fc-pwr6. Reported by AndyAnh174.
  • Static files: Static, StaticFS, Group.Static and Group.StaticFS with a prefix without a trailing slash registered prefix*, so /assetsadmin/private.txt was served from <root>/admin/private.txt for e.Static("/assets", root), bypassing a guard on /assets/admin. They now register prefix/*, plus prefix for the redirect to prefix/. Fixes GHSA-76qj-xf66-r429. Reported by AndyAnh174.
  • Static middleware on a group: documented that middleware.Static attached with Group#Use is not protected by guards on routes inside the group or on nested groups, and that Group#Static should be used for files behind such guards. See GHSA-5hp7-4fcm-57f9. Reported by AndyAnh174.

Fixes

  • Map binding: binding path, query, header or form data into a map whose value type is not string, []string or any returns an error instead of skipping the values, and named string types no longer panic. Fixes #3235 in #3238.
  • Gzip middleware: Accept-Encoding quality values are honored (gzip;q=0 refuses gzip, x-gzip is accepted, substrings such as notgzip no longer match), and responses that already have a Content-Encoding, for example from a reverse proxy, are passed through instead of compressed twice. Also fixes Write reporting more bytes than given at the MinLength threshold, a truncated stream when a handler only flushes, and stale Content-Length and Content-Encoding headers. Fixes #3232 and #2788 in #3239.
  • Response: Flush commits an uncommitted response, WriteHeader passes 1xx informational codes (such as 103 Early Hints) through without committing, and the built-in error handlers remove Content-Encoding, Content-Length and Content-Disposition before writing the error body. Fixes #3240, #3241 and #3242 in #3243.

Behavior changes

  • After routing, Proxy rejects paths with ./.. segments, and a Rewrite middleware attached after routing (on Echo#Use, a group or a route) applies its targets literally: relative targets and absolute URLs are rejected. Echo#Pre is unchanged.
  • Static and StaticFS return the RouteInfo of prefix/* instead of prefix*, and file names that only start with the prefix (for example /img-logo.png for e.Static("/img-", dir)) are no longer served.
  • Binding into an unsupported map type returns 400 Bad Request.
  • A handler that sets Content-Encoding itself is assumed to have encoded the body; the Gzip middleware no longer compresses it.
  • Custom HTTPErrorHandlers still need to clear stale Content-Encoding, Content-Length and Content-Disposition themselves.

No dependency or minimum Go-version changes.

Changelog

Sourced from github.com/labstack/echo/v5's changelog.

v5.4.7 - 2026-11-20

Security

  • Proxy middleware: after routing, a . or .. path segment (also encoded as %2e) was resolved by Rewrite/RegexRewrite or by the upstream into a path the router never matched. GET /api/x/../admin/users matched an unprotected /api/* proxy group but reached the upstream as /admin/users, skipping middleware such as authentication on /api/admin. After routing, Proxy now returns 400 Bad Request for such paths, and rewrite targets in Proxy and the Rewrite middleware are applied literally instead of being resolved; a target with a dot segment or a leading // is rejected. Fixes GHSA-w5j2-g3fc-pwr6. Reported by AndyAnh174.
  • Static files: Static, StaticFS, Group.Static and Group.StaticFS with a prefix without a trailing slash registered prefix*, so /assetsadmin/private.txt was served from <root>/admin/private.txt for e.Static("/assets", root), bypassing a guard on /assets/admin. They now register prefix/*, plus prefix for the redirect to prefix/. Fixes GHSA-76qj-xf66-r429. Reported by AndyAnh174.
  • Static middleware on a group: documented that middleware.Static attached with Group#Use is not protected by guards on routes inside the group or on nested groups, and that Group#Static should be used for files behind such guards. See GHSA-5hp7-4fcm-57f9. Reported by AndyAnh174.

Fixes

  • Map binding: binding path, query, header or form data into a map whose value type is not string, []string or any returns an error instead of skipping the values, and named string types no longer panic. Fixes #3235 in #3238.
  • Gzip middleware: Accept-Encoding quality values are honored (gzip;q=0 refuses gzip, x-gzip is accepted, substrings such as notgzip no longer match), and responses that already have a Content-Encoding, for example from a reverse proxy, are passed through instead of compressed twice. Also fixes Write reporting more bytes than given at the MinLength threshold, a truncated stream when a handler only flushes, and stale Content-Length and Content-Encoding headers. Fixes #3232 and #2788 in #3239.
  • Response: Flush commits an uncommitted response, WriteHeader passes 1xx informational codes (such as 103 Early Hints) through without committing, and the built-in error handlers remove Content-Encoding, Content-Length and Content-Disposition before writing the error body. Fixes #3240, #3241 and #3242 in #3243.

Behavior changes

  • After routing, Proxy rejects paths with ./.. segments, and a Rewrite middleware attached after routing (on Echo#Use, a group or a route) applies its targets literally: relative targets and absolute URLs are rejected. Echo#Pre is unchanged.
  • Static and StaticFS return the RouteInfo of prefix/* instead of prefix*, and file names that only start with the prefix (for example /img-logo.png for e.Static("/img-", dir)) are no longer served.
  • Binding into an unsupported map type returns 400 Bad Request.
  • A handler that sets Content-Encoding itself is assumed to have encoded the body; the Gzip middleware no longer compresses it.
  • Custom HTTPErrorHandlers still need to clear stale Content-Encoding, Content-Length and Content-Disposition themselves.

No dependency or minimum Go-version changes.

Commits
  • 59aacdd Merge commit from fork
  • fb1d59d fix: commit response on Flush, pass through 1xx, and clear stale error header...
  • 390f278 fix(middleware): honor Accept-Encoding q-values and preserve encoded response...
  • fbd734f fix(bind): reject unsupported map value types (#3235) (#3238)
  • See full diff in compare view

@dependabot dependabot Bot added dependencies Pull requests that update a dependency file go Pull requests that update go code labels Nov 23, 2026

@lin594 lin594 left a comment

Copy link
Copy Markdown
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

🤖 说明:以下内容由 OpenAI Codex 独立完成并自动提交,代表 Codex 的代码审查意见,不是 lin594 本人人工书写。

Verdict: Approve.

Echo v5.4.6→v5.4.7 是同主版本安全补丁,仅改 go.mod/go.sum,两条校验记录同步。仓库直接调用的客户端 IP 提取 API 不变;已核上游说明,本 PR 不证明旧版在生产存在可用漏洞,也不等于环境已升级。

核验:隔离检出精确 head,git diff --check 通过。62 项 CI 通过,含 Go 竞态、静态检查、核心流程和 PDF 访问。本地 Go 1.27.2 低于仓库 1.27.4,未运行到定向断言;未做生产测试。

@dependabot dependabot Bot changed the title build(deps): bump github.com/labstack/echo/v5 from 5.4.6 to 5.4.7 in /backend in the go-patch group build(deps): bump github.com/labstack/echo/v5 from 5.4.6 to 5.4.7 in /backend in the go-patch group across 1 directory Nov 24, 2026
@dependabot
dependabot Bot force-pushed the dependabot/go_modules/backend/go-patch-746bbe60e9 branch 2 times, most recently from 0560ce9 to 9f865a8 Compare November 26, 2026 20:24
Bumps the go-patch group with 1 update in the /backend directory: [github.com/labstack/echo/v5](https://github.com/labstack/echo).


Updates `github.com/labstack/echo/v5` from 5.4.6 to 5.4.7
- [Release notes](https://github.com/labstack/echo/releases)
- [Changelog](https://github.com/labstack/echo/blob/master/CHANGELOG.md)
- [Commits](labstack/echo@v5.4.6...v5.4.7)

---
updated-dependencies:
- dependency-name: github.com/labstack/echo/v5
  dependency-version: 5.4.7
  dependency-type: direct:production
  update-type: version-update:semver-patch
  dependency-group: go-patch
...

Signed-off-by: dependabot[bot] <support@github.com>
@dependabot
dependabot Bot force-pushed the dependabot/go_modules/backend/go-patch-746bbe60e9 branch from 9f865a8 to 0900a89 Compare November 29, 2026 20:23
@L8848-Li
L8848-Li added this pull request to the merge queue Nov 30, 2026
Merged via the queue into main with commit 8558377 Nov 30, 2026
64 checks passed
@dependabot
dependabot Bot deleted the dependabot/go_modules/backend/go-patch-746bbe60e9 branch November 30, 2026 00:43
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

dependencies Pull requests that update a dependency file go Pull requests that update go code

Projects

None yet

Development

Successfully merging this pull request may close these issues.

2 participants