Skip to content

GHSA-hm8q-7f3q-5f36 CVE-2026-44459

Hono has improper validation of NumericDate claims (exp, nbf, iat) in JWT verify()

Low npm
Severity
3.8 / 10
Low · CVSS 3.1
Exploit chance (EPSS)
0.22%
Chance of exploitation in the next 30 days. Higher than 12.06% of scored vulnerabilities.
Known exploited
No
Not in CISA's catalog
Weakness
CWE-1284 Improper Validation of Specified Quantity in Input
Fix
4.12.18
Upgrade hono to this version or later

Description

Summary

Improper validation of the JWT NumericDate claims exp, nbf, and iat in hono/utils/jwt allows tokens with non-spec-compliant claim values to silently bypass time-based checks. This issue is not exploitable by an anonymous attacker; it only manifests when a malformed claim value reaches verify() — typically when the application itself issues such tokens, or when the signing key is otherwise under attacker control.

Details

The validation routine combined option, presence, and threshold checks in a single short-circuiting expression, so several classes of malformed values were silently skipped instead of rejected:

  • A falsy numeric value short-circuited the presence check.
  • A non-finite numeric value compared as never-after-now and never-expired.
  • A non-numeric type produced NaN comparisons that evaluated false.

This deviates from RFC 7519 §4.1.4, which defines NumericDate as a finite JSON numeric value.

Impact

An actor able to issue tokens accepted by the application may craft tokens whose exp, nbf, or iat claims silently bypass time-based enforcement. This may lead to:

  • Tokens treated as never expiring even with exp configured on the verifier.
  • Tokens with a future nbf accepted as currently valid.
  • Tokens with a future iat accepted as legitimately issued.

Deployments using a well-formed token issuer and protecting the signing key are not affected.

Affected versions

npm

PackageVulnerableFixed in
hono
< 4.12.18
4.12.18

How to fix

Move to the fixed version or later with your package manager, update the lockfile, and run your tests. If the package only arrives through another dependency, upgrade that dependency first. If none of its releases pulls a fixed version yet, force the version with your package manager's override.

hono npm → 4.12.18

npm
npm install hono@4.12.18
yarn
yarn add hono@4.12.18
pnpm
pnpm add hono@4.12.18

Severity breakdown

CVSS 3.1 3.8

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

Attack vector
Network
Attack complexity
Low
Privileges required
High
User interaction
None
Scope
Unchanged
Confidentiality
Low
Integrity
Low
Availability
None

Weakness

CWE-1284: Improper Validation of Specified Quantity in Input

The product receives input that is expected to specify a quantity (such as size or length), but it does not validate or incorrectly validates that the quantity has the required properties.

How to prevent it
  • Implementation: Assume all input is malicious. Use an "accept known good" input validation strategy, i.e., use a list of acceptable inputs that strictly conform to specifications. Reject any input that does not strictly conform to specifications, or transform it into something that does. When performing input validation, consider all potentially relevant properties, including length, type of input, the full range of acceptable values, missing or extra inputs, syntax, consistency across related fields, and conformance to business rules. As an example of business rule logic, "boat" may be syntactically valid because it only contains alphanumeric characters, but it is not valid if the input is only expected to contain colors such as "red" or "blue." Do not rely exclusively on looking for malicious or malformed inputs. This is likely to miss at least one undesirable input, especially if the code's environment changes. This can give attackers enough room to bypass the intended validation. However, denylists can be useful for detecting potential attacks or determining which inputs are so malformed that they should be rejected outright.

References

Timeline

  1. Published
  2. Last updated by the source
  3. Latest EPSS score
AdvisorySeverityWhy it's related
GHSA-5r4p-p66f-jhc7
Hono: `serveStatic` decodes the request path a second time, leading to bypass of middleware on static paths
Medium Also affects hono
GHSA-hxh3-vqpv-xpqv
hono/jsx renders plain strings unescaped in boundary components, leading to XSS
Low Also affects hono
GHSA-gqvv-2mrq-wpjv
Hono: Incomplete fix for CVE-2026-39408: `toSSG()` still writes files outside the output directory
Medium Also affects hono
GHSA-g6gw-c38x-mqfc
Hono: Unbounded dot-notation nesting in `parseBody()` can cause memory exhaustion
Medium Also affects hono
GHSA-crvj-82cr-hjcx
Hono: Query parser reads parameters after the URL fragment, causing cache-key and proxy interpretation differentials
Medium Also affects hono
GHSA-f23p-vx2j-j53r
Hono: `memo()` retains SSR output across requests, leading to cross-user data disclosure
Medium Also affects hono
GHSA-79qm-7rj5-m7r9
Hono: Proxy Helper does not remove response headers listed in the `Connection` header
Low Also affects hono
GHSA-54fx-42gc-7vw4
Hono: Algorithmic Complexity DoS in Language Middleware
Medium Also affects hono
Is this in your code?

MergeHarbor checks every repository's dependencies against this database, ranks what matters by exploitability and reachability, routes it to the owning team and opens the fix pull request.

Check your repos with MergeHarbor