Read the docs
TI-2026-22297 Aliases CVE-2026-27953GHSA-f964-whrq-44h8

ormar has a Pydantic Validation Bypass via Kwargs Injection in Model Constructor

Priority HIGH 75CWE-20Published · Updated

Key facts

Attack vector
Network
Privileges required
None
User interaction
None
Attack complexity
Low
Impact type
Tampering
Confidentiality · integrity · availability
High · High · High
Fix status
Fixed

Attack profile from CVSS 3.1 · NVD. Fix status from CNA and GitHub. Impact type from CWE-915.

Summary

ormar is a async mini ORM for Python. Versions 0.23.0 and below are vulnerable to Pydantic validation bypass through the model constructor, allowing any unauthenticated user to skip all field validation by injecting "__pk_only__": true into a JSON request body. By injecting "__pk_only__": true into a JSON request body, an unauthenticated attacker can skip all field validation and persist unvalidated data directly to the database. A secondary __excluded__ parameter injection uses the same pattern to selectively nullify arbitrary model fields (e.g., email or role) during construction. This affects ormar's canonical FastAPI integration pattern recommended in its official documentation, enabling privilege escalation, data integrity violations, and business logic bypass in any application using ormar.Model directly as a request body parameter. This issue has been fixed in version 0.23.1.

Why it matters now

Exploitation Proof of concept CISA SSVC · not in CISA KEV
EPSS 0.01238 69th percentileScored 2026-11-07
Public exploit Yes 1 exploit referenceTagged by NVD
Fix Fixed ormar (ormar-orm): 0.23.1ormar (PyPI): 0.23.1

SSVC decision points

CISA ADP · SSVC 2.0.3

Exploitation
Poc
Automatable
No
Technical impact
Partial

The decision (Track, Attend, Act) also depends on your mission and well-being impact; see CISA's SSVC guide.

Affected products

VendorProductAffected versionsFixed inStatusSource
ormar-ormormarbefore 0.23.10.23.1Patch availableCNA
—ormar (PyPI)before 0.23.10.23.1Patch availableGHSA-f964-whrq-44h8
  • ormar Vendorormar-orm Affected before 0.23.1 Fixed in 0.23.1 Patch available CNA
  • ormar (PyPI) Vendor— Affected before 0.23.1 Fixed in 0.23.1 Patch available GHSA-f964-whrq-44h8

CPE configurations NVD · 1

CPEVersionsRoleVendor
cpe:2.3:a:collerek:ormar:*:*:*:*:*:python:*:*before 0.23.1Vulnerablecollerek
  • cpe:2.3:a:collerek:ormar:*:*:*:*:*:python:*:* Versions before 0.23.1 Vulnerable ·collerek

Remediation

  • Fix · CNA ormar (ormar-orm) Fixed in 0.23.1
  • Fix · GHSA-f964-whrq-44h8 ormar (PyPI) Fixed in 0.23.1 Advisory →

Timeline

  1. 2026-10-02 Threatist record created from CVE-2026-27953
  2. 2026-10-03 Alias added: GHSA-f964-whrq-44h8

References

  • TI-2026-21189 ormar is vulnerable to SQL Injection through aggregate functions min() and max() CVSS 3.1CRITICAL 9.8

Sources