Skip to main content
VulnerabilityPublished

CVE-2026-27953: ormar · Mass Assignment

Affects ormarSource CVE Database V5

0
Compare

Not known to be exploited · CVSS 7.1 High : upgrade to 0.23.1 soon.

Data as of 31 Oct 2026, 08:20 UTC

CVSS 3.1 base score
7.1High
How severe the flaw is on the 0–10 CVSS scale.
EPSS
1.2% chance of exploitation in 30 days – higher than 68% of CVEsExploit Prediction Scoring System: the likelihood attackers will use this flaw soon.
Patch
Available – fixed in 0.23.1
CVSS:3.1/AV:N/AC:L/PR:L/UI:N/S:U/C:N/I:H/A:L

Exploitation evidence

  1. Disclosed: evidence found.

    CVE published 19 Mar 2026

  2. Detectable: no evidence on record.

    No public nuclei template indexed

  3. Weaponized: no evidence on record.

    No public exploit code indexed in Metasploit or Exploit-DB

  4. Exploited in the wild: no evidence on record.

    Not in CISA KEV and no source reports exploitation

  5. Observed by OffSeq Mirage: no evidence on record.

    No attack traffic recorded by OffSeq Mirage sensors

A missing step is not evidence of safety. Sources: cve.org (opens in a new tab), the Metasploit, Exploit-DB and nuclei-templates index as of 30 Oct 2026.

What to do

Upgrade ormar to 0.23.1.

Affected software

ProductAffectedFixed in
ormar-ormormarAffected
  • <0.23.1
Fixed in
  • 0.23.1
PyPIormarpkg:pypi/ormarOther threatsAffected
  • <0.23.1
Fixed in
  • 0.23.1

Check your own hosts for these packages with threat-finder (opens in a new tab), our free open-source scanner.

AI-suggested

  1. Immediate upgrade of ormar to version 0.23.1 or later to apply the official patch that fixes the validation bypass.
  2. Review and audit all FastAPI endpoints that use ormar.Model as a request body parameter to ensure no unvalidated or dynamic attributes can be injected.
  3. Implement additional server-side validation layers independent of ormar's model validation to detect and reject unexpected parameters like "__pk_only__" or "__excluded__".
  4. Employ strict input sanitization and schema validation at the API gateway or middleware level to prevent injection of special control parameters.
  5. Monitor application logs for suspicious requests containing these special parameters or anomalous data modifications.
  6. Conduct penetration testing focusing on model validation bypass attempts to verify the effectiveness of mitigations.
  7. Educate development teams about the risks of relying solely on ORM-level validation and encourage defense-in-depth strategies.
  8. If upgrading immediately is not feasible, consider temporarily disabling ormar.Model direct usage as request bodies and replace with explicit Pydantic schemas that do not allow dynamic attribute injection.

Description

CVE-2026-27953 is a high-severity vulnerability in ormar, an async mini ORM for Python, affecting versions below 0.23.1. It allows unauthenticated attackers to bypass Pydantic model validation by injecting the "__pk_only__": true parameter in JSON request bodies, enabling direct persistence of unvalidated data to the database. A secondary injection parameter "__excluded__" can nullify arbitrary model fields, facilitating privilege escalation, data integrity violations, and business logic bypass. This vulnerability impacts applications using ormar. Model directly as a request body parameter, especially in FastAPI integrations following ormar's official documentation. The issue has been fixed in version 0.23.1.

References

Community reviews

Loading reviews…