# CVE-2026-136512: Buffer overflows when a converted value does not fit the application's buffer

Status: published. Published: 2026-11-25. Updated: 2026-11-25.

With SQL_C_DEFAULT, the C type of a bound column or parameter follows its SQL type. An application sizes its buffer from the type it was told when it described the statement. When the column had another type at fetch time, because the server reported another type, the table was altered, or an output parameter's result column had another type, psqlODBC wrote the larger type into the smaller buffer: 12 bytes past a 4-byte buffer for a uuid, and more in multi-row fetches, where the driver also steps through the array by the larger size.

Other conversions wrote past the application's buffer as well:

- With Int8As set to a smaller type, an int8 column fetched as SQL_C_DEFAULT was still written as 8 bytes.
- An int2vector column fetched as SQL_C_DEFAULT returned unterminated binary data instead of text.
- An output parameter that the application discards by binding a NULL buffer overflowed a stack buffer in the driver.
- SQLGetData() with BufferLength 0 on a column the driver reads as a large object wrote a NUL byte past the buffer.
- Adding a row with SQLBulkOperations(SQL_ADD) on a static updatable cursor before the first fetch, then changing that row, rolling back and fetching it, made the keyset index arithmetic free a pointer that was never allocated and corrupt the heap.

This can be triggered by a hostile or compromised server, or anyone on the network path of a connection that does not use sslmode=verify-full (the default is disable), and by the owner of a table the application reads.

Versions up to and including psqlODBC 18.00.0006 are affected.

## Remediation

No remediation reported in collected sources

## Affected products and versions

- PostgreSQL / psqlODBC (psqlodbc): ≥ 0; ≤ 18.00.0006 (affected, custom). Source: CNA: PostgreSQL

## Severity and prioritization

- CVSS 3.1: 7.5 (high); CVSS:3.1/AV:N/AC:H/PR:N/UI:R/S:U/C:H/I:H/A:H; source: CNA: PostgreSQL

- CVSS 3.1: 7.5 (high); CVSS:3.1/AV:N/AC:H/PR:N/UI:R/S:U/C:H/I:H/A:H; source: NVD: f86ef6dc-4d3a-42ad-8f28-e6d5547a5007

- CISA KEV: No listing in collected sources

- EPSS: Not available

- SSVC: Not available

- Weaknesses: CWE-787

## Exploit evidence

No exploit evidence in collected sources. This is not proof of no exploitation.

## References

- https://github.com/postgresql-interfaces/psqlodbc/security/advisories/GHSA-c66p-8p63-p7mr (CNA: PostgreSQL; vendor-advisory)

- https://odbc.postgresql.org/changelog/ (CNA: PostgreSQL; release-notes)

- https://github.com/postgresql-interfaces/psqlodbc/security/advisories/GHSA-c66p-8p63-p7mr (f86ef6dc-4d3a-42ad-8f28-e6d5547a5007)

- https://odbc.postgresql.org/changelog/ (f86ef6dc-4d3a-42ad-8f28-e6d5547a5007)

## Provenance

- CNA: PostgreSQL: https://www.cve.org/CVERecord?id=CVE-2026-136512; retrieved 2026-11-25; source updated 2026-11-25

- NVD: https://nvd.nist.gov/vuln/detail/CVE-2026-136512; retrieved 2026-11-26; source updated 2026-11-25

Revision: 56202a44466470ac42b446f16d066e11a88eb827ff56695e94cdf8c5c4ab7711

Canonical: https://y2.dev/cve/CVE-2026-136512

## Agent and API access

Public CVE pages, Markdown, and JSON are free to read without an account or API key.

- Public catalog: https://y2.dev/cve/index.json. Follow nextCursor with the same search, filters, sort, and limit (1–100). A null cursor marks the end.

- WebMCP: search_cve_disclosures, get_cve_disclosure, get_cve_page_markdown, get_y2_cve_access. Available in compatible browsers.

- Cyber API: https://api.y2.dev/api/v2/cyber/cves and https://api.y2.dev/api/v2/cyber/cves/{cveId}.

- Y2 Pro or Elite: create a workspace API key with the intel:cyber scope and send Authorization: Bearer <Y2_API_KEY>. Setup: https://y2.dev/docs/api/create-key.

- x402: Pay per request without an account or API key. Omit Authorization, read the HTTP 402 PAYMENT-REQUIRED challenge, validate its current requirements, and retry with PAYMENT-SIGNATURE through an authorized payment client. These browser tools never make payments. Guide: https://y2.dev/docs/api/x402.

- OpenAPI: https://y2.dev/api/openapi.yaml. Agent access metadata: https://y2.dev/cve/agent.json.

Collected public records only. Check source status for coverage and freshness.