Skip to main content

Marten CVE-2026-75513

| EUVDEUVD-2026-81263 CRITICAL
SQL Injection (CWE-89)
2026-09-16 GitHub_M GHSA-rfx3-98h7-v3xp
9.1
CVSS 3.1 · Vendor: GitHub_M
View

Attack ChainAIDerived

Hypothetical attack flow derived from CVE metadata – not a confirmed exploit chain

  1. Access
    Authenticate to Marten-backed app
  2. Delivery
    Submit crafted dictionary key with single quote
  3. Exploit
    Break out of SQL literal, inject always-true predicate
  4. Execution
    Bypass filter and tenant isolation
  5. Impact
    Exfiltrate cross-tenant data (blind)

Vulnerability Assessment

Weakness
CWE
OWASP Top 10:2025
A05:2025 - Injection
ASVS 5.0
V1 - Encoding and Sanitization Parameterized queries, prepared statements
MITRE ATT&CK

2 techniques across 2 tactics: Initial Access, Persistence

The technique list with ATT&CK links and the kill-chain view is part of the Basic plan and up.

Exploitation Conditions

Exploitation requires the host application to pass attacker-controlled strings into one of the affected Marten paths: the primary confirmed vector is a dictionary indexer key used in Where filters (DictionaryItemMember.cs); Dictionary.ContainsKey is exploitable ONLY when the Newtonsoft serializer is configured (System.Text.Json is not affected); and tenant identifiers reaching DeleteAllForTenant.cs via IEventStore.DeleteProjectionProgressAsync. Limiting factors: the vulnerable strings must be reachable from untrusted input (a library/application-integration prerequisite), the CVSS PR:L implies an authenticated context, and DATA MODIFICATION (beyond read/authorization bypass) is possible only on deployments that permit semicolon-batched Npgsql statements - a non-default multi-statement configuration. Read-based filter/multi-tenant authorization bypass and blind exfiltration do not require the batched-statement setting.

Impact

This is a genuine high-priority SQL injection (CWE-89) in Marten, confirmed by the vendor's own GitHub Security Advisory (GHSA-rfx3-98h7-v3xp) and fixed in 9.13.0 via PR #4911 with dedicated regression tests. The CVSS 3.1 vector (AV:N/AC:L/PR:L/UI:N/S:C/C:H/I:L/A:L, 9.1) signals a network-reachable, low-complexity flaw whose scope-change (S:C) reflects cross-tenant authorization bypass - an attacker reading data belonging to other tenants, which is the most serious real-world consequence. Confidentiality is High while Integrity/Availability are Low because write/delete impact is conditional (only where semicolon-batched Npgsql statements are permitted, a non-default connection setting). No EPSS score, no CISA KEV listing, and no standalone public exploit were provided, so there is no evidence of active exploitation; however, the PR #4911 regression tests embed working attack payloads (e.g. "nonexistent' = '' or 1=1 --", "x' or '1'='1"), which materially lowers the barrier to weaponization. The one caveat is the PR:L rating: exploitability depends entirely on whether the host application routes attacker-controlled input into the affected LINQ dictionary-indexer/ContainsKey or tenant-management paths - a library-context prerequisite the CVSS vector cannot fully capture. Overall: a real priority for any multi-tenant Marten deployment, not an inflated-CVSS non-issue.

Exploit ScenarioDerived

An application uses Marten LINQ with a dictionary field and passes a user-supplied value as the dictionary indexer/ContainsKey key (e.g. filtering documents by an attribute the user selects). The attacker submits a key containing a single quote such as "nonexistent' = '' or 1=1 --", breaking out of the generated single-quoted JSON-path literal to inject an always-true predicate that bypasses the filter and any per-tenant restriction, enabling blind exfiltration of other tenants' documents. No public standalone exploit is listed, but the vendor's fix PR contains proof-of-concept attack strings.

Act Now Prioritize within 24-48h. Why: CRITICAL severity + public POC available.
Patch available 0.4% exploitation probability (EPSS)

Get an e-mail when this CVE is exploited, patched or re-scored. Free account.

Alert me

AnalysisAIv1 – Sep 16, 2026

SQL injection (CWE-89) in Marten, the .NET transactional document DB and event store for PostgreSQL, affects versions 7.0.0 through 9.12.x and lets an authenticated attacker who can influence strings reaching Marten's LINQ or tenant-management paths break out of single-quoted SQL/JSON-path literals and inject an always-true predicate, causing filter or multi-tenant authorization bypass and blind data exfiltration; on deployments that permit semicolon-batched Npgsql statements, data modification is also possible. The primary confirmed vector is a dictionary indexer key used in Where filters (src/Marten/Linq/Members/Dictionaries/DictionaryItemMember.cs); Dictionary.ContainsKey is exploitable only under the Newtonsoft serializer, tenant identifiers reaching DeleteAllForTenant.cs via IEventStore.DeleteProjectionProgressAsync are likewise affected, and EventLoader.cs contains a related defense-in-depth sink. The vendor confirmed the issue in GHSA-rfx3-98h7-v3xp and fixed it in version 9.13.0 via PR #4911; no public exploit code was identified at time of analysis, and exploitation requires the host application to route attacker-controlled strings into one of these Marten paths.

