CVE-2026-136505 (GCVE-0-2026-136505)

Vulnerability from cvelistv5 – Published: 2026-11-25 22:25 – Updated: 2026-11-25 22:25
VLAI
Title
Unchecked sizes and counters overflow driver buffers
Summary
psqlODBC uses sizes and counts without checking their range, or keeps them in types too small for them: - A row array size of 0, set with SQLSetStmtAttr() or on the ARD, makes SQLSetPos() with SQL_REFRESH write past the bound arrays. - SQL_DESC_COUNT above 32767 on an APD or IPD writes before the start of a heap buffer. - A numeric parameter with a negative scale overflows a stack buffer. - SQLGetData() of a text value of 2 GiB or more into a wide-character buffer computes a wrapped size and overflows the heap. - The 16-bit reference count and size of the statement parser's column-information cache wrap, which frees a cache entry still in use or overflows the cache, and a statement with more than 32768 columns overflows the parser's field array. - An updatable cursor that records more than 65535 changes in one transaction wraps the 16-bit capacity of its rollback log, which overflows it and frees it twice. - A statement with 32769 or more parameter markers overflows a 16-bit parameter count. - A wide-character string of more than 2 GiB wraps the size of its UTF-8 conversion, which is then written below the start of a heap buffer. - SQLGetDiagField() and SQLGetDiagFieldW() always stored the five-character SQLSTATE plus its terminator and checked BufferLength only afterwards, overrunning a buffer shorter than six bytes. - The ANSI SQLSetDescField(SQL_DESC_NAME) on an IPD ignored BufferLength and copied the name with strdup(), reading a name passed as pointer plus length past its end. - SQLFetchScroll(SQL_FETCH_BOOKMARK) did not check the bookmark it was given, so whoever chooses the bookmark value read out of bounds and crashed the process. - Four places in the parameter conversion read one byte past the end of a bound character parameter, and one of them rewrote it. - Binding a date, time or timestamp C value to an SQL_INTEGER or SQL_SMALLINT parameter dereferenced NULL instead of returning the conversion error. Depending on the case, the values come from the application, from the data or statement text an end user supplies, or from a database user who controls the size of a table or value. The demonstrated results are crashes and heap corruption; code execution has not been demonstrated. Versions up to and including psqlODBC 18.00.0006 are affected.
CWE
  • CWE-190 - Integer Overflow or Wraparound
  • CWE-787 - Out-of-bounds Write
  • CWE-121 - Stack-based Buffer Overflow
References
Impacted products
Vendor Product Version
PostgreSQL psqlODBC Affected: 0 , ≤ 18.00.0006 (custom)
Create a notification for this product.
Show details on NVD website

{
  "containers": {
    "cna": {
      "affected": [
        {
          "collectionURL": "https://odbc.postgresql.org/",
          "defaultStatus": "unaffected",
          "packageName": "psqlodbc",
          "product": "psqlODBC",
          "vendor": "PostgreSQL",
          "versions": [
            {
              "lessThanOrEqual": "18.00.0006",
              "status": "affected",
              "version": "0",
              "versionType": "custom"
            }
          ]
        }
      ],
      "descriptions": [
        {
          "lang": "en",
          "value": "psqlODBC uses sizes and counts without checking their range, or keeps them in types too small for them:\n\n- A row array size of 0, set with SQLSetStmtAttr() or on the ARD, makes SQLSetPos() with SQL_REFRESH write past the bound arrays.\n- SQL_DESC_COUNT above 32767 on an APD or IPD writes before the start of a heap buffer.\n- A numeric parameter with a negative scale overflows a stack buffer.\n- SQLGetData() of a text value of 2 GiB or more into a wide-character buffer computes a wrapped size and overflows the heap.\n- The 16-bit reference count and size of the statement parser\u0027s column-information cache wrap, which frees a cache entry still in use or overflows the cache, and a statement with more than 32768 columns overflows the parser\u0027s field array.\n- An updatable cursor that records more than 65535 changes in one transaction wraps the 16-bit capacity of its rollback log, which overflows it and frees it twice.\n- A statement with 32769 or more parameter markers overflows a 16-bit parameter count.\n- A wide-character string of more than 2 GiB wraps the size of its UTF-8 conversion, which is then written below the start of a heap buffer.\n- SQLGetDiagField() and SQLGetDiagFieldW() always stored the five-character SQLSTATE plus its terminator and checked BufferLength only afterwards, overrunning a buffer shorter than six bytes.\n- The ANSI SQLSetDescField(SQL_DESC_NAME) on an IPD ignored BufferLength and copied the name with strdup(), reading a name passed as pointer plus length past its end.\n- SQLFetchScroll(SQL_FETCH_BOOKMARK) did not check the bookmark it was given, so whoever chooses the bookmark value read out of bounds and crashed the process.\n- Four places in the parameter conversion read one byte past the end of a bound character parameter, and one of them rewrote it.\n- Binding a date, time or timestamp C value to an SQL_INTEGER or SQL_SMALLINT parameter dereferenced NULL instead of returning the conversion error.\n\nDepending on the case, the values come from the application, from the data or statement text an end user supplies, or from a database user who controls the size of a table or value. The demonstrated results are crashes and heap corruption; code execution has not been demonstrated.\n\nVersions up to and including psqlODBC 18.00.0006 are affected."
        }
      ],
      "metrics": [
        {
          "cvssV3_1": {
            "baseScore": 7.5,
            "baseSeverity": "HIGH",
            "vectorString": "CVSS:3.1/AV:N/AC:H/PR:L/UI:N/S:U/C:H/I:H/A:H",
            "version": "3.1"
          },
          "format": "CVSS"
        }
      ],
      "problemTypes": [
        {
          "descriptions": [
            {
              "cweId": "CWE-190",
              "description": "CWE-190 Integer Overflow or Wraparound",
              "lang": "en",
              "type": "CWE"
            },
            {
              "cweId": "CWE-787",
              "description": "CWE-787 Out-of-bounds Write",
              "lang": "en",
              "type": "CWE"
            },
            {
              "cweId": "CWE-121",
              "description": "CWE-121 Stack-based Buffer Overflow",
              "lang": "en",
              "type": "CWE"
            }
          ]
        }
      ],
      "providerMetadata": {
        "dateUpdated": "2026-11-25T22:25:47.870Z",
        "orgId": "f86ef6dc-4d3a-42ad-8f28-e6d5547a5007",
        "shortName": "PostgreSQL"
      },
      "references": [
        {
          "name": "GHSA-4g4f-phc4-3qh7",
          "tags": [
            "vendor-advisory"
          ],
          "url": "https://github.com/postgresql-interfaces/psqlodbc/security/advisories/GHSA-4g4f-phc4-3qh7"
        },
        {
          "name": "psqlODBC changelog",
          "tags": [
            "release-notes"
          ],
          "url": "https://odbc.postgresql.org/changelog/"
        }
      ],
      "title": "Unchecked sizes and counters overflow driver buffers"
    }
  },
  "cveMetadata": {
    "assignerOrgId": "f86ef6dc-4d3a-42ad-8f28-e6d5547a5007",
    "assignerShortName": "PostgreSQL",
    "cveId": "CVE-2026-136505",
    "datePublished": "2026-11-25T22:25:47.870Z",
    "dateReserved": "2026-11-24T20:17:10.904Z",
    "dateUpdated": "2026-11-25T22:25:47.870Z",
    "state": "PUBLISHED"
  },
  "dataType": "CVE_RECORD",
  "dataVersion": "5.2",
  "vulnerability-lookup:meta": {
    "epss": {
      "cve": "CVE-2026-136505",
      "date": "2026-11-27",
      "epss": "0.00527",
      "percentile": "0.38047"
    },
    "microsoft_vex": {
      "current_release_date": "2026-11-27T01:18:04.000Z",
      "cve": "CVE-2026-136505",
      "id": "msrc_CVE-2026-136505",
      "initial_release_date": "2026-11-27T01:18:04.000Z",
      "product_status:under_investigation": "1",
      "source": "Microsoft CSAF VEX",
      "status": "final",
      "title": "Unchecked sizes and counters overflow driver buffers",
      "url": "https://msrc.microsoft.com/csaf/vex/2026/msrc_cve-2026-136505.json",
      "version": "1"
    },
    "nvd": {
      "cve": {
        "affected": [
          {
            "affectedData": [
              {
                "collectionURL": "https://odbc.postgresql.org/",
                "defaultStatus": "unaffected",
                "packageName": "psqlodbc",
                "product": "psqlODBC",
                "vendor": "PostgreSQL",
                "versions": [
                  {
                    "lessThanOrEqual": "18.00.0006",
                    "status": "affected",
                    "version": "0",
                    "versionType": "custom"
                  }
                ]
              }
            ],
            "source": "f86ef6dc-4d3a-42ad-8f28-e6d5547a5007"
          }
        ],
        "cveTags": [],
        "descriptions": [
          {
            "lang": "en",
            "value": "psqlODBC uses sizes and counts without checking their range, or keeps them in types too small for them:\n\n- A row array size of 0, set with SQLSetStmtAttr() or on the ARD, makes SQLSetPos() with SQL_REFRESH write past the bound arrays.\n- SQL_DESC_COUNT above 32767 on an APD or IPD writes before the start of a heap buffer.\n- A numeric parameter with a negative scale overflows a stack buffer.\n- SQLGetData() of a text value of 2 GiB or more into a wide-character buffer computes a wrapped size and overflows the heap.\n- The 16-bit reference count and size of the statement parser\u0027s column-information cache wrap, which frees a cache entry still in use or overflows the cache, and a statement with more than 32768 columns overflows the parser\u0027s field array.\n- An updatable cursor that records more than 65535 changes in one transaction wraps the 16-bit capacity of its rollback log, which overflows it and frees it twice.\n- A statement with 32769 or more parameter markers overflows a 16-bit parameter count.\n- A wide-character string of more than 2 GiB wraps the size of its UTF-8 conversion, which is then written below the start of a heap buffer.\n- SQLGetDiagField() and SQLGetDiagFieldW() always stored the five-character SQLSTATE plus its terminator and checked BufferLength only afterwards, overrunning a buffer shorter than six bytes.\n- The ANSI SQLSetDescField(SQL_DESC_NAME) on an IPD ignored BufferLength and copied the name with strdup(), reading a name passed as pointer plus length past its end.\n- SQLFetchScroll(SQL_FETCH_BOOKMARK) did not check the bookmark it was given, so whoever chooses the bookmark value read out of bounds and crashed the process.\n- Four places in the parameter conversion read one byte past the end of a bound character parameter, and one of them rewrote it.\n- Binding a date, time or timestamp C value to an SQL_INTEGER or SQL_SMALLINT parameter dereferenced NULL instead of returning the conversion error.\n\nDepending on the case, the values come from the application, from the data or statement text an end user supplies, or from a database user who controls the size of a table or value. The demonstrated results are crashes and heap corruption; code execution has not been demonstrated.\n\nVersions up to and including psqlODBC 18.00.0006 are affected."
          }
        ],
        "id": "CVE-2026-136505",
        "lastModified": "2026-11-25T23:17:23.570",
        "metrics": {
          "cvssMetricV31": [
            {
              "cvssData": {
                "attackComplexity": "HIGH",
                "attackVector": "NETWORK",
                "availabilityImpact": "HIGH",
                "baseScore": 7.5,
                "baseSeverity": "HIGH",
                "confidentialityImpact": "HIGH",
                "integrityImpact": "HIGH",
                "privilegesRequired": "LOW",
                "scope": "UNCHANGED",
                "userInteraction": "NONE",
                "vectorString": "CVSS:3.1/AV:N/AC:H/PR:L/UI:N/S:U/C:H/I:H/A:H",
                "version": "3.1"
              },
              "exploitabilityScore": 1.6,
              "impactScore": 5.9,
              "source": "f86ef6dc-4d3a-42ad-8f28-e6d5547a5007",
              "type": "Secondary"
            }
          ]
        },
        "published": "2026-11-25T23:17:23.570",
        "references": [
          {
            "source": "f86ef6dc-4d3a-42ad-8f28-e6d5547a5007",
            "url": "https://github.com/postgresql-interfaces/psqlodbc/security/advisories/GHSA-4g4f-phc4-3qh7"
          },
          {
            "source": "f86ef6dc-4d3a-42ad-8f28-e6d5547a5007",
            "url": "https://odbc.postgresql.org/changelog/"
          }
        ],
        "sourceIdentifier": "f86ef6dc-4d3a-42ad-8f28-e6d5547a5007",
        "vulnStatus": "Received",
        "weaknesses": [
          {
            "description": [
              {
                "lang": "en",
                "value": "CWE-121"
              },
              {
                "lang": "en",
                "value": "CWE-190"
              },
              {
                "lang": "en",
                "value": "CWE-787"
              }
            ],
            "source": "f86ef6dc-4d3a-42ad-8f28-e6d5547a5007",
            "type": "Secondary"
          }
        ]
      }
    }
  }
}



Log in or create an account to share your comment.




Tags
Taxonomy of the tags.


Loading…

Loading…

Loading…

Forecast uses a logistic model when the trend is rising, or an exponential decay model when the trend is falling. Fitted via linearized least squares.

Sightings

Author Source Type Date Other

Nomenclature

  • Seen: The vulnerability was mentioned, discussed, or observed by the user.
  • Confirmed: The vulnerability has been validated from an analyst's perspective.
  • Published Proof of Concept: A public proof of concept is available for this vulnerability.
  • Exploited: The vulnerability was observed as exploited by the user who reported the sighting.
  • Patched: The vulnerability was observed as successfully patched by the user who reported the sighting.
  • Not exploited: The vulnerability was not observed as exploited by the user who reported the sighting.
  • Not confirmed: The user expressed doubt about the validity of the vulnerability.
  • Not patched: The vulnerability was not observed as successfully patched by the user who reported the sighting.

Loading…

Loading…

Loading…

Related by attack behaviour

Vulnerabilities whose description is nearest to this one in the vector space of the CIRCL/vulnerability-attack-technique-biencoder model. This is a similarity search over the bi-encoder space (plain cosine), not a classification, and it has no measured accuracy.


Loading…