OpenAIHonoJun 23, 2026, 2:51 AM

v4.12.27

A condensed section focused on the key takeaways first.

Original Post

Quick Digest

Summary

A condensed section focused on the key takeaways first.

openaienmodel: gpt-5-mini-2025-08-07

v4.12.27 — security fixes

Key Points

  • SSR cross-request context disclosure
  • Server-side JSX XSS via cx()
  • API Gateway v1 header value drop

Summary

Release v4.12.27 (2026-06-23) fixes three security issues across hono packages. Users of hono/jsx, hono/jsx-renderer, hono/css (cx()), and hono/aws-lambda API Gateway v1 / VPC Lattice adapters should upgrade immediately.

Key Points

  • SSR context leak (hono/jsx, hono/jsx-renderer) — Context was stored process-wide instead of per-request, so useContext()/useRequestContext() called after an await in async components could return another concurrent request's value, enabling cross-request data disclosure or incorrect authorization. (GHSA-hvrm-45r6-mjfj)
  • Server-side XSS via cx() (hono/css) — cx() treated composed class names as pre-escaped and did not escape input, allowing untrusted class name input to break out of a JSX class attribute during SSR and inject markup. (GHSA-w62v-xxxg-mg59)
  • API Gateway v1 / VPC Lattice header deduplication (hono/aws-lambda) — The adapter de-duplicated repeated header values by substring instead of exact match, dropping values that were substrings of others (e.g. affecting X-Forwarded-For) which can break IP-based logic. (GHSA-xgm2-5f3f-mvvc)

Recommended Actions

  • Upgrade to v4.12.27 immediately.
  • Audit server-side code that: uses async JSX components with useRequestContext/useContext; passes untrusted strings to cx()/class name utilities; relies on repeated header values (e.g. X-Forwarded-For).
  • As a temporary mitigation: avoid using untrusted input directly as class names, validate/sanitize header parsing logic, and add logging around auth/authorization decisions affected by request context or headers.

Notes for Engineers

  • These are security fixes; treat as high priority for production environments that perform SSR, use custom class name inputs, or run on API Gateway v1 / VPC Lattice.
  • Refer to the GHSA advisories listed above for CVE/GHSA tracking and upgrade guidance.

Full Translation

Translations

A translation section that keeps the flow of the original article.

openaijamodel: gpt-5-mini-2025-08-07

v4.12.27

v4.12.27

  • 公開日: 2026-06-23T02:51:19.000Z
  • リリース: yusukebe
  • コミット: 97c6fe1

概要

このリリースには以下のセキュリティ修正が含まれます。該当パッケージを利用しているユーザーはアップグレードを推奨します。

セキュリティ修正

  • hono/jsx がリクエストごとにコンテキストを分離していない

    • 影響: hono/jsx, hono/jsx-renderer
    • 説明: SSR 中にコンテキストがプロセス全体で保持され、リクエスト単位で分離されていませんでした。その結果、useContext() / useRequestContext()await の後に別の並行リクエストの値を返す可能性があり、クロスリクエストのデータ漏洩や誤ったリクエストに対する認可チェックにつながる恐れがありました。
    • 脆弱性ID: GHSA-hvrm-45r6-mjfj
  • Server-Side XSS: JSX のエスケープを迂回する cx() による脆弱性

    • 影響: hono/css
    • 説明: cx() が合成したクラス名を既にエスケープ済みとマークし、入力を適切にエスケープしていませんでした。そのため、信頼できない入力をクラス名として渡すと、SSR 中に JSX の class 属性を破ってマークアップを注入(XSS)される可能性がありました。
    • 脆弱性ID: GHSA-w62v-xxxg-mg59
  • API Gateway v1 アダプターが繰り返しヘッダー値を落とす可能性

    • 影響: hono/aws-lambda
    • 説明: API Gateway v1(および VPC Lattice)アダプターが繰り返しヘッダー値を部分文字列で重複除去しており、ある値が別の値の部分文字列である場合にその値を削除してしまっていました。例: 203.0.113.1203.0.113.10 の存在時に削除される、これにより X-Forwarded-For に基づく IP 制限などのロジックに影響を与えます。
    • 脆弱性ID: GHSA-xgm2-5f3f-mvvc

推奨

hono/jsx / hono/jsx-rendererhono/csscx())、および hono/aws-lambda の API Gateway v1 / VPC Lattice アダプターを使用しているユーザーは、速やかにアップグレードしてください。

補足

  • アセット: 2
  • リアクション: ❤️ 1件(sant123)、🚀 1件(sant123)