BreachSpiderVerified, not vibes

CVE-2012-0866 in Postgresql

Medium 6.5

CREATE TRIGGER in PostgreSQL 8.3.x before 8.3.18, 8.4.x before 8.4.11, 9.0.x before 9.0.7, and 9.1.x before 9.1.3 does not properly check the execute permission for trigger functions marked SECURITY DEFINER, which allows remote authenticated users to execute otherwise restricted triggers on arbitrary data by install...

Affects 1 product from 1 vendor. Facts below cite their sources.

CVSS 2.06.5
EPSS3.6%
EPSS percentile90th
FixSee advisory

Remotely exploitable over the network, low complexity.

Affected products and versions

VendorProductAffected versions
Postgresql Postgresql 8.3 8.3.1 8.3.2 8.3.3 8.3.4 8.3.5
+33 more8.3.6 8.3.7 8.3.8 8.3.9 8.3.10 8.3.11 8.3.12 8.3.13 8.3.14 8.3.15 8.3.16 8.3.17 8.4 8.4.1 8.4.2 8.4.3 8.4.4 8.4.5 8.4.6 8.4.7 8.4.8 8.4.9 8.4.10 9.0 9.0.1 9.0.2 9.0.3 9.0.4 9.0.5 9.0.6 9.1 9.1.1 9.1.2

A product listed here is affected only at the versions shown. Use the free check to test the exact version you run.

Fix and vendor advisory

View Vendor Advisory →

Vendor PSIRT: [email protected]

Exploitation

CISA known-exploitedNot in the CISA KEV catalog
Public exploitNot confirmed

Official description

CREATE TRIGGER in PostgreSQL 8.3.x before 8.3.18, 8.4.x before 8.4.11, 9.0.x before 9.0.7, and 9.1.x before 9.1.3 does not properly check the execute permission for trigger functions marked SECURITY DEFINER, which allows remote authenticated users to execute otherwise restricted triggers on arbitrary data by installing the trigger on an attacker-owned table.

Source: NIST NVD / MITRE CVE.

Record details

CVE IDCVE-2012-0866
BreachSpider IDBS-2012-GLOBAL-314046-M
CVSS vectorAV:N/AC:L/Au:S/C:P/I:P/A:P
Published2012-07-18
Last modified2026-06-16
Weakness (CWE)
SourceNVD

Weakness definitions

CWE-264: Permissions, Privileges, and Access Controls

Broad class covering failures in permission enforcement. Deprecated in favor of CWE-284, CWE-862, CWE-863.

Analysis AI-written, not human-reviewed

This vulnerability was disclosed in 2012. A medium severity vulnerability affects Postgresql systems (CVE-2012-0866). No public exploit code is currently available. Isolate affected systems if patching is not feasible.

Vulnerability details: CREATE TRIGGER in PostgreSQL 8.3.x before 8.3.18, 8.4.x before 8.4.11, 9.0.x before 9.0.7, and 9.1.x before 9.1.3 does not properly check the execute permission for trigger functions marked SECURITY DEFINER, which allows remote authenticated users to execute otherwise restricted triggers on arbitrary data by installing the trigger on an attacker-owned table. CVSS vector: AV:N/AC:L/Au:S/C:P/I:P/A:P.

Questions

What is CVE-2012-0866?

This vulnerability was disclosed in 2012. A medium severity vulnerability affects Postgresql systems (CVE-2012-0866). No public exploit code is currently available. Isolate affected systems if patching is not feasible.

What is the CVSS score for CVE-2012-0866?

CVE-2012-0866 has CVSS 6.5 (Medium). Vector: AV:N/AC:L/Au:S/C:P/I:P/A:P. EPSS: 3.6%.

Is CVE-2012-0866 actively exploited?

No confirmed active exploitation of CVE-2012-0866 as of 2026-09-25.

How do I remediate CVE-2012-0866?

Priority: MONITOR. Advisory: http://www.postgresql.org/about/news/1377/ PSIRT: [email protected]

What systems are affected by CVE-2012-0866?

CVE-2012-0866 affects Postgresql Postgresql.

For developers and AI agents

Run this check from your own code or agent

REST API

curl -s https://breachspider.com/api/v1/assets/correlate-cves \
 -H "Authorization: Bearer $BREACHSPIDER_API_KEY" \
 -H "Content-Type: application/json" \
 -d '{"assets":[{"asset_id":"dev-1","vendor":"Postgresql","product":"Postgresql","version":"1.0"}]}'

API reference

Python SDK

pip install breachspider

PyPI · GitHub

MCP for AI agents

# hosted: add as a connector
https://mcp.breachspider.com/mcp
# local
pipx install breachspider-mcp

Setup for Claude, ChatGPT, Cursor

Free trial: 14 days, 750 device checks, no card.

Page facts from NVD, MITRE, CISA and vendor advisories, record last modified 2026-06-16.