added client callbacks to ssh server
This commit is contained in:
@@ -0,0 +1,3 @@
|
||||
target_sources( ${PROJECT_NAME}
|
||||
PUBLIC client.c
|
||||
)
|
||||
|
||||
22
source/client_source/client.c
Normal file
22
source/client_source/client.c
Normal file
@@ -0,0 +1,22 @@
|
||||
#include "client.h"
|
||||
#include <string.h>
|
||||
#include <tart.h>
|
||||
|
||||
|
||||
int client_auth(void* userdata);
|
||||
|
||||
int client_init(void* cli) {
|
||||
return 0;
|
||||
}
|
||||
|
||||
int client_update(ssh_terminal_data* td, void* cli) {
|
||||
client* c = (client*)cli;
|
||||
|
||||
strcpy(td->outputBuffer, "testing 1212\n\r");
|
||||
return 0;
|
||||
}
|
||||
|
||||
int client_stop(void* cli) {
|
||||
return 0;
|
||||
}
|
||||
|
||||
@@ -1,6 +1,16 @@
|
||||
#ifndef CLIENT_H
|
||||
#define CLIENT_H
|
||||
#include "../ssh_server_client.h"
|
||||
|
||||
typedef struct {} client;
|
||||
|
||||
int client_auth(void* userdata);
|
||||
|
||||
int client_init(void*);
|
||||
|
||||
int client_update(ssh_terminal_data* td, void*);
|
||||
|
||||
int client_stop(void*);
|
||||
|
||||
|
||||
#endif
|
||||
|
||||
Reference in New Issue
Block a user