1libssh2_session_startup(3) libssh2 libssh2_session_startup(3)
2
3
4
6 libssh2_session_startup - begin transport layer
7
9 #include <libssh2.h>
10
11 int
12 libssh2_session_startup(LIBSSH2_SESSION *session, int socket);
13
15 Starting in libssh2 version 1.2.8 this function is considered depre‐
16 cated. Use libssh2_session_handshake(3) instead.
17
18 session - Session instance as returned by libssh2_session_init_ex(3)
19
20 socket - Connected socket descriptor. Typically a TCP connection though
21 the protocol allows for any reliable transport and the library will at‐
22 tempt to use any berkeley socket.
23
24 Begin transport layer protocol negotiation with the connected host.
25
27 Returns 0 on success, negative on failure.
28
30 LIBSSH2_ERROR_SOCKET_NONE - The socket is invalid.
31
32 LIBSSH2_ERROR_BANNER_SEND - Unable to send banner to remote host.
33
34 LIBSSH2_ERROR_KEX_FAILURE - Encryption key exchange with the remote
35 host failed.
36
37 LIBSSH2_ERROR_SOCKET_SEND - Unable to send data on socket.
38
39 LIBSSH2_ERROR_SOCKET_DISCONNECT - The socket was disconnected.
40
41 LIBSSH2_ERROR_PROTO - An invalid SSH protocol response was received on
42 the socket.
43
44 LIBSSH2_ERROR_EAGAIN - Marked for non-blocking I/O but the call would
45 block.
46
48 libssh2_session_free(3) libssh2_session_init_ex(3)
49
50
51
52libssh2 0.15 1 Jun 2007 libssh2_session_startup(3)