Your message dated Wed, 11 Sep 2013 16:48:10 +0000 with message-id <[email protected]> and subject line Bug#650422: fixed in freetds 0.91-5 has caused the Debian Bug report #650422, regarding tdsodbc: segfault in SQLTables to be marked as done.
This means that you claim that the problem has been dealt with. If this is not the case it is now your responsibility to reopen the Bug report if necessary, and/or fix the problem forthwith. (NB: If you are a system administrator and have no idea what this message is talking about, this may indicate a serious mail system misconfiguration somewhere. Please contact [email protected] immediately.) -- 650422: http://bugs.debian.org/cgi-bin/bugreport.cgi?bug=650422 Debian Bug Tracking System Contact [email protected] with problems
--- Begin Message ---Package: tdsodbc Version: 0.91-1.0 Severity: important Tags: upstream patch tdsodbc segfaults on some calls of SQLTables; in particular it segfaults when used from LibreOffice, when the user just *browses* the available tables (not opening a table, selecting data from it; just browsing the list of tables). Here's an example backtrace: #0 0x00007fb82705365c in tds_quote (tds=0x33a3a20, buffer=0x0, quoting=93 ']', id= 0xffffffffffffffff <Address 0xffffffffffffffff out of bounds>, len=1106707232) at query.c:2184 #1 0x00007fb82705378c in tds_quote_id (tds=0x33a3a20, buffer=0x0, id=0xffffffffffffffff <Address 0xffffffffffffffff out of bounds>, idlen=1106707232) at query.c:2222 #2 0x00007fb827027ff6 in odbc_stat_execute (stmt=0x34e9cc0, begin=0x7fb8270698cf "..sp_tables", nparams=4) at odbc.c:7049 #3 0x00007fb827027492 in _SQLTables (hstmt=0x34e9cc0, szCatalogName=0x34e5118 "APSAL", cbCatalogName=-3, szSchemaName=0x34e5138 "dbo", cbSchemaName=-3, szTableName=0x34e4208 "ANALYTIC_VENTILATION", cbTableName=-3, szTableType=0x34e9ee8 "VIEW,TABLE,%,", cbTableType=-3) at odbc.c:6793 #4 0x00007fb827026d3c in SQLTables (hstmt=0x34e9cc0, szCatalogName=0x34e5118 "APSAL", cbCatalogName=-3, szSchemaName=0x34e5138 "dbo", cbSchemaName=-3, szTableName=0x34e4208 "ANALYTIC_VENTILATION", cbTableName=-3, szTableType=0x34e9ee8 "VIEW,TABLE,%,", cbTableType=-3) at sqlwparams.h:113 odbc.c:6793 is if (begin[0] == '.' && strstr(params[i].name, "qualifier")) { len += tds_quote_id(stmt->dbc->tds_socket, NULL, tds_dstr_cstr(¶ms[param_qualifier].value), tds_dstr_len(¶ms[param_qualifier].value)); param_qualifier = i; } Note that the first time this codepath is taken, param_qualifier is still as initialised at begin of function call, namely -1. tds_dstr_cstr thus gets passed params[-1].value, which is "obviously" a nonsensical value. Switching these two statements fixes the problem. Here is the patch: --- freetds-0.91.orig/src/odbc/odbc.c +++ freetds-0.91/src/odbc/odbc.c @@ -7046,9 +7046,9 @@ len += strlen(params[i].name) + odbc_quote_metadata(stmt->dbc, params[i].type, NULL, ¶ms[i].value) + 3; if (begin[0] == '.' && strstr(params[i].name, "qualifier")) { + param_qualifier = i; len += tds_quote_id(stmt->dbc->tds_socket, NULL, tds_dstr_cstr(¶ms[param_qualifier].value), tds_dstr_len(¶ms[param_qualifier].value)); - param_qualifier = i; } } -- System Information: Debian Release: 6.0.3 APT prefers stable APT policy: (500, 'stable'), (400, 'testing'), (300, 'unstable'), (1, 'experimental') Architecture: amd64 (x86_64) Kernel: Linux 3.1.0-1-amd64 (SMP w/4 CPU cores) Locale: LANG=fr_LU.UTF-8, LC_CTYPE=fr_LU.UTF-8 (charmap=UTF-8) Shell: /bin/sh linked to /bin/dash Versions of packages tdsodbc depends on: ii debconf [debconf-2.0] 1.5.36.1 Debian configuration management sy ii freetds-common 0.91-1.0 configuration files for FreeTDS SQ ii libc6 2.13-21 Embedded GNU C Library: Shared lib ii libgnutls26 2.12.11-1 GNU TLS library - runtime library ii odbcinst1debian2 2.2.14p2-4 Support library for accessing odbc Versions of packages tdsodbc recommends: ii libodbc1 2.2.14p2-4 ODBC library for Unix tdsodbc suggests no packages. -- debconf information: * freetds/addtoodbc: true
--- End Message ---
--- Begin Message ---Source: freetds Source-Version: 0.91-5 We believe that the bug you reported is fixed in the latest version of freetds, which is due to be installed in the Debian FTP archive. A summary of the changes between this version and the previous one is attached. Thank you for reporting the bug, which will now be closed. If you have further comments please address them to [email protected], and the maintainer will reopen the bug report if appropriate. Debian distribution maintenance software pp. Steve Langasek <[email protected]> (supplier of updated freetds package) (This message was generated automatically at their request; if you believe that there is a problem with it please contact the archive administrators by mailing [email protected]) -----BEGIN PGP SIGNED MESSAGE----- Hash: SHA256 Format: 1.8 Date: Wed, 11 Sep 2013 06:37:14 +0000 Source: freetds Binary: freetds-common libct4 freetds-bin tdsodbc libsybdb5 freetds-dev Architecture: source all amd64 Version: 0.91-5 Distribution: unstable Urgency: low Maintainer: Steve Langasek <[email protected]> Changed-By: Steve Langasek <[email protected]> Description: freetds-bin - FreeTDS command-line utilities freetds-common - configuration files for FreeTDS SQL client libraries freetds-dev - MS SQL and Sybase client library (static libs and headers) libct4 - libraries for connecting to MS SQL and Sybase SQL servers libsybdb5 - libraries for connecting to MS SQL and Sybase SQL servers tdsodbc - ODBC driver for connecting to MS SQL and Sybase SQL servers Closes: 650421 650422 665268 699069 715697 715698 715785 Changes: freetds (0.91-5) unstable; urgency=low . * Add Kerberos support. LP: #1223567. * Stop overriding CPPFLAGS in debian/rules, giving us full proper hardening support. Closes: #665268. * src/odbc/odbc.c: cherry-pick upstream fix for a segfault due to an uninitialized value. Thanks to Lionel Elie Mamane <[email protected]> for the fix. Closes: #650422. * Allow parallel builds. Closes: #650421. * Drop manual autotools patching for dh-autoreconf, fixing builds on x32 et al. Closes: #699069. * Properly bump the build-dep on debhelper to 9. * Bump to Standards-Version 3.9.4, no changes required. * Convert copyright file to copyright-format 1.0. * src/apps/bsqldb.c, src/apps/bsqlodbc.c: fix wrong getopt() option strings so that arguments to -d are parsed correctly. Closes: #715697, #715698. * src/apps/datacopy.c: handle a lack of login/password information without segfaulting. Closes: #715785. Checksums-Sha1: 5eed091becfc0c0c3c4ba2e8d4ec48b10217fdf7 2219 freetds_0.91-5.dsc 7bdaeb6487fa2908fb0dd9fd82564dbfb1ee40b3 22214 freetds_0.91-5.diff.gz 48620e70351a5ab0c554f667bab8d559f1ee78f3 57666 freetds-common_0.91-5_all.deb cc934b15e44cc8c16605eed4ca829924cff5b193 173674 libct4_0.91-5_amd64.deb 4bb090612750c96d6c596520c228edb5feb9e44d 216742 freetds-bin_0.91-5_amd64.deb 243dc14b65d4b2ceb8e6ade959f6b8f6785757b0 197854 tdsodbc_0.91-5_amd64.deb cd78446d3c4304836df1676f472da863470ff923 196696 libsybdb5_0.91-5_amd64.deb da6b702e09bbe3aaa21daa7c5882d7934b0eb154 274156 freetds-dev_0.91-5_amd64.deb Checksums-Sha256: 2781b5030296b39a67cb31725fa9ad54a6b12fd0d57b1f03b470544437011717 2219 freetds_0.91-5.dsc 31f67434d8254eff77893a957512c8cdf708420f7abd0eca5ca4895291bd5143 22214 freetds_0.91-5.diff.gz 5640fac5fa62d86db38338a174928693fb98f92df7fe0e9535907ff2e297f01c 57666 freetds-common_0.91-5_all.deb fe3d6d192cc32ef47bb7ece3b04915068d8cecca183d782277fcdb43913c5e33 173674 libct4_0.91-5_amd64.deb 1025ea58c346c391517cd9179a6687ce33ec639cf93a915f2c5202208049eaad 216742 freetds-bin_0.91-5_amd64.deb fe58ade164057100418994ab22ca9d0ec27f6921130c54ec2f9c8a8ce9d7a1d8 197854 tdsodbc_0.91-5_amd64.deb c1c022afa95277210ca1dc41bb96020b6172be2228975f25ef7841fc3b95419d 196696 libsybdb5_0.91-5_amd64.deb e8eb2afcb7b4fb429a3f9faa0059f7eecf8dfc6fa928d4998dcc6443b987a73b 274156 freetds-dev_0.91-5_amd64.deb Files: 1bc5fe374aa3d3b842ae823b6d57390e 2219 libs optional freetds_0.91-5.dsc fde9251e75c91310968173a8a744e351 22214 libs optional freetds_0.91-5.diff.gz 60ff9a90d79d6e7589562fb2d7496b97 57666 libs optional freetds-common_0.91-5_all.deb 4f4737ee0fcc629c2e2d91f3ac3ec735 173674 libs optional libct4_0.91-5_amd64.deb e01d58118b2ab0db12c90f850a6e7b1b 216742 database optional freetds-bin_0.91-5_amd64.deb d5cacd4bd8e4b8ac924bcfbf8aa52b5c 197854 libs optional tdsodbc_0.91-5_amd64.deb 4d8096cea2e32bbcf74cc273636946e8 196696 libs optional libsybdb5_0.91-5_amd64.deb e6e5734bc2fc5e04fdfaad4ec5207653 274156 devel optional freetds-dev_0.91-5_amd64.deb -----BEGIN PGP SIGNATURE----- Version: GnuPG v1.4.14 (GNU/Linux) iQIcBAEBCAAGBQJSMJtDAAoJEFaNMPMhshM9ziAP/RhecmdigFwd5vKkcJLNyj1f o3/7QKerbVOqSTAnOBngBeBkcqVvsfSn01YwMZhTXcCiIHCrHb33MujdGNewwvD2 3vUXAn32KB/0D4aiFSTPAaqtr6YNmYwpwSYedxRNN+exQdgoroaDIXzAtoklCoNb oQXCzZtNbk/iILuQv+GzZ0flVaYcw/GEDD7F6mgM3TJenhRKJexCYpSovWugaBS9 bknt7JgjWDhsoMRL1RxGsIGaDSwUJaUDDlMvfNl2TeBzBYk4+h8w6N/jFkwuhH0X uirlVQiDnR3Ie8SoHv7KXhjssWPiaqDueAUsWIb9v1VtXNEqvuxzoL75h/epaXX1 P88F38sNaEYNkQOoKOgS5BTt/FezDTgKdASh20h4lagizbwFn0fMbQBkYStj+Q8i 15djkhsSzaUFXr5gTn0W1uOEQDJ/3JapSvHzzPyInD4ezdyErsNp+Wqrh7VRSMRC 6FtupqtD0gMk8u0PeAGmjs3SP1SnOEmhX+qhQDI4M1rS34VGI1pmqjEXfW2nIIUj 7IHBRA3he4FDy/1hsVnTbUl/bAIWXl8ZIuJ7zuS537LUy2MvDS+GHFxKUoSNUXjT y5vGE9Su+F5HDWmDrORpXiCggVkmDwoTce+AAGYjqKymrR+PHAdIHEsXdLgES3LN U0jv9lIXPMMVek0NBGXN =qfA9 -----END PGP SIGNATURE-----
--- End Message ---

