You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
Database Version: Microsoft SQL Server 2022 (RTM-CU15-GDR) (KB5046862) - 16.0.4155.4 (X64) Oct 18 2024 16:16:11 Copyright (C) 2022 Microsoft Corporation Developer Edition (64-bit) on Linux (Ubuntu 22.04.5 LTS)
Database OS: Linux (Docker)
Node.js Version: 20
Node.js OS: Linux (Docker)
Describe the bug
ODBC Library crashes with segfault when opening database connection
Expected behavior
The database is opened and queries can be executed
To Reproduce
Reproduction available in this repositories docker compose, See project readme. Namely running the willCrash.js with node
Code
If applicable, add snippets of code to show:
The offending code:
constodbc=require("odbc");require('dotenv').config()asyncfunctionconnectToDatabase(){letdatabase=process.env.DB||'db'letpassword=process.env.PASS||'DATABASE_PASSWORD1!'letconnString=`Driver={ODBC Driver 17 for SQL Server};Server=${database};Database=master;Uid=sa;Pwd=${password};`;console.log(`Connecting with connString: ${connString}`);constconnection=awaitodbc.connect(connString);constresult=awaitconnection.query("select * from INFORMATION_SCHEMA.COLUMNS");console.log(result);}connectToDatabase().catch((e)=>console.log(e));
Any DEBUG information printed to the terminal:
(Segfault)
GDB Debug output
Starting program: /usr/local/bin/node willCrash.js
warning: Error disabling address space randomization: Operation not permitted
[Thread debugging using libthread_db enabled]
Using host libthread_db library "/lib/x86_64-linux-gnu/libthread_db.so.1".
[New Thread 0x7f3d61bda6c0 (LWP 61)]
[New Thread 0x7f3d613d96c0 (LWP 62)]
[New Thread 0x7f3d60bd86c0 (LWP 63)]
[New Thread 0x7f3d5bfff6c0 (LWP 64)]
[New Thread 0x7f3d5b7fe6c0 (LWP 65)]
[New Thread 0x7f3d603366c0 (LWP 66)]
Connecting with connString: Driver={ODBC Driver 17 for SQL Server};Server=db;Database=master;Uid=sa;Pwd=DATABASE_PASSWORD1!;
[New Thread 0x7f3d3afbf6c0 (LWP 67)]
[New Thread 0x7f3d3a7be6c0 (LWP 68)]
[New Thread 0x7f3d39fbd6c0 (LWP 69)]
[New Thread 0x7f3d397bc6c0 (LWP 70)]
Thread 8 "node" received signal SIGSEGV, Segmentation fault.
[Switching to Thread 0x7f3d3afbf6c0 (LWP 67)]
0x0000000001a9141a in SSL_SESSION_free ()
Any error information returned from a function call:
Additional context
Add any other context about the problem here.
The text was updated successfully, but these errors were encountered:
Describe your system
odbc
Package Version: 2.4.9Describe the bug
ODBC Library crashes with segfault when opening database connection
Expected behavior
The database is opened and queries can be executed
To Reproduce
Reproduction available in this repositories docker compose, See project readme. Namely running the
willCrash.js
with nodeCode
If applicable, add snippets of code to show:
(Segfault)
GDB Debug output
Additional context
Add any other context about the problem here.
The text was updated successfully, but these errors were encountered: