• Main Page
  • Related Pages
  • Modules
  • Data Structures
  • Files
  • File List
  • Globals

include/libssh/legacy.h

00001 /*
00002  * This file is part of the SSH Library
00003  *
00004  * Copyright (c) 2010 by Aris Adamantiadis
00005  *
00006  * The SSH Library is free software; you can redistribute it and/or modify
00007  * it under the terms of the GNU Lesser General Public License as published by
00008  * the Free Software Foundation; either version 2.1 of the License, or (at your
00009  * option) any later version.
00010  *
00011  * The SSH Library is distributed in the hope that it will be useful, but
00012  * WITHOUT ANY WARRANTY; without even the implied warranty of MERCHANTABILITY
00013  * or FITNESS FOR A PARTICULAR PURPOSE.  See the GNU Lesser General Public
00014  * License for more details.
00015  *
00016  * You should have received a copy of the GNU Lesser General Public License
00017  * along with the SSH Library; see the file COPYING.  If not, write to
00018  * the Free Software Foundation, Inc., 59 Temple Place - Suite 330, Boston,
00019  * MA 02111-1307, USA.
00020  */
00021 
00022 /* Since libssh.h includes legacy.h, it's important that libssh.h is included
00023  * first. we don't define LEGACY_H now because we want it to be defined when
00024  * included from libssh.h
00025  * All function calls declared in this header are deprecated and meant to be
00026  * removed in future.
00027  */
00028 
00029 #include "libssh/libssh.h"
00030 
00031 #ifndef LEGACY_H_
00032 #define LEGACY_H_
00033 LIBSSH_API void buffer_free(ssh_buffer buffer);
00034 LIBSSH_API void *buffer_get(ssh_buffer buffer);
00035 LIBSSH_API uint32_t buffer_get_len(ssh_buffer buffer);
00036 LIBSSH_API ssh_buffer buffer_new(void);
00037 
00038 LIBSSH_API ssh_channel channel_accept_x11(ssh_channel channel, int timeout_ms);
00039 LIBSSH_API int channel_change_pty_size(ssh_channel channel,int cols,int rows);
00040 LIBSSH_API ssh_channel channel_forward_accept(ssh_session session, int timeout_ms);
00041 LIBSSH_API int channel_close(ssh_channel channel);
00042 LIBSSH_API int channel_forward_cancel(ssh_session session, const char *address, int port);
00043 LIBSSH_API int channel_forward_listen(ssh_session session, const char *address, int port, int *bound_port);
00044 LIBSSH_API void channel_free(ssh_channel channel);
00045 LIBSSH_API int channel_get_exit_status(ssh_channel channel);
00046 LIBSSH_API ssh_session channel_get_session(ssh_channel channel);
00047 LIBSSH_API int channel_is_closed(ssh_channel channel);
00048 LIBSSH_API int channel_is_eof(ssh_channel channel);
00049 LIBSSH_API int channel_is_open(ssh_channel channel);
00050 LIBSSH_API ssh_channel channel_new(ssh_session session);
00051 LIBSSH_API int channel_open_forward(ssh_channel channel, const char *remotehost,
00052     int remoteport, const char *sourcehost, int localport);
00053 LIBSSH_API int channel_open_session(ssh_channel channel);
00054 LIBSSH_API int channel_poll(ssh_channel channel, int is_stderr);
00055 LIBSSH_API int channel_read(ssh_channel channel, void *dest, uint32_t count, int is_stderr);
00056 
00057 LIBSSH_API int channel_read_buffer(ssh_channel channel, ssh_buffer buffer, uint32_t count,
00058     int is_stderr);
00059 
00060 LIBSSH_API int channel_read_nonblocking(ssh_channel channel, void *dest, uint32_t count,
00061     int is_stderr);
00062 LIBSSH_API int channel_request_env(ssh_channel channel, const char *name, const char *value);
00063 LIBSSH_API int channel_request_exec(ssh_channel channel, const char *cmd);
00064 LIBSSH_API int channel_request_pty(ssh_channel channel);
00065 LIBSSH_API int channel_request_pty_size(ssh_channel channel, const char *term,
00066     int cols, int rows);
00067 LIBSSH_API int channel_request_shell(ssh_channel channel);
00068 LIBSSH_API int channel_request_send_signal(ssh_channel channel, const char *signum);
00069 LIBSSH_API int channel_request_sftp(ssh_channel channel);
00070 LIBSSH_API int channel_request_subsystem(ssh_channel channel, const char *subsystem);
00071 LIBSSH_API int channel_request_x11(ssh_channel channel, int single_connection, const char *protocol,
00072     const char *cookie, int screen_number);
00073 LIBSSH_API int channel_send_eof(ssh_channel channel);
00074 LIBSSH_API int channel_select(ssh_channel *readchans, ssh_channel *writechans, ssh_channel *exceptchans, struct
00075         timeval * timeout);
00076 LIBSSH_API void channel_set_blocking(ssh_channel channel, int blocking);
00077 LIBSSH_API int channel_write(ssh_channel channel, const void *data, uint32_t len);
00078 
00079 LIBSSH_API void privatekey_free(ssh_private_key prv);
00080 LIBSSH_API ssh_private_key privatekey_from_file(ssh_session session, const char *filename,
00081     int type, const char *passphrase);
00082 LIBSSH_API void publickey_free(ssh_public_key key);
00083 LIBSSH_API int ssh_publickey_to_file(ssh_session session, const char *file,
00084     ssh_string pubkey, int type);
00085 LIBSSH_API ssh_string publickey_from_file(ssh_session session, const char *filename,
00086     int *type);
00087 LIBSSH_API ssh_public_key publickey_from_privatekey(ssh_private_key prv);
00088 LIBSSH_API ssh_string publickey_to_string(ssh_public_key key);
00089 LIBSSH_API ssh_message ssh_message_retrieve(ssh_session session, uint32_t packettype);
00090 LIBSSH_API void string_burn(ssh_string str);
00091 LIBSSH_API ssh_string string_copy(ssh_string str);
00092 LIBSSH_API void *string_data(ssh_string str);
00093 LIBSSH_API int string_fill(ssh_string str, const void *data, size_t len);
00094 LIBSSH_API void string_free(ssh_string str);
00095 LIBSSH_API ssh_string string_from_char(const char *what);
00096 LIBSSH_API size_t string_len(ssh_string str);
00097 LIBSSH_API ssh_string string_new(size_t size);
00098 LIBSSH_API char *string_to_char(ssh_string str);
00099 
00100 #endif /* LEGACY_H_ */

Generated by  doxygen 1.7.1