Your message dated Fri, 07 Mar 2014 06:33:33 +0000
with message-id <e1wlold-0002gz...@franck.debian.org>
and subject line Bug#705645: fixed in sqlline 1.0.2-5
has caused the Debian Bug report #705645,
regarding Sqlline fails with MS SQL Server JDBC data sources
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 ow...@bugs.debian.org
immediately.)


-- 
705645: http://bugs.debian.org/cgi-bin/bugreport.cgi?bug=705645
Debian Bug Tracking System
Contact ow...@bugs.debian.org with problems
--- Begin Message ---
Package: sqlline
Version: 1.0.2-4

Hello,

Running the sqlline binary against a MS SQL Server JDBC data source results in 
the following error:

$ sqlline
sqlline version 1.0.2 by Marc Prud'hommeaux
sqlline>  !connect jdbc:sqlserver://X.X.X.X:1433;databaseName=MyDatabase
Connecting to jdbc:sqlserver://X.X.X.X:1433;databaseName=MyDatabase
Enter username for jdbc:sqlserver://X.X.X.X:1433;databaseName=MyDatabase: foo
Enter password for jdbc:sqlserver://X.X.X.X:1433;databaseName=MyDatabase: ***
Apr 17, 2013 7:34:46 PM com.microsoft.sqlserver.jdbc.TDSChannel enableSSL
INFO: java.security path: 
/usr/lib/jvm/java-1.6.0-openjdk-1.6.0.0.x86_64/jre/lib/security
Security providers: [SUN version 1.6, SunRsaSign version 1.7, SunJSSE version 
1.6, SunJGSS version 1.0, SunSASL version 1.5, XMLDSig version 1.0, SunPCSC 
version 1.6]
SSLContext provider info: Sun JSSE provider(PKCS12, SunX509 key/trust 
factories, SSLv3, TLSv1)
SSLContext provider services:
[SunJSSE: KeyFactory.RSA -> sun.security.rsa.RSAKeyFactory
  aliases: [1.2.840.113549.1.1, OID.1.2.840.113549.1.1]
, SunJSSE: KeyPairGenerator.RSA -> sun.security.rsa.RSAKeyPairGenerator
  aliases: [1.2.840.113549.1.1, OID.1.2.840.113549.1.1]
, SunJSSE: Signature.MD2withRSA -> sun.security.rsa.RSASignature$MD2withRSA
  aliases: [1.2.840.113549.1.1.2, OID.1.2.840.113549.1.1.2]
, SunJSSE: Signature.MD5withRSA -> sun.security.rsa.RSASignature$MD5withRSA
  aliases: [1.2.840.113549.1.1.4, OID.1.2.840.113549.1.1.4]
, SunJSSE: Signature.SHA1withRSA -> sun.security.rsa.RSASignature$SHA1withRSA
  aliases: [1.2.840.113549.1.1.5, OID.1.2.840.113549.1.1.5, 1.3.14.3.2.29, 
OID.1.3.14.3.2.29]
, SunJSSE: Signature.MD5andSHA1withRSA -> sun.security.ssl.RSASignature
, SunJSSE: KeyManagerFactory.SunX509 -> 
sun.security.ssl.KeyManagerFactoryImpl$SunX509
, SunJSSE: KeyManagerFactory.NewSunX509 -> 
sun.security.ssl.KeyManagerFactoryImpl$X509
, SunJSSE: TrustManagerFactory.SunX509 -> 
sun.security.ssl.TrustManagerFactoryImpl$SimpleFactory
, SunJSSE: TrustManagerFactory.PKIX -> 
sun.security.ssl.TrustManagerFactoryImpl$PKIXFactory
  aliases: [SunPKIX, X509, X.509]
, SunJSSE: SSLContext.SSL -> sun.security.ssl.SSLContextImpl
, SunJSSE: SSLContext.SSLv3 -> sun.security.ssl.SSLContextImpl
, SunJSSE: SSLContext.TLS -> sun.security.ssl.SSLContextImpl
, SunJSSE: SSLContext.TLSv1 -> sun.security.ssl.SSLContextImpl
, SunJSSE: SSLContext.Default -> sun.security.ssl.DefaultSSLContextImpl
, SunJSSE: KeyStore.PKCS12 -> sun.security.pkcs12.PKCS12KeyStore
]
java.ext.dirs: /usr/share/java/:/usr/local/share/java/
Error: The driver could not establish a secure connection to SQL Server by 
using Secure Sockets Layer (SSL) encryption. Error: "RSA premaster secret 
error". ClientConnectionId:656fc562-608b-4bb4-9bf1-29720f312884 
(state=08S01,code=0)

