The libssh API

Overview

The libssh library is implementing the SSH protocols and some of its extensions. Moreā€¦

// global functions

int
ssh_finalize(void);

int
ssh_init(void);

Detailed Documentation

The libssh library is implementing the SSH protocols and some of its extensions.

This group of functions is mostly used to implment a SSH client. Some function are needed to implement a SSH server too.

Global Functions

int
ssh_finalize(void)

Finalize and cleanup all libssh and cryptographic data structures.

This function should only be called once, at the end of the program!

Returns:

0 on succes, -1 if an error occured.

0 otherwise

int
ssh_init(void)

Initialize global cryptographic data structures.

This function should only be called once, at the beginning of the program, in the main thread. It may be omitted if your program is not multithreaded.

Returns:

0 on success, -1 if an error occured.