Skip to content

Commit

Permalink
Ssh2 build (#9)
Browse files Browse the repository at this point in the history
Added libssh2 build script.
Refactor - moved agent init and auth functions to outside Session class.
Fixed double de-allocation of more than one channel from the same session.
Added session property to channel for parent session of channel.
Refactoring - made agent related functions available as Cython functions under ssh2.agent that can be cimported.
Fixed agent authentication error/exception handling.
Added authentication error handling session tests.
Added SFTPIOError exception.
Added last_errno and set_last_error session functions.
Added raising SFTPIOError on sftp mkdir errors.
Added socket object and file descriptor attributes to session object for better de-allocation of sockets and socket use via C-API.
Updated changelog.
Added bytes conversion on SFTP mkdir and mkdir test.
Re-generated C files for updated cython.
Implemented hostkey_hash session method for computing host key hash and test.
Minor code updates for performance.
Updated doc strings.
Fixed sftp readdir_ex long entry, added test. SFTP  performance improvements.
  • Loading branch information
pkittenis committed Oct 5, 2017
1 parent bf46014 commit 7080f34
Show file tree
Hide file tree
Showing 28 changed files with 10,081 additions and 5,280 deletions.
19 changes: 18 additions & 1 deletion Changelog.rst
@@ -1,11 +1,28 @@
Change Log
=============

0.6.0
++++++

Changes
---------

* Implemented `last_errno` and `set_last_error` session functions
* Agent authentication errors raise exceptions
* C-API refactor
* SFTP IO errors raise exceptions

Fixes
-------

* Crash on de-allocation of channel in certain cases
* SFTP ``readdir_ex`` directory listing (long entry) was not returned correctly

0.5.5
++++++

Changes
--------
---------

* Accept both bytes and unicode parameters in authentication with public key from memory.

Expand Down
6 changes: 6 additions & 0 deletions ci/build-ssh2.sh
@@ -0,0 +1,6 @@
#!/bin/bash -xe

mkdir -p src && cd src
cmake ../libssh2 -DBUILD_SHARED_LIBS=ON -DENABLE_ZLIB_COMPRESSION=ON \
-DENABLE_CRYPT_NONE=ON -DENABLE_MAC_NONE=ON -DCRYPTO_BACKEND=OpenSSL
cmake --build . --config Release
2 changes: 2 additions & 0 deletions setup.py
Expand Up @@ -24,6 +24,8 @@
ext = 'pyx' if USING_CYTHON else 'c'
sources = glob('ssh2/*.%s' % (ext,))
_libs = ['ssh2'] if platform.system() != 'Windows' else [
# For libssh2 OpenSSL backend on Windows.
# Windows native WinCNG is used by default.
# 'libeay32', 'ssleay32',
'Ws2_32', 'libssh2', 'user32']

Expand Down

0 comments on commit 7080f34

Please sign in to comment.