Xojo Conferences

Platforms to show: All Mac Windows Linux Cross-Platform

SSH2SessionMBS constants

Error Codes

Constant Value Description
kErrorAgentProtocol -42 Invalid agent protocol.
kErrorAlloc -6 Out of memory.
kErrorAuthenticationFailed -18 Authentication failed.
kErrorBadSocket -45 Bad socket handle.
kErrorBadUse -39 Bad use.
kErrorBannerRecv -2 Failed to receive banner.
kErrorBannerSend -3 Failed to send banner.
kErrorBufferTooSmall -38 Memory buffer is too small.
kErrorChannelClosed -26 Channel is already closed.
kErrorChannelEofSent -27 Chanel sent EOF.
kErrorChannelFailure -21 Generic error on a channel.
kErrorChannelOutoforder -20 Channel commands out of order.
kErrorChannelPacketExceeded -25 Channel packet exceeded.
kErrorChannelRequestDenied -22 Channel request denied.
kErrorChannelUnknown -23 Unknown channel.
kErrorChannelWindowExceeded -24 Channel window exceeded.
kErrorCompress -40 Compression error.
kErrorDecrypt -12 Error with decryption.
kErrorEagain -37 Please try again later.
kErrorEncrypt -44 Error on encrypting.
kErrorFile -16 File IO error.
kErrorHostkeyInit -10 Failed to init host key.
kErrorHostkeySign -11 Failed to sign host key.
kErrorInval -34 Input value error.
kErrorInvalidMac -4 Invalid MAC address.
kErrorInvalidPollType -35 Invalid poll type.
kErrorKexFailure -5 Key exchange failed.
kErrorKeyExchangeFailure -8 Key exchange failed.
kErrorKnownHosts -46 Unknown host.
kErrorMethodNone -17 No method.
kErrorMethodNotSupported -33 Method not supported.
kErrorNone 0 No error.
kErrorOutOfBoundary -41 Out of Boundary.
kErrorPasswordExpired -15 Password expired.
kErrorProto -14 Protocol error.
kErrorPublickeyProtocol -36 Publickey protocol failed.
kErrorPublickeyUnverified -19 Publickey is not verified.
kErrorRequestDenied -32 Request denied.
kErrorScpProtocol -28 Error with SCP protocol.
kErrorSftpProtocol -31 Error with SFTP protocol.
kErrorSocketDisconnect -13 Socket got disconnected.
kErrorSocketNone -1 No socket error.
kErrorSocketRecv -43 Socket receive failed.
kErrorSocketSend -7 Socket send failed.
kErrorSocketTimeout -30 Socket timeout.
kErrorTimeout -9 Timeout.
kErrorZlib -29 Error with zlib (Compression).


Constant Value Description
kFlagCompress 2 Set options for the created session. flag is the option to set, while value is typically set to 1 or 0 to enable or disable the option.
If set - before the connection negotiation is performed - libssh2 will try to negotiate compression enabling for this connection. By default libssh2 will not attempt to use compression.
kFlagSigPipe 1 Set options for the created session. flag is the option to set, while value is typically set to 1 or 0 to enable or disable the option.
If set, libssh2 will not attempt to block SIGPIPEs but will let them trigger from the underlying socket layer.

Hash Type

Constant Value Description
kHostKeyHashMD5 1 MD5
kHostKeyHashSHA1 2 SHA1

MBS Xojo blog