23#include "libssh/priv.h" 
   33enum ssh_channel_request_state_e {
 
   35    SSH_CHANNEL_REQ_STATE_NONE = 0,
 
   37    SSH_CHANNEL_REQ_STATE_PENDING,
 
   39    SSH_CHANNEL_REQ_STATE_ACCEPTED,
 
   41    SSH_CHANNEL_REQ_STATE_DENIED,
 
   43    SSH_CHANNEL_REQ_STATE_ERROR
 
   46enum ssh_channel_state_e {
 
   47  SSH_CHANNEL_STATE_NOT_OPEN = 0,
 
   48  SSH_CHANNEL_STATE_OPENING,
 
   49  SSH_CHANNEL_STATE_OPEN_DENIED,
 
   50  SSH_CHANNEL_STATE_OPEN,
 
   51  SSH_CHANNEL_STATE_CLOSED
 
   55#define SSH_CHANNEL_FLAG_CLOSED_REMOTE 0x0001 
   58#define SSH_CHANNEL_FLAG_CLOSED_LOCAL 0x0002 
   61#define SSH_CHANNEL_FLAG_FREED_LOCAL 0x0004 
   64#define SSH_CHANNEL_FLAG_NOT_BOUND 0x0008 
   66struct ssh_channel_struct {
 
   68    uint32_t local_channel;
 
   69    uint32_t local_window;
 
   71    uint32_t local_maxpacket;
 
   73    uint32_t remote_channel;
 
   74    uint32_t remote_window;
 
   76    uint32_t remote_maxpacket;
 
   77    enum ssh_channel_state_e state;
 
   80    ssh_buffer stdout_buffer;
 
   81    ssh_buffer stderr_buffer;
 
   89    enum ssh_channel_request_state_e request_state;
 
   90    struct ssh_list *callbacks; 
 
  109int channel_default_bufferize(ssh_channel channel,
 
  110                              void *data, uint32_t len,
 
  112int ssh_channel_flush(ssh_channel channel);
 
  113uint32_t ssh_channel_new_id(ssh_session session);
 
  114ssh_channel ssh_channel_from_local(ssh_session session, uint32_t 
id);
 
  115void ssh_channel_do_free(ssh_channel channel);
 
  116int ssh_global_request(ssh_session session,
 
#define SSH_PACKET_CALLBACK(name)
This macro declares a packet callback handler.
Definition callbacks.h:560