diff options
Diffstat (limited to '')
-rw-r--r-- | src/session.h | 16 |
1 files changed, 13 insertions, 3 deletions
diff --git a/src/session.h b/src/session.h index 2a4ea8d..50b5fe8 100644 --- a/src/session.h +++ b/src/session.h @@ -1,9 +1,19 @@ -#ifndef _SESSION_H_ -#define _SESSION_H_ +#ifndef SESSION_H_ +#define SESSION_H_ #include <libssh/libssh.h> -#include "util.h" +#define SESSION_END (SSH_CLOSED | SSH_CLOSED_ERROR) + +/* A userdata struct for session. */ +struct session_data_struct { + /* Pointer to the channel the session will allocate. */ + ssh_channel channel; + int auth_attempts; + int authenticated; + // ssh user name when login + char * login_username; +}; void handle_session(ssh_event event, ssh_session session); |