From: Russ Tyndall Date: Fri, 9 Oct 2015 15:30:40 +0000 (-0400) Subject: merging in master from kpe.io X-Git-Tag: v6.7.0~7 X-Git-Url: http://git.kpe.io/?p=clsql.git;a=commitdiff_plain;h=eeb36233c9881cd2bb141f7a3241afbe82feda8d;hp=ed507b70a9d910372d1378cf0a7754fc88171183 merging in master from kpe.io --- diff --git a/ChangeLog b/ChangeLog index 63a2b16..ccc8afc 100644 --- a/ChangeLog +++ b/ChangeLog @@ -1,3 +1,9 @@ + +2015-08-12 Kevin Rosenberg + * Version 6.6.3 release + * db-oracle/oracle-sql.lisp: Patch for PostgreSQL socket interface + for unicode characters. Thanks to Jason Melbye. + 2015-06-02 Daniel Kochmański * clsql.asd, sql/package.lisp: Add ECL compatibility fixes * sql/db-interface.lisp: Fix declaration typo @@ -7,6 +13,11 @@ operator / expression. Needed for correct regex handling EG: [E "some string"]=> E'some string' +2015-03-30 Kevin Rosenberg + * Version 6.6.2 release + * db-oracle/oracle-sql.lisp: Remove extra hyphen, thanks to + Thomas Vossen + 2015-03-24 Russ Tyndall * sql/oodml.lisp: fixed call-next-method in the base of read-sql-value and replaced with a continuable @@ -18,6 +29,12 @@ * {uffi,db-mysql}/Makefile: remove -pie build hardening for which caused load issues for Linux Mint +2015-03-18 Kevin Rosenberg + * Version 6.6.1 release + * {uffi,db-mysql}/Makefile: Remove pie from build + hardening options for Debian/Ubuntu systems. Thanks to + DJ and Russ Tyndall + 2015-02-26 Kevin Rosenberg * Version 6.6.0 release * {uffi,db-mysql}/Makefile: Add build hardening for Debian diff --git a/NEWS b/NEWS index d1e96f2..b69ad00 100644 --- a/NEWS +++ b/NEWS @@ -36,7 +36,7 @@ well as the initial regression suite and most of the new documentation. He has contributed to many of the re-design decisions and new code for CLSQL. -CLSQL's home is http://clsql.b9.com +CLSQL's home is http://clsql.kpe.io Enjoy! diff --git a/README b/README index 3caff9f..8fdfd89 100644 --- a/README +++ b/README @@ -3,7 +3,7 @@ Rosenberg. It includes both functional and object oriented subsystems for data definition and manipulation as well as an integrated symbolic SQL syntax. -CLSQL supports a number of RDBMS and uses the UFFI (http://uffi.b9.com) +CLSQL supports a number of RDBMS and uses the UFFI (http://uffi.kpe.io) library for compatibility with Allegro CL, Lispworks, CMUCL, SBCL and OpenMCL. @@ -14,7 +14,7 @@ in 2004, development of has stopped on these incorporated projects. - Paul Meurer's SQL/ODBC - Cadabra's Oracle interface -CLSQL's home is http://clsql.b9.com. +CLSQL's home is http://clsql.kpe.io. Documentation is available as a PDF file in doc/clsql.pdf and as HTML files in doc/html.tar.gz. @@ -24,7 +24,7 @@ CONTRIBUTING ------------ If you would like to report a bug please do so through the clsql -mailing list. http://lists.b9.com/mailman/listinfo/CLSQL +mailing list. http://lists.kpe.io/mailman/listinfo/CLSQL Patches are welcome. It will be much easier for us to incorporate if you use [git](http://git-scm.com/). Please keep distinct changes in diff --git a/db-mysql/Makefile b/db-mysql/Makefile index d67afe1..de42b71 100644 --- a/db-mysql/Makefile +++ b/db-mysql/Makefile @@ -30,7 +30,7 @@ CFLAGS:=-I /usr/local/include/mysql -I /usr/include/mysql -I /sw/include/mysql - LDFLAGS:=-L/usr/local/lib64/mysql -L/usr/local/lib/mysql -L/usr/lib64/mysql -L/usr/lib/mysql -L/sw/lib -L/opt/local/lib/mysql -L/opt/local/lib/mysql5/mysql -L/usr/local/mysql/lib -L/usr/lib/gcc/i686-pc-cygwin/3.4.4 -lmysqlclient -lz -lc CFLAGS32:=-I /usr/local/include/mysql -I /usr/include/mysql -I /sw/include/mysql -I /opt/local/include/mysql -I /opt/local/include/mysql5/mysql -I /usr/local/mysql/include -m32 -LDFLAGS32:=-L/lib32 -L/usr/lib32 -melf_i386 -lmysqlclient -lz -lc +LDFLAGS32:=-L/lib32 -L/usr/lib32 -lmysqlclient -lz -lc ifneq ($(OS_CYGWIN),0) CFLAGS:=-I /cygdrive/c/Program\ Files/MySQL/MySQL\ Server\ 5.0/include @@ -64,14 +64,14 @@ else else ifneq ($(OS_LINUX64),0) gcc $(CFLAGS) -fPIC -c $(source) -o $(object) - ld $(LDFLAGS) -shared -soname=$(base) $(object) -o $(shared64_lib) + gcc $(LDFLAGS) -fPIC -shared -Wl,-soname=$(base) -lc $(object) -o $(shared64_lib) rm $(object) @echo "Ensure that you have multiarch i386 build tools and libraries if you want to build 32-bit library" -gcc $(CFLAGS32) -fPIC -c $(source) -o $(object) - -ld -shared -soname=$(base) $(object) $(LDFLAGS32) -o $(shared_lib) + -gcc $(LDFLAGS) -fPIC -shared -Wl,-soname=$(base) -lc $(object) $(LDFLAGS32) -o $(shared_lib) else gcc $(CFLAGS) -fPIC -c $(source) -o $(object) - ld -shared -soname=$(base) $(object) $(LDFLAGS) -o $(shared_lib) + gcc -m32 $(LDFLAGS) -fPIC -shared -Wl,-soname=$(base) -lc $(object) $(LDFLAGS) -o $(shared_lib) endif endif endif diff --git a/db-oracle/oracle-sql.lisp b/db-oracle/oracle-sql.lisp index f8f5836..9460011 100644 --- a/db-oracle/oracle-sql.lisp +++ b/db-oracle/oracle-sql.lisp @@ -514,7 +514,7 @@ the length of that format.") (oci-stmt-prepare (deref-vp stmthp) (deref-vp errhp) c-stmt-string - (uffi:foreign-string-length c--stmt-string) + (uffi:foreign-string-length c-stmt-string) +oci-ntv-syntax+ +oci-default+ :database db) (oci-attr-get (deref-vp stmthp) +oci-htype-stmt+ diff --git a/db-postgresql-socket/postgresql-socket-api.lisp b/db-postgresql-socket/postgresql-socket-api.lisp index 879e5bb..40dc86a 100644 --- a/db-postgresql-socket/postgresql-socket-api.lisp +++ b/db-postgresql-socket/postgresql-socket-api.lisp @@ -234,6 +234,14 @@ socket interface" (int32 pid) (int32 key)) +(defun read-bytes (socket length) + "Read a byte array of the given length from a stream." + (declare (type stream socket) + (type fixnum length) + (optimize (speed 3) (safety 0))) + (let ((result (make-array length :element-type '(unsigned-byte 8)))) + (read-sequence result socket) + result)) (defun read-socket-sequence (stream length &optional (allow-wide t)) (declare (stream stream) @@ -487,10 +495,16 @@ troubles." :database database :user user :password (or password "")))) -(defun encrypt-md5 (plaintext salt) - (string-downcase - (format nil "~{~2,'0X~}" - (coerce (md5sum-string (concatenate 'string plaintext salt)) 'list)))) +(defun byte-sequence-to-hex-string (sequence) + (string-downcase (format nil "~{~2,'0X~}" (coerce sequence 'list)))) + +(defun encrypt-password-md5 (password user salt) + (let ((pass1 (byte-sequence-to-hex-string + (md5::md5sum-string (concatenate 'string password user))))) + (byte-sequence-to-hex-string + (md5:md5sum-sequence (concatenate '(vector (unsigned-byte 8)) + (map '(vector (unsigned-byte 8)) #'char-code pass1) + salt))))) (defun reopen-postgresql-connection (connection) "Reopen the given PostgreSQL connection. Closes any existing @@ -532,10 +546,11 @@ connection, if it is still open." (postgresql-connection-password connection) salt))) (force-output socket)) (5 - (let ((salt (read-socket-sequence socket 4 nil))) - (let* ((pwd2 (encrypt-md5 (postgresql-connection-password connection) - (postgresql-connection-user connection))) - (pwd (encrypt-md5 pwd2 salt))) + (let ((salt (read-bytes socket 4))) + (let ((pwd (encrypt-password-md5 + (postgresql-connection-password connection) + (postgresql-connection-user connection) + salt))) (send-encrypted-password-message socket (concatenate 'string "md5" pwd)))) diff --git a/db-postgresql-socket/postgresql-socket-package.lisp b/db-postgresql-socket/postgresql-socket-package.lisp index 718667b..fbedb51 100644 --- a/db-postgresql-socket/postgresql-socket-package.lisp +++ b/db-postgresql-socket/postgresql-socket-package.lisp @@ -19,7 +19,7 @@ #+lispworks (require "comm") (defpackage #:postgresql-socket - (:use #:cl md5) + (:use #:cl #:md5) (:export #:pgsql-ftype #:pgsql-ftype#bytea #:pgsql-ftype#int2 @@ -56,4 +56,3 @@ #:copy-cursor-row #:skip-cursor-row )) - diff --git a/debian/changelog b/debian/changelog index 0d2b64a..4d133fb 100644 --- a/debian/changelog +++ b/debian/changelog @@ -1,8 +1,27 @@ +cl-sql (6.6.3-1) unstable; urgency=medium + + * New upstream + * Use gcc for linking (closes:755064) + + -- Kevin M. Rosenberg Sat, 29 Aug 2015 18:13:55 -0600 + +cl-sql (6.6.2-1) unstable; urgency=medium + + * New upstream + + -- Kevin M. Rosenberg Mon, 30 Mar 2015 14:46:53 -0600 + +cl-sql (6.6.1-1) unstable; urgency=medium + + * {uffi,db-mysql}/Makefile: Change build hardening to +all,-pie + + -- Kevin M. Rosenberg Wed, 18 Mar 2015 21:30:11 -0600 + cl-sql (6.6.0-1) unstable; urgency=medium * New upstream * {uffi,db-mysql}/Makefile: Add build hardening - + -- Kevin M. Rosenberg Thu, 26 Feb 2015 15:32:46 -0700 cl-sql (6.5.0-1) unstable; urgency=low diff --git a/debian/control b/debian/control index 524a4c9..8a681c1 100644 --- a/debian/control +++ b/debian/control @@ -4,9 +4,9 @@ Priority: extra Maintainer: Kevin M. Rosenberg Build-Depends: dh-lisp, debhelper (>= 7.0.0), libmysqlclient-dev, libpq-dev Standards-Version: 3.9.6 -Homepage: http://clsql.b9.com/ -Vcs-Git: git://git.b9.com/clsql.git -Vcs-Browser: http://git.b9.com/?p=clsql.git +Homepage: http://clsql.kpe.io/ +Vcs-Git: git://git.kpe.io/clsql.git +Vcs-Browser: http://git.kpe.io/?p=clsql.git Package: cl-sql Architecture: all diff --git a/debian/copyright b/debian/copyright index f9364eb..71a7cb7 100644 --- a/debian/copyright +++ b/debian/copyright @@ -1,7 +1,7 @@ Debian Copyright Section ======================== -Upstream Source URL: http://files.b9.com/clsql +Upstream Source URL: http://files.kpe.io/clsql Upstream Author: Kevin M. Rosenberg Debian Maintainer: (Same as upstream) diff --git a/debian/upload.sh b/debian/upload.sh old mode 100755 new mode 100644 index c5d401e..c44c009 --- a/debian/upload.sh +++ b/debian/upload.sh @@ -1,4 +1,4 @@ #!/bin/bash -e -dup clsql -Ufiles.b9.com -D/home/ftp/clsql -su \ +dup clsql -Ufiles.kpe.io -D/home/ftp/clsql -su \ -C"(umask 022; cd /srv/www/html/clsql; make install; find . -type d |xargs chmod go+rx; find . -type f | xargs chmod go+r)" $* diff --git a/debian/watch b/debian/watch index b697ecb..1b92d46 100644 --- a/debian/watch +++ b/debian/watch @@ -1,2 +1,2 @@ version=3 -http://files.b9.com/clsql/clsql-([\d\.]*)\.tar\.gz debian uupdate +http://files.kpe.io/clsql/clsql-([\d\.]*)\.tar\.gz debian uupdate diff --git a/doc/clsql.pdf b/doc/clsql.pdf index 4a5cc4c..4922a96 100644 Binary files a/doc/clsql.pdf and b/doc/clsql.pdf differ diff --git a/doc/html.tar.gz b/doc/html.tar.gz index bdc0734..8718c23 100644 Binary files a/doc/html.tar.gz and b/doc/html.tar.gz differ diff --git a/doc/intro.xml b/doc/intro.xml index eb10c69..936cf59 100644 --- a/doc/intro.xml +++ b/doc/intro.xml @@ -86,7 +86,7 @@ &uffi; &clsql; uses &uffi; + url="http://uffi.kpe.io/">&uffi; as a Foreign Function Interface (FFI) to support multiple &cl; implementations. @@ -96,7 +96,7 @@ &md5; &clsql;'s postgresql-socket interface uses Pierre Mai's - md5 + md5 module. diff --git a/tests/README b/tests/README index b3f6efe..aa6a9a6 100644 --- a/tests/README +++ b/tests/README @@ -7,7 +7,7 @@ each database type to be tested. There is an example file in contained in CLSQL's examples directory. These tests require the downloading of the rt package from -http://files.b9.com/. +http://files.kpe.io/. Load clsql.asd or put it somewhere where ASDF can find it and call: diff --git a/uffi/Makefile b/uffi/Makefile index 77203fd..7599380 100644 --- a/uffi/Makefile +++ b/uffi/Makefile @@ -55,11 +55,11 @@ else else ifneq ($(OS_LINUX64),0) gcc $(CFLAGS) -fPIC -DPIC -c $(source) -o $(object) - ld $(LDFLAGS) -shared -soname=$(base) -lc $(object) -o $(shared64_lib) + gcc $(LDFLAGS) -fPIC -shared -Wl,-soname=$(base) -lc $(object) -o $(shared64_lib) rm -f $(object) @echo "Ensure that you have multiarch i386 build tools if you want to build 32-bit library" -gcc -m32 $(CFLAGS) -fPIC -DPIC -c $(source) -o $(object) - -ld -melf_i386 $(LDFLAGS) -shared -soname=$(base) -lc $(object) -o $(shared_lib) + -gcc -m32 $(LDFLAGS) -fPIC -shared -Wl,-soname=$(base) -lc $(object) -o $(shared_lib) else gcc -fPIC -DPIC -c $(source) -o $(object) ld -shared -soname=$(base) -lc $(object) -o $(shared_lib)