summaryrefslogtreecommitdiffstats
path: root/src
Commit message (Collapse)AuthorAgeFilesLines
* session: Always request POLLINColin Walters2013-11-091-3/+1
| | | | | | | The assumption is that if libssh functions are being invoked, we want to read data. Reviewed-by: Andreas Schneider <asn@cryptomilk.org>
* Add ssh_get_poll_flags()Colin Walters2013-11-092-0/+30
| | | | | | | | | | For integration with an external mainloop, we need to know how to replicate libssh's internal poll() calls. We originally through ssh_get_status() was that API, but it's not really - those flags only get updated from the *result* of a poll(), where what we really need is to know how libssh would *start* a poll(). Reviewed-by: Andreas Schneider <asn@cryptomilk.org>
* client: If we have a pre-connected FD, set state to SOCKET_CONNECTEDColin Walters2013-11-091-0/+1
| | | | | | | Otherwise applications providing their own fd end up tripping an assertion, since the session is just in _CONNECTING. Reviewed-by: Andreas Schneider <asn@cryptomilk.org>
* dh: Move ssh_get_hexa() and ssh_print_hexa() down.Andreas Schneider2013-11-061-57/+57
| | | | | This way they are in the documentation block for the session and we get documentation for them.
* dh: Add new ssh_get_publickey_hash() function.Andreas Schneider2013-11-061-19/+102
|
* doc: Fix doxygen warnings.Andreas Schneider2013-11-042-6/+7
|
* Fix cast warnings on 64bitsAris Adamantiadis2013-11-042-3/+3
|
* remove warnings on OSX (workaround)Aris Adamantiadis2013-11-041-2/+2
|
* logging: fix wordingAris Adamantiadis2013-11-041-2/+2
|
* curve25519: include reference implementationAris Adamantiadis2013-11-033-7/+283
|
* socket: Fix check for pending data.Aris Adamantiadis2013-11-031-3/+3
| | | | | | BUG: https://red.libssh.org/issues/119 Reviewed-by: Andreas Schneider <asn@cryptomilk.org>
* server: Fix ssh_execute_server_callbacks() client executionNicolas Viennot2013-11-031-4/+2
| | | | | | | | | | When the public key auth handler is executed and returns SSH_OK, ssh_execute_server_callbacks() still runs some client callbacks, which may set rc to SSH_AGAIN, which triggers a default reply on auth, denying auth. Signed-off-by: Nicolas Viennot <nicolas@viennot.biz> Reviewed-by: Andreas Schneider <asn@cryptomilk.org>
* server kex: enable delayed compressionNicolas Viennot2013-11-031-4/+14
| | | | | | | The code is careful to reenable compression when rekeying. Signed-off-by: Nicolas Viennot <nicolas@viennot.biz> Reviewed-by: Andreas Schneider <asn@cryptomilk.org>
* session: Make sure we correctly burn the buffer.Andreas Schneider2013-11-031-1/+1
|
* wrapper: Make sure we really burn the buffer.Andreas Schneider2013-11-031-1/+1
|
* server: fix pubkey reply for key probesJon Simons2013-11-021-1/+9
| | | | | | | | | | | | | | | Per RFC 4252, it is required to send back only one of either SSH_MSG_USERAUTH_PK_OK or SSH_MSG_USERAUTH_FAILURE for public key probes. Update the handling of 'auth_pubkey_function' to send back PK_OK instead of SSH_MSG_USERAUTH_SUCCESS for the case that the state of the message at hand is SSH_PUBLICKEY_STATE_NONE. With this change, it is now possible to process an initial key probe and then subsequent signature validation using the server callbacks. Reviewed-by: Andreas Schneider <asn@cryptomilk.org>
* ssh_options_get can now return ProxyCommandWilliam Orr2013-11-021-0/+9
| | | | Reviewed-by: Andreas Schneider <asn@cryptomilk.org>
* connect: fix memory leak in ssh_selectJon Simons2013-10-311-2/+9
| | | | | | | | Balance 'ssh_event_add_fd' with 'ssh_event_remove_fd' in 'ssh_select'. BUG: https://red.libssh.org/issues/128 Reviewed-by: Andreas Schneider <asn@cryptomilk.org>
* poll: fix leak in ssh_poll_ctx_freeJon Simons2013-10-311-1/+5
| | | | | | | | | Fix a memory leak in 'ssh_poll_ctx_free': issue 'ssh_poll_free' to remove the poll handle from its context and free it. BUG: https://red.libssh.org/issues/128 Reviewed-by: Andreas Schneider <asn@cryptomilk.org>
* bind: fix leak in ssh_bind_accept error pathJon Simons2013-10-241-2/+1
| | | | | Use 'ssh_socket_free' to cleanup if 'ssh_bind_accept_fd' fails, to be sure to free the ssh_socket in/out buffers.
* auth: docs: Fix typo optoins -> optionsColin Walters2013-10-231-6/+6
| | | | | | I'm just getting my feet wet with this codebase. Reviewed-by: Andreas Schneider <asn@cryptomilk.org>
* channel: Reinit the buffer and reset the state on error.Andreas Schneider2013-10-201-23/+46
| | | | BUG: https://red.libssh.org/issues/126
* channel: Fix ssh_global_request_termination().Andreas Schneider2013-10-201-1/+1
| | | | BUG: https://red.libssh.org/issues/126
* pki: Don't leak a buffer.Andreas Schneider2013-10-191-0/+2
|
* pki_crpypto: Fix ecdsa signature to blob.Andreas Schneider2013-10-181-12/+26
| | | | BUG: https://red.libssh.org/issues/118
* pki: Add support for ECDSA private key signing.Andreas Schneider2013-10-181-14/+34
|
* pki: Add the type as a char pointer.Andreas Schneider2013-10-182-2/+5
|
* wrapper: Add more evp functions.Andreas Schneider2013-10-181-0/+24
|
* client: Fix the build.Andreas Schneider2013-10-181-1/+0
|
* scp: Fixed result of ssh_scp_string_mode() to get SCP working.Oliver Stöneberg2013-10-181-1/+1
| | | | Reviewed-by: Andreas Schneider <asn@cryptomilk.org>
* client: Added a missing NULL pointer check.Oliver Stöneberg2013-10-181-8/+13
| | | | Reviewed-by: Andreas Schneider <asn@cryptomilk.org>
* channel: Fix packets termination timeout in global_request().Andreas Schneider2013-10-011-1/+1
| | | | BUG: https://red.libssh.org/issues/126
* session: Try the ecdsa default key first.Andreas Schneider2013-10-011-0/+11
|
* callbacks: add support for auth_none_functionTristan CACQUERAY2013-09-271-0/+11
|
* kex: implement curve25519-sha256@libssh.orgAris Adamantiadis2013-09-277-2/+346
|
* channels: Correctly handle timeouts in channel functions.Andreas Schneider2013-09-171-5/+14
|
* channel: Use the correct timeout option in channel_open().Andreas Schneider2013-09-171-1/+5
| | | | BUG: https://red.libssh.org/issues/124
* session: Document return value of ssh_get_serverbanner().Andreas Schneider2013-09-161-0/+3
| | | | BUG: https://red.libssh.org/issues/122
* session: Remove obsolete status variables.Andreas Schneider2013-09-161-6/+4
| | | | BUG: https://red.libssh.org/issues/121
* client: Add example code for ssh_get_openssh_version().Andreas Schneider2013-09-161-0/+8
| | | | BUG: https://red.libssh.org/issues/120
* channels: Correctly decrement timeout value in ssh_channel_accept().Andreas Schneider2013-09-161-2/+5
| | | | BUG: https://red.libssh.org/issues/116
* channel: Document SSH_AGAIN in ssh_channel_read().Andreas Schneider2013-09-161-2/+2
| | | | BUG: https://red.libssh.org/issues/115
* doc: Improve the PKI documentation a bit.Andreas Schneider2013-09-101-14/+18
|
* doc: Update documentation of ssh_set_blocking().Andreas Schneider2013-09-091-2/+0
| | | | This should work correctly in libssh 0.6.0. If not then you hit a bug.
* ecdh: Refactor ecdh_build_k to check errors codes.Andreas Schneider2013-08-131-14/+40
|
* channel: Refactor channel_write_common() code.Andreas Schneider2013-08-131-16/+37
| | | | This makes it easier to read and easier to debug.
* channel: Make channel_write_common() static.Andreas Schneider2013-08-131-2/+4
|
* channel: Use MIN macro in channel_write_common().Andreas Schneider2013-08-131-2/+4
|
* scp: Document more scp functionts.Andreas Schneider2013-08-121-3/+31
|
* server kex: Fix server side compression typoNicolas Viennot2013-08-051-2/+3
| | | | | | | | The original code had a typo (COMP was CRYPT). This fixes the zlib compression method. Signed-off-by: Nicolas Viennot <nicolas@viennot.biz> Reviewed-by: Andreas Schneider <asn@cryptomilk.org>