CVE-2026-22814
JavaScript vulnerability analysis and mitigation

Overview

CVE-2026-22814 is a Mass Assignment vulnerability in @adonisjs/lucid, the SQL ORM for the AdonisJS framework built on top of Knex. It allows a remote attacker who can influence data passed into Lucid model assignments to overwrite internal ORM state properties, potentially leading to logic bypasses and unauthorized database record modification. The vulnerability affects @adonisjs/lucid versions up to and including 21.8.1, and 22.x pre-release versions from 22.0.0-next.0 through 22.0.0-next.5. It was disclosed on January 13, 2026, by RomainLanz via the GitHub Security Advisory GHSA-g5gc-h5hp-555f, with credit to reporter wodzen. The CVSS v4.0 base score is 8.2 (High) (Github Advisory, AdonisJS Advisory).

Technical details

The root cause is classified as CWE-915 (Improperly Controlled Modification of Dynamically-Determined Object Attributes). The vulnerability exists in the BaseModelImpl class, which uses a this.hasOwnProperty(key) check to determine valid assignment targets. Because internal ORM state properties ($isPersisted, $attributes, $original, $isDeleted) are initialized as instance properties, they pass this check — allowing attacker-controlled input to overwrite them. The flaw propagates across the entire write surface of the library, including instance methods fill and merge, creation methods create, createQuietly, firstOrNew, firstOrCreate, updateOrCreate, and bulk operations such as createMany and updateOrCreateMany. Applications are vulnerable when they pass unvalidated or loosely validated data (e.g., via request.all(), request.except(), or schemas with allowUnknownProperties) directly to model methods (AdonisJS Advisory, Github Advisory).

Impact

Successful exploitation allows an unauthenticated remote attacker to manipulate the ORM's internal state, enabling unauthorized modification of database records. By injecting "$isPersisted": true into a payload, an attacker can force save() to execute an UPDATE operation instead of an INSERT, effectively modifying existing records rather than creating new ones. Additionally, injecting into $attributes can bypass field-level validators and restrictions, allowing unauthorized data to be persisted to the database. There is no confidentiality or availability impact, but the integrity impact is high, with potential for data tampering and database state manipulation across any table or model exposed through a vulnerable endpoint (AdonisJS Advisory, Feedly).

Exploitability

No public proof-of-concept exploit code is known to exist, and there is no evidence of in-the-wild exploitation at this time. The EPSS score is approximately 0.037% (11th percentile), indicating a low near-term exploitation probability. The vulnerability is not listed in the CISA Known Exploited Vulnerabilities (KEV) catalog. Exploitation requires that the target application passes unvalidated or insufficiently validated user input directly to Lucid model methods, which is a prerequisite (Attack Requirements: Present in CVSS v4.0) (Github Advisory, Feedly).

Exploitation steps

  1. Reconnaissance: Identify web applications built on AdonisJS that use @adonisjs/lucid versions ≤ 21.8.1 or 22.0.0-next.0 through 22.0.0-next.5. Look for endpoints that accept user-supplied JSON or form data and pass it to model creation or update operations.
  2. Identify vulnerable endpoint: Find an API route or form handler that calls Model.create(), model.merge(), model.fill(), or similar methods using request.all() or request.except() without strict allow-list validation.
  3. Craft malicious payload: Construct a JSON payload that includes internal ORM property keys alongside normal fields. For example, to convert an INSERT into an UPDATE: { "name": "attacker", "$isPersisted": true, "$attributes": { "role": "admin" } }.
  4. Submit the payload: Send the crafted payload to the vulnerable endpoint via an HTTP POST or PUT request.
  5. Achieve unauthorized record modification: The hasOwnProperty check in BaseModelImpl passes for $isPersisted and $attributes since they are instance properties. The ORM executes an UPDATE instead of INSERT, or persists attacker-controlled attribute values that bypass field validators, resulting in unauthorized database record modification (AdonisJS Advisory).

Indicators of compromise

  • Network: HTTP POST/PUT requests to model-creation or update endpoints containing JSON keys prefixed with $ (e.g., $isPersisted, $attributes, $isDeleted, $original) in the request body.
  • Logs: Application logs showing unexpected UPDATE database operations on records that should have been newly created (INSERT); anomalous changes to records with no corresponding user-initiated update action.
  • Application Behavior: Database records with unexpected field values (e.g., elevated roles or permissions) that do not correspond to legitimate user input; records modified at timestamps inconsistent with user activity.
  • Database: Audit logs showing UPDATE statements on rows where only INSERT was expected, particularly for user registration, profile creation, or similar flows.

Mitigation and workarounds

Upgrade @adonisjs/lucid to version 21.8.2 (stable) or 22.0.0-next.6 (pre-release) or later, which contain the official patch (AdonisJS Advisory). As an immediate workaround, implement strict allow-list validation for all user input before passing it to ORM methods — explicitly discard unknown properties and avoid passing request.all() or request.except() directly to Model.create() or similar methods. Use schema validation with allowUnknownProperties set to false to ensure internal ORM keys cannot be injected by user-controlled data.

Community reactions

The advisory was published by AdonisJS maintainer RomainLanz on January 13, 2026, and credited to security researcher wodzen. Coverage has been limited to vulnerability aggregation platforms such as Vulners, CVEFeed, and INCIBE-CERT, with no significant broader media or social media discussion identified (AdonisJS Advisory).

Additional resources


SourceThis report was generated using AI

Related JavaScript vulnerabilities:

CVE ID

Severity

Score

Technologies

Component name

CISA KEV exploit

Has fix

Published date

CVE-2026-88062CRITICAL9.5
  • JavaScript logoJavaScript
  • omniroute
NoNoSep 10, 2026
CVE-2026-61534CRITICAL9.1
  • JavaScript logoJavaScript
  • yayson
NoYesSep 11, 2026
CVE-2026-59973HIGH8.5
  • JavaScript logoJavaScript
  • @frontmcp/adapters
NoYesSep 11, 2026
CVE-2026-59960HIGH7.5
  • JavaScript logoJavaScript
  • @argos-ci/core
NoYesSep 10, 2026
CVE-2026-59965HIGH7.1
  • JavaScript logoJavaScript
  • @jhb.software/payload-alt-text-plugin
NoNoSep 10, 2026

Free Vulnerability Assessment

Benchmark your Cloud Security Posture

Evaluate your cloud security practices across 9 security domains to benchmark your risk level and identify gaps in your defenses.

Request assessment

Get a personalized demo

Ready to see Wiz in action?

"Best User Experience I have ever seen, provides full visibility to cloud workloads."
David EstlickCISO
"Wiz provides a single pane of glass to see what is going on in our cloud environments."
Adam FletcherChief Security Officer
"We know that if Wiz identifies something as critical, it actually is."
Greg PoniatowskiHead of Threat and Vulnerability Management