CVE-2024-7348
PostgreSQL relation replacement during pg_dump executes arbitrary SQL
Time-of-check Time-of-use (TOCTOU) race condition in pg_dump in PostgreSQL allows an object creator to execute arbitrary SQL functions as the user running pg_dump, which is often a superuser. The attack involves replacing another relation type with a view or foreign table. The attack requires waiting for pg_dump to start, but winning the race condition is trivial if the attacker retains an open transaction. Versions before PostgreSQL 16.4, 15.8, 14.13, 13.16, and 12.20 are affected.
Exposure status: unknown. This page does not establish whether an installed system is affected or corrected.
Severity and exploitation evidence
EPSS: 1.565% · score date 2026-11-19. EPSS is an estimated probability over the next 30 days, not proof of exploitation.
CISA KEV: not included in the checked catalog; exploitation may still occur. Last checked: 2026-11-19T16:25:55.090Z. Public exploit availability is not used to set this status.
CVSS 3.1 · 8.8 · published by PostgreSQLCVSS:3.1/AV:N/AC:L/PR:L/UI:N/S:U/C:H/I:H/A:H
Assessment source · checked 2026-11-19T12:57:22.360Z
Verification by field
| Field | Status | Checked at (UTC) | Source |
|---|---|---|---|
| kev | verified | 2026-11-19T16:25:55.090Z | CISA KEV |
| cvss | verified | 2026-11-19T12:57:22.360Z | CVE Program |
| epss | verified | 2026-11-19T16:04:39.514Z | FIRST EPSS |
| patches | verified | 2026-11-19T12:52:05.592Z | OSV |
| affected | verified | 2026-11-19T12:57:22.360Z | CVE Program |
| lifecycle | verified | 2026-11-19T12:57:22.360Z | CVE Program |
Affected versions and configuration
n/a PostgreSQL; default status: unaffected: 16 to < 16.4 [affected; scheme: rpm]; 15 to < 15.8 [affected; scheme: rpm]; 14 to < 14.13 [affected; scheme: rpm]; 13 to < 13.16 [affected; scheme: rpm]; 0 to < 12.20 [affected; scheme: rpm]
Defaults, conditional configuration, package status and version schemes are retained below. A version range alone is not an exposure verdict.
CVE Program · cve-json · full conditions
{
"affected": [
{
"vendor": "n/a",
"product": "PostgreSQL",
"versions": [
{
"status": "affected",
"version": "16",
"lessThan": "16.4",
"versionType": "rpm"
},
{
"status": "affected",
"version": "15",
"lessThan": "15.8",
"versionType": "rpm"
},
{
"status": "affected",
"version": "14",
"lessThan": "14.13",
"versionType": "rpm"
},
{
"status": "affected",
"version": "13",
"lessThan": "13.16",
"versionType": "rpm"
},
{
"status": "affected",
"version": "0",
"lessThan": "12.20",
"versionType": "rpm"
}
],
"defaultStatus": "unaffected"
}
],
"additionalContainers": [
{
"title": "CISA ADP Vulnrichment",
"metrics": [
{
"other": {
"type": "ssvc",
"content": {
"id": "CVE-2024-7348",
"role": "CISA Coordinator",
"options": [
{
"Exploitation": "none"
},
{
"Automatable": "no"
},
{
"Technical Impact": "total"
}
],
"version": "2.0.3",
"timestamp": "2024-08-15T00:00:00+00:00"
}
}
}
],
"affected": [
{
"cpes": [
"cpe:2.3:a:postgresql:postgresql:*:*:*:*:*:*:*:*"
],
"vendor": "postgresql",
"product": "postgresql",
"versions": [
{
"status": "affected",
"version": "0",
"lessThan": "12.20",
"versionType": "custom"
},
{
"status": "affected",
"version": "13",
"lessThan": "13.16",
"versionType": "custom"
},
{
"status": "affected",
"version": "14",
"lessThan": "14.13",
"versionType": "custom"
},
{
"status": "affected",
"version": "15",
"lessThan": "15.8",
"versionType": "custom"
},
{
"status": "affected",
"version": "16",
"lessThan": "16.4",
"versionType": "custom"
}
],
"defaultStatus": "unknown"
}
],
"providerMetadata": {
"orgId": "134c704f-9b21-4f2e-91b3-4a467353bcc0",
"shortName": "CISA-ADP",
"dateUpdated": "2024-08-16T04:01:38.124Z"
}
},
{
"title": "CVE Program Container",
"references": [
{
"url": "http://www.openwall.com/lists/oss-security/2024/08/11/1"
},
{
"url": "https://security.netapp.com/advisory/ntap-20240822-0002/"
}
],
"providerMetadata": {
"orgId": "af854a3a-2127-422b-91ae-364da2661108",
"shortName": "CVE",
"dateUpdated": "2024-08-22T18:03:18.699Z"
}
}
]
}Archived source JSONOSV · osv · full conditions
{
"id": "DEBIAN-CVE-2024-7348",
"aliases": [],
"affected": [
{
"ranges": [
{
"type": "ECOSYSTEM",
"events": [
{
"introduced": "0"
},
{
"fixed": "15.8-0+deb12u1"
}
]
}
],
"package": {
"name": "postgresql-15",
"purl": "pkg:deb/debian/postgresql-15?arch=source&distro=bookworm",
"ecosystem": "Debian:12"
},
"versions": [
"15.3-0+deb12u1",
"15.3-1",
"15.4-0+deb12u1",
"15.4-1",
"15.4-2",
"15.4-3",
"15.5-0+deb12u1",
"15.6-0+deb12u1",
"15.7-0+deb12u1"
],
"database_specific": {
"source": "https://storage.googleapis.com/debian-osv/debian-cve-osv/DEBIAN-CVE-2024-7348.json"
},
"ecosystem_specific": {
"urgency": "not yet assigned"
}
}
],
"severity": [
{
"type": "CVSS_V3",
"score": "CVSS:3.1/AV:N/AC:H/PR:L/UI:N/S:U/C:H/I:H/A:H"
}
],
"upstream": [
"CVE-2024-7348"
],
"withdrawn": null,
"references": [
{
"url": "https://security-tracker.debian.org/tracker/CVE-2024-7348",
"type": "ADVISORY"
}
],
"relatedGitRanges": [],
"database_specific": {}
}Archived source JSONCorrection evidence
Distribution packages and upstream releases are distinct. ESM channels may require the corresponding Ubuntu entitlement. Notes and branch ranges are not installable package versions. OSV fixed boundaries are ecosystem-specific version thresholds, not proof that a package is currently available or installed.
| Evidence type | Distribution / release | Package | Channel | Version or source note | Source |
|---|---|---|---|---|---|
| ecosystem-boundary | Debian:12 / 12 | postgresql-15 | unknown | 15.8-0+deb12u1 | Official record |
Vendor notices and operational guidance
No connected vendor notice is available for this record.
Original sources and dates
- OSVConsulted: 2026-11-19T12:52:05.592ZArchived source JSON
Source publication: 2024-08-08T13:15:14.007Z
Source modification: 2026-11-02T12:03:12.058ZDocument fingerprint
bc7377159fbe1883ea8a51101a0bcce2f458a18dc726dd446fd2fa90a886a417 - CVE ProgramConsulted: 2026-11-19T12:57:22.360ZArchived source JSON
Source publication: 2024-08-08T13:00:02.130Z
Source modification: 2024-08-22T18:03:18.699ZDocument fingerprint
dfa7c97abcb426387f3b20bfa728668ad749552f4178aeca7dcdfe13f19089b8 - CISA KEVConsulted: 2026-11-19T16:25:55.090ZArchived source JSON
Source publication: not supplied
Source modification: 2026-11-18T19:17:41.0354ZDocument fingerprint
a35fdc67c7d9802988dcfc1d3ff1198da327948d1db122ab7692ac201055ac56 - FIRST EPSSConsulted: 2026-11-19T16:04:39.514ZArchived source JSON
Source publication: not supplied
Source modification: not suppliedDocument fingerprint
c07aa8e6fdfc310c84fe1ac9be92e31e56fc57bead56722404a3841425dfa449
Official status history
- UNKNOWN → PUBLISHED · · evidence