{"schemaVersion":1,"url":"https://cve.openhack.com/cve/CVE-2026-61820","id":"CVE-2026-61820","title":"pg_partman privilege escalation via SQL injection when inheriting template properties","description":"pg_partman is a PostgreSQL extension that manages partitioned tables by time or ID. Prior to 5.5.0, inherit_template_properties() manually surrounds primary-key column names from pg_attribute.attname with double quotes without escaping embedded double-quote characters. A partman_user who owns a template table can create a crafted column name that breaks out of the generated ALTER TABLE ADD PRIMARY","descriptionLong":"pg_partman is a PostgreSQL extension that manages partitioned tables by time or ID. Prior to 5.5.0, inherit_template_properties() manually surrounds primary-key column names from pg_attribute.attname with double quotes without escaping embedded double-quote characters. A partman_user who owns a template table can create a crafted column name that breaks out of the generated ALTER TABLE ADD PRIMARY KEY identifier when the background worker applies the key to a child partition. The generated SQL then 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 crafted catalog identifier persists until removed and can trigger again during later partition creation. This issue is fixed in version 5.5.0.","published":"2026-09-18T19:49:10.983Z","updated":"2026-10-28T02:30:21.071720624Z","reserved":"2026-07-10T20:17:57.992Z","status":"Awaiting Analysis","rejected":false,"assigner":"GitHub_M","metric":{"version":"3.1","score":8.5,"vector":"CVSS:3.1/AV:N/AC:H/PR:L/UI:N/S:C/C:H/I:H/A:H","rating":"high","source":"GitHub_M"},"metrics":[{"version":"3.1","score":8.5,"vector":"CVSS:3.1/AV:N/AC:H/PR:L/UI:N/S:C/C:H/I:H/A:H","rating":"high","source":"GitHub_M"},{"version":"3.1","score":8.5,"vector":"CVSS:3.1/AV:N/AC:H/PR:L/UI:N/S:C/C:H/I:H/A:H","rating":"high","source":"github.com"},{"version":"3.1","score":8.5,"vector":"CVSS:3.1/AV:N/AC:H/PR:L/UI:N/S:C/C:H/I:H/A:H","rating":"high","source":"OSV"}],"rating":"high","products":["pgpartman pg_partman"],"affectedProducts":[{"vendor":"pgpartman","product":"pg_partman","defaultStatus":null,"versions":[{"version":"< 5.5.0","status":"affected"}],"platforms":[]}],"packages":[],"cwes":["CWE-89"],"aliases":["GHSA-xqxh-6hh3-974m"],"references":[{"url":"https://github.com/pgpartman/pg_partman/security/advisories/GHSA-xqxh-6hh3-974m","tags":["x_refsource_CONFIRM","advisory"]},{"url":"https://github.com/pgpartman/pg_partman/commit/ba9405542acf24dd881845b935cab8b165854361","tags":["x_refsource_MISC","fix"]},{"url":"https://github.com/pgpartman/pg_partman/releases/tag/v5.5.0","tags":["x_refsource_MISC","web"]},{"url":"https://github.com/CVEProject/cvelistV5/tree/main/cves/2026/61xxx/CVE-2026-61820.json","tags":["advisory"]},{"url":"https://nvd.nist.gov/vuln/detail/CVE-2026-61820","tags":["advisory"]}],"patchReferenced":true,"fixAvailable":true,"exploitReferenced":false,"kev":false,"kevAdded":null,"kevDue":null,"kevEntry":null,"ssvc":{"exploitation":"none","automatable":"no","technicalImpact":"total"},"epss":0.00892,"epssPercentile":0.60164,"sources":[{"name":"CVE List","url":"https://www.cve.org/CVERecord?id=CVE-2026-61820","ok":true},{"name":"NVD","url":"https://nvd.nist.gov/vuln/detail/CVE-2026-61820","ok":true,"note":"Awaiting Analysis"},{"name":"OSV","url":"https://osv.dev/vulnerability/CVE-2026-61820","ok":true,"note":"0 packages"},{"name":"CISA KEV","url":"https://www.cisa.gov/known-exploited-vulnerabilities-catalog","ok":true,"note":"not listed"},{"name":"EPSS","url":"https://api.first.org/data/v1/epss?cve=CVE-2026-61820","ok":true,"note":"scored 2026-11-19"}],"aiTitle":false,"tech":[],"critical":[],"attention":null}