RemediationAI

Vendor-released patch: upgrade Marten to 9.13.0 (https://github.com/JasperFx/marten/releases/tag/9.13.0), which contains PR #4911 (commit 61882d0424854cb48703f08bdb246894ac576bed) parameterizing the tenant identifier and escaping single quotes in the affected JSON-path literals; no backport to 7.x/8.x is referenced in the available data, so plan an upgrade to the 9.13.0 line. If immediate upgrade is not possible, apply targeted compensating controls: audit every call site that places a user-supplied string into a Where dictionary indexer or ContainsKey call and reject or strip single quotes and JSON-path metacharacters before the value reaches Marten (trade-off: legitimate dictionary keys containing apostrophes will no longer match and may need a canonicalized storage format); switch to the System.Text.Json serializer so the ContainsKey sink is not reachable under Newtonsoft (trade-off: serializer behavior differences may change persisted document shape, so test migration paths); enforce identifier validation on every tenant id before it reaches IEventStore.DeleteProjectionProgressAsync/TeardownForTenant, matching the AssertValidPostgresqlIdentifiers rules that the teardown path bypasses (trade-off: tenant ids that do not conform must be remapped, and any id-validation bypass elsewhere reopens the sink); disable semicolon-batched, multi-statement Npgsql configuration so the data-modification branch is unreachable (trade-off: multi-statement command support must be replaced by individual statements); and run the Marten connection role with minimal privileges, denying broad DELETE/UPDATE on tenant document tables (trade-off: legitimate teardown and bulk-maintenance operations may require a separate, more privileged role). Regression tests added upstream confirm the injection is neutralized, and the advisory at https://github.com/JasperFx/marten/security/advisories/GHSA-rfx3-98h7-v3xp should be tracked for any further guidance.

Affected VersionsENISA

marten 7.0.0, < 9.13.0

Affected Packages

nuget marten fix: 9.13.0

Source: OSV (Open Source Vulnerabilities)

Affects your stack

Affects 1 package in nuget

Checking this CVE against your own stacks and servers is part of the Basic plan and up.

Technical ContextAI · show details

Marten generates PostgreSQL SQL from .NET LINQ expressions and from internal tenant-management operations, and several of those code paths historically concatenated runtime strings into single-quoted literals rather than binding them as parameters. The core root cause is CWE-89 (improper neutralization of special elements used in SQL commands): in DictionaryItemMember.cs, a dictionary indexer key used inside a Where filter is emitted into a JSON-path style literal such as '{...}' - for example a Where(x => x.Attributes[key] == "v") predicate - so a key containing a single quote terminates the literal early and lets an attacker append arbitrary predicate text, which is why the CVSS vector shows scope change (S:C) and high confidentiality impact while integrity/availability stay limited. DictionaryContainsKeyFilter.cs has the same weakness, but only when the Newtonsoft serializer is configured, because Newtonsoft's ToCleanJson output leaves a single quote unescaped whereas System.Text.Json does not. DatabaseScopedTenantPartitions.cs, DeleteAllForTenant.cs (reached through IEventStore.DeleteProjectionProgressAsync -> TeardownForTenant, where the tenant id is not guaranteed to have passed AssertValidPostgresqlIdentifiers) and EventLoader.cs' per-tenant partition-pruning literal round out the sink list, with EventLoader.cs flagged by the advisory as defense in depth. The fix in PR #4911/commit 61882d0424854cb48703f08bdb246894ac576bed converts the tenant id into a bound parameter (the regression test asserts the malicious value travels as cmd.Parameters[0] and never appears inline) and escapes embedded single quotes in the JSON-path literals, so the attacker-controlled value remains data instead of becoming SQL syntax.

Know when Marten gets its next vulnerability

  • Watch products and get an email when something new is published
  • Check this CVE against your own stack and servers
  • Exploit and PoC references, threat intelligence from 22 sources

No credit card · 7-day full trial

Severity by source

Vendor (GitHub_M) PRIMARY 9.1 CRITICAL
AV:N/AC:L/PR:L/UI:N/S:C/C:H/I:L/A:L
vuln.today AI 9.1 CRITICAL

Network-reachable, low-complexity injection needing app-level authenticated input (PR:L); S:C for cross-tenant boundary crossing; C:H exfiltration, I:L/A:L since write/delete is gated on non-default batched statements.

3.1 AV:N/AC:L/PR:L/UI:N/S:C/C:H/I:L/A:L
4.0 AV:N/AC:L/AT:N/PR:L/UI:N/VC:H/VI:L/VA:L/SC:L/SI:L/SA:N

Primary rating from Vendor (GitHub_M).

CVSS VectorVendor: GitHub_M

Attack Vector
Network
Attack Complexity
Low
Privileges Required
Low
User Interaction
None
Scope
Changed
Confidentiality
High
Integrity
Low
Availability
Low

Lifecycle Timeline

2
Patch available
Sep 16, 2026 - 22:04 EUVD
CVE Published
Sep 16, 2026 - 20:46 cve.org
CRITICAL 9.1

DescriptionCVE.org

Marten is a .NET Transactional Document DB and Event Store on PostgreSQL. From version 7.0.0 until 9.13.0, several Marten LINQ and tenant-management paths interpolate runtime, potentially attacker-controlled strings into single-quoted SQL literals without escaping or parameterization. The primary confirmed vector is a dictionary indexer key used by Where filters in src/Marten/Linq/Members/Dictionaries/DictionaryItemMember.cs. Additional affected sinks include SelectParser.cs, DatabaseScopedTenantPartitions.cs, and DeleteAllForTenant.cs reached through IEventStore.DeleteProjectionProgressAsync, while DictionaryContainsKeyFilter.cs (Newtonsoft serializer only; System.Text.Json is not affected) handles ContainsKey calls. Events/Daemon/Internals/EventLoader.cs contains a related per-tenant partition-pruning literal that the advisory identifies as a defense-in-depth sink. A crafted single quote can escape the generated literal, enabling filter or multi-tenant authorization bypass and blind data exfiltration, and deployments that permit semicolon-batched Npgsql statements may also allow data modification. This issue is fixed in version 9.13.0.

Technical POC Analysis

CWE-89 SQL injection.

Full technical POC analysis - root cause, step-by-step exploitation and patch breakdown - is part of the Pro and Business plans.

Executive ViewAI

Why It Matters

Marten, the .NET transactional document database and event store for PostgreSQL, contains a critical SQL injection vulnerability (CVE-2026-75513) affecting versions 7.0.0 through 9.12.x that enables multi-tenant authorization bypass and blind data exfiltration. Organizations using Marten to isolate tenant data could suffer cross-tenant data leakage and, where specific database configurations exist, unauthorized data modification, undermining customer trust and regulatory compliance. Leadership should prioritize immediate remediation because the flaw directly threatens the confidentiality and integrity of multi-tenant applications built on this platform.

Business Impact: Severe
Compensating Controls

Apply vendor patch.

Threat Intelligence Overview

EPSS Score
0.4%
Top 71% exploitable
Prevalence
Medium
popular .NET document-DB/event-store library for PostgreSQL, niche outside .NET
Threat Intel
1
1 source
Exploit
POC
Public exploit code exists
Social Media
2
Sightings
Data Quality
5 sources
Confidence: Medium

How this decision was reached

The engine reads each signal below and applies a fixed list of rules from top to bottom. The first rule that matches sets the recommended action – like a statement, every line is shown.

SignalValue
Severity CRITICAL
CISA KEV No
Public POC Yes
EPSS 0.4%
Patch available Yes
Active threat No
Deciding rule
CRITICAL severity + public POC available
What every action level means
Emergency Immediate action required. Criteria: CRITICAL + in CISA KEV (actively exploited) without patch, OR CRITICAL + EPSS > 30% without patch, OR CRITICAL + active threat signals without patch.
Act Now Prioritize within 24-48h. Criteria: in KEV with patch available, OR CRITICAL + public POC, OR HIGH + EPSS > 10%, OR CRITICAL + active threat, OR any CRITICAL severity.
This Week Schedule remediation this week. Criteria: HIGH severity (CVSS 7.0-8.9). Patch within normal change window.
This Month Plan within 30 days. Criteria: MEDIUM severity (CVSS 4.0-6.9), lower exploitation probability. Include in regular patch cycle.
Monitor Track and reassess. Criteria: LOW severity (CVSS 0.1-3.9), minimal exploitation risk. No immediate action needed.

SSVC AssessmentENISA

SSVC Decision· derived
Scheduled
Exploitation· derived
Poc
System Exposure· derived
Open
Automatable· derived
No
Human Impact
Very High

Priority Score

66
Low Medium High Critical
KEV: 0
EPSS: 0
CVSS: +46
PoC: +20
Weaponized: 0
Threat intel: 0
Gov advisory: 0

Attack Technique

SQL injection exploits the way applications construct database queries by mixing user input directly into SQL statements.

This site uses cookies essential for authentication and security. No tracking or analytics cookies are used. Privacy Policy