According to other bug reports with similar errors, it's because java.ext.dirs 
overrides the automatic use of the jre/lib/ext directory (reference 
http://bugs.sun.com/bugdatabase/view_bug.do?bug_id=6382135). And indeed, 
manually updating the sqlline binary to add the correct ext dir does fix this 
for the above test. Here's my local patch, though there's probably a much 
better way to do this when java-wrappers is involved.

Thanks,
Mark

--- /usr/bin/sqlline    2009-07-13 15:08:44.000000000 -0400
+++ sqlline     2013-04-17 19:40:06.000000000 -0400
@@ -1,6 +1,7 @@
 #!/bin/sh

-JAVA_ARGS="-Djava.ext.dirs=/usr/share/java/:/usr/local/share/java/"
+EXT_DIRS=/usr/share/java/:/usr/local/share/java/
+

 # Include the wrappers utility script
 . /usr/lib/java-wrappers/java-wrappers.sh
@@ -11,6 +12,18 @@
 # Define our classpath
 find_jars jline sqlline

+# find jre/lib/ext
+EXT=$JAVA_HOME/lib/ext
+if [ ! -d $EXT ] ; then
+  EXT=$JAVA_HOME/jre/lib/ext
+  if [ ! -d $EXT ] ; then
+    echo "Can't find extension dir (jre/lib/ext)!" >&2
+    exit 1
+  fi
+fi
+
+JAVA_ARGS="-Djava.ext.dirs=$EXT:/usr/share/java/:/usr/local/share/java/"
+
 # Run SQLLine
 run_java sqlline.SqlLine $extra_args "$@"
The information transmitted, including any content in this communication is 
confidential, is intended only for the use of the intended recipient and is the 
property of The Western Union Company or its affiliates and subsidiaries. If 
you are not the intended recipient, you are hereby notified that any use of the 
information contained in or transmitted with the communication or 
dissemination, distribution, or copying of this communication is strictly 
prohibited. If you have received this communication in error, please notify the 
Western Union sender immediately by replying to this message and delete the 
original message

--- End Message ---
--- Begin Message ---
Source: sqlline
Source-Version: 1.0.2-5

We believe that the bug you reported is fixed in the latest version of
sqlline, 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 705...@bugs.debian.org,
and the maintainer will reopen the bug report if appropriate.

Debian distribution maintenance software
pp.
Emmanuel Bourg <ebo...@apache.org> (supplier of updated sqlline 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 ftpmas...@ftp-master.debian.org)


-----BEGIN PGP SIGNED MESSAGE-----
Hash: SHA512

Format: 1.8
Date: Thu, 06 Mar 2014 09:30:18 +0100
Source: sqlline
Binary: sqlline
Architecture: source all
Version: 1.0.2-5
Distribution: unstable
Urgency: medium
Maintainer: Debian Java Maintainers 
<pkg-java-maintainers@lists.alioth.debian.org>
Changed-By: Emmanuel Bourg <ebo...@apache.org>
Description: 
 sqlline    - JDBC command-line utility for issuing SQL
Closes: 705645 738425
Changes: 
 sqlline (1.0.2-5) unstable; urgency=medium
 .
   * Team upload.
   * Add the known JDBC drivers to the classpath instead of setting
     the java.ext.dirs system property (Closes: #705645)
   * Renamed the 'enum' variables to fix a build failure (Closes: #738425)
   * Updated the Lintian overrides to use capitalization-error-in-description
     instead of spelling-error-in-description
   * debian/control:
     - Standards-Version updated to 3.9.5 (no changes)
     - Use canonical URLs for the Vcs-* fields
     - Recommend libpostgresql-jdbc-java instead of libpg-java
   * Switch to debhelper level 9
   * Added a clean target to debian/rules
Checksums-Sha1: 
 cad0df879acb5593f5efc177a119c2acd348cdcd 1945 sqlline_1.0.2-5.dsc
 432b2968e2e338c4b0909afc2713e67c57c76ab0 4940 sqlline_1.0.2-5.debian.tar.xz
 5abc76644320f7aac1b9c8e6a1d7898939f0a1d9 64460 sqlline_1.0.2-5_all.deb
Checksums-Sha256: 
 aebea3a174da2156ac4167462416b4b614edbbb9655199e2dad133a5e4851f87 1945 
sqlline_1.0.2-5.dsc
 6616a7088c9a2b3965fe9f0045e43bac5a795def33e4674b3447588c063c1628 4940 
sqlline_1.0.2-5.debian.tar.xz
 b108dbfdd9c54a798a7c02fb8ffb434902c15b054b551ed85c0c8642b7840edd 64460 
sqlline_1.0.2-5_all.deb
Files: 
 4fa03932bf6945aa3be5d181add46662 1945 java extra sqlline_1.0.2-5.dsc
 420643abd6cf1200476b887c35b15130 4940 java extra sqlline_1.0.2-5.debian.tar.xz
 186670bf3e28b6ede9a30b31ea47c937 64460 java extra sqlline_1.0.2-5_all.deb

-----BEGIN PGP SIGNATURE-----
Version: GnuPG v1

iQIcBAEBCgAGBQJTGWXjAAoJECHSBYmXSz6WeYEQAKCFKjmNyJBo3+1JR/ypiVj7
gXynRM5PN6+jPn8HKRgpUgfDLD1GfJKLdXD7sYi1gJZojWFrwBTkgkFTcuY5FKsa
VMek6yBoL8ntEzAdAV45fsj+loKP/2dE3O7TvH0KI3LI+VbsjvOKf7s1kxTyV/sJ
yB5S0Kt73014GzZfz4E0ZNCdiWPuk2iZRQiCqPuvEEVnsgDP2jdQ7fTs5QQOS+wq
sY7jdyVFZLEvG/MDSyG3zi1IFDm7FoFRJA48tM+p90m2IJG48uFqEdD5kWRRHbM3
J96RK/sTVCF/Ut7fK2JmCN52lePXyk1uGXGGTsM6uBzCjlFwQWgiCe8ZdLTkN3YN
uA1hBrMkw/ifCfQaKgdbzXAZb5g7eIA0zwkZD3lS4uguHA0nyIMOrhx25aiMWY6t
81npF7u0IiESur8uc1RfYvG3oRn13Z6kKI1meRR7UqUubFuXlZ5q6x5ZJPejIFop
ZEX0rn/EI93b2KAmdhgDFG2sZX0BHfSneOLk2Oc0H22+CPW2NiWrikvMaEvbNVxa
UPsPpGZUo8w0/Q0Fr4Bw7HQBTVLaeoh3kpzu+fyK0aUP58lpOaFpC84xpFDGK7cy
8jbySMvaW1nJp1EUXPzkG1/2kwXf40qpF0yhGBI5lgCAoC6qyZXeu7sAPCdRjkCH
EtE/FSOP+jpH4QvuuBub
=I0rB
-----END PGP SIGNATURE-----

--- End Message ---
__
This is the maintainer address of Debian's Java team
<http://lists.alioth.debian.org/cgi-bin/mailman/listinfo/pkg-java-maintainers>. 
Please use
debian-j...@lists.debian.org for discussions and questions.

Reply via email to