CVE-2026-61819: pg_partman - SQL Injection
- Cve: CVE-2026-61819
- Name: pg_partman - SQL Injection
- Description: pg_partman is a PostgreSQL extension that manages partitioned tables by time or ID. Prior to 5.5.0, when pg_jobmon is installed and part_config.jobmon is true, exception handlers in multiple pg_partman functions place p_parent_table verbatim inside a SQL string literal used to call pg_jobmon.add_job(). A partman_user can create a parent-table name containing a single quote that terminates the literal and injects SQL when an affected exception path runs. If pg_partman_bgw reaches that path, the injected SQL executes with pg_partman_bgw.role privileges, which default to PostgreSQL superuser, permitting database-wide compromise and operating-system command execution as the PostgreSQL service account. The persistent part_config row can trigger the escalation again on later maintenance ticks. This issue is fixed in version 5.5.0.
- Impact: An attacker can execute arbitrary SQL and OS commands with superuser privileges, leading to full database and system compromise.
- Remediation: Upgrade to version 5.5.0 or later.
- Vulnerability type: sql_injection
- Vulnerability impact: remote_code_execution, privilege_escalation
- Requirement type: logged_in
- Requirements: Attacker must have partman_user privileges to create crafted parent-table name
- Labels source: projectdiscovery
- Severity: high
- Cvss score: 8.5
- Cvss vector: CVSS:3.1/AV:N/AC:H/PR:L/UI:N/S:C/C:H/I:H/A:H
- Epss score: 0.00729
- Epss percentile: 0.55154
- Assignee: [email protected]
- Published at: 2026-09-18T20:17:19Z
- Age in days: 67
- Modified at: 2026-09-23T18:12:04Z
- References total: 3
- Oss: yes
- Projects total: 1
- Advisory url: https://nvd.nist.gov/vuln/detail/CVE-2026-61819
- Nvd status: awaiting_analysis
- Checked, none or zero: patch available, known exploited entries, nuclei templates, public exploits total, public exploits capped, public exploits, products total, products, rejected by nvd
- Not known: hackerone
Cwe
| Id | Name |
|---|---|
| CWE-89 | Improper Neutralization of Special Elements used in an SQL Command |
References
Same in every row:
- Source: nvd
- Tags:
Projects
| Repository | Link kinds | Indexed | Url |
|---|---|---|---|
| pgpartman/pg_partman | commit, fix, releases, security_advisory | yes | /v1/repositories/pgpartman/pg_partman |
Index
- Checked, none or zero: repositories, repositories high signal, packages
Exploitation
- Remote: yes
- Authentication required: yes
- Checked, none or zero: known exploited, known exploited by, exploitation seen, public exploit, public exploit count, initial access
- Not known: known exploited since, vulncheck known exploited since, public exploit first date, nuclei template, initial access since, hackerone reports, exposed hosts