You always forget SSH1 ...
Этот коммит содержится в:
родитель
56ee212641
Коммит
fb5769b4be
@ -52,7 +52,7 @@ static int wait_auth1_status(SSH_SESSION *session) {
|
||||
}
|
||||
|
||||
static int send_username(SSH_SESSION *session, const char *username) {
|
||||
STRING *user = NULL;
|
||||
ssh_string user = NULL;
|
||||
/* returns SSH_AUTH_SUCCESS or SSH_AUTH_DENIED */
|
||||
if(session->auth_service_asked) {
|
||||
return session->auth_service_asked;
|
||||
@ -96,11 +96,11 @@ int ssh_userauth1_none(SSH_SESSION *session, const char *username){
|
||||
}
|
||||
|
||||
/*
|
||||
int ssh_userauth_offer_pubkey(SSH_SESSION *session, char *username,int type, STRING *publickey){
|
||||
STRING *user;
|
||||
STRING *service;
|
||||
STRING *method;
|
||||
STRING *algo;
|
||||
int ssh_userauth_offer_pubkey(SSH_SESSION *session, char *username,int type, ssh_string publickey){
|
||||
ssh_string user;
|
||||
ssh_string service;
|
||||
ssh_string method;
|
||||
ssh_string algo;
|
||||
int err=SSH_AUTH_ERROR;
|
||||
if(!username)
|
||||
if(!(username=session->options->username)){
|
||||
@ -137,17 +137,17 @@ int ssh_userauth_offer_pubkey(SSH_SESSION *session, char *username,int type, STR
|
||||
* \todo implement ssh1 public key
|
||||
*/
|
||||
int ssh_userauth1_offer_pubkey(SSH_SESSION *session, const char *username,
|
||||
int type, STRING *pubkey) {
|
||||
int type, ssh_string pubkey) {
|
||||
return SSH_AUTH_DENIED;
|
||||
}
|
||||
|
||||
/*
|
||||
int ssh_userauth_pubkey(SSH_SESSION *session, char *username, STRING *publickey, PRIVATE_KEY *privatekey){
|
||||
STRING *user;
|
||||
STRING *service;
|
||||
STRING *method;
|
||||
STRING *algo;
|
||||
STRING *sign;
|
||||
int ssh_userauth_pubkey(SSH_SESSION *session, char *username, ssh_string publickey, PRIVATE_KEY *privatekey){
|
||||
ssh_string user;
|
||||
ssh_string service;
|
||||
ssh_string method;
|
||||
ssh_string algo;
|
||||
ssh_string sign;
|
||||
int err=SSH_AUTH_ERROR;
|
||||
if(!username)
|
||||
if(!(username=session->options->username)){
|
||||
@ -190,7 +190,7 @@ int ssh_userauth_pubkey(SSH_SESSION *session, char *username, STRING *publickey,
|
||||
|
||||
int ssh_userauth1_password(SSH_SESSION *session, const char *username,
|
||||
const char *password) {
|
||||
STRING *pwd = NULL;
|
||||
ssh_string pwd = NULL;
|
||||
int rc;
|
||||
|
||||
rc = send_username(session, username);
|
||||
|
@ -76,7 +76,7 @@ int channel_open_session1(CHANNEL *chan) {
|
||||
int channel_request_pty_size1(CHANNEL *channel, const char *terminal, int col,
|
||||
int row) {
|
||||
SSH_SESSION *session = channel->session;
|
||||
STRING *str = NULL;
|
||||
ssh_string str = NULL;
|
||||
|
||||
str = string_from_char(terminal);
|
||||
if (str == NULL) {
|
||||
@ -181,7 +181,7 @@ int channel_request_shell1(CHANNEL *channel) {
|
||||
|
||||
int channel_request_exec1(CHANNEL *channel, const char *cmd) {
|
||||
SSH_SESSION *session = channel->session;
|
||||
STRING *command = NULL;
|
||||
ssh_string command = NULL;
|
||||
|
||||
command = string_from_char(cmd);
|
||||
if (command == NULL) {
|
||||
@ -206,7 +206,7 @@ int channel_request_exec1(CHANNEL *channel, const char *cmd) {
|
||||
|
||||
static int channel_rcv_data1(SSH_SESSION *session, int is_stderr) {
|
||||
CHANNEL *channel = session->channels;
|
||||
STRING *str = NULL;
|
||||
ssh_string str = NULL;
|
||||
|
||||
str = buffer_get_ssh_string(session->in_buffer);
|
||||
if (str == NULL) {
|
||||
|
Загрузка…
x
Ссылка в новой задаче
Block a user