diff options
author | Julien Dessaux | 2018-06-20 13:23:48 +0200 |
---|---|---|
committer | Julien Dessaux | 2018-06-20 13:23:48 +0200 |
commit | 8c04f0d56d88ebea808d5505dcee07e8d197e360 (patch) | |
tree | 81f8e3f59c17ab234eb95c7812adb0054779a117 /src/client.h | |
parent | Initial import with working simple server based on libssh examples (diff) | |
download | bastion-8c04f0d56d88ebea808d5505dcee07e8d197e360.tar.gz bastion-8c04f0d56d88ebea808d5505dcee07e8d197e360.tar.bz2 bastion-8c04f0d56d88ebea808d5505dcee07e8d197e360.zip |
Made a working ssh proxy server
Diffstat (limited to 'src/client.h')
-rw-r--r-- | src/client.h | 22 |
1 files changed, 22 insertions, 0 deletions
diff --git a/src/client.h b/src/client.h new file mode 100644 index 0000000..3826b5f --- /dev/null +++ b/src/client.h @@ -0,0 +1,22 @@ +#ifndef CLIENT_H_ +#define CLIENT_H_ + +#include <libssh/libssh.h> + +#include "proxy.h" +#include "session.h" + +/* A userdata struct for channel. */ +struct client_channel_data_struct { + /* Event which is used to poll */ + ssh_event event; + ssh_session my_session; + ssh_channel my_channel; + ssh_channel proxy_channel; + struct ssh_channel_callbacks_struct * client_channel_cb; +}; + +struct client_channel_data_struct* client_dial(ssh_event event, struct proxy_channel_data_struct *pdata, const char * hostname); +void client_cleanup(struct client_channel_data_struct *cdata); + +#endif |