dsniff  2.4b2
About: A collection of tools for network auditing
  Fossies Dox: dsniff-2.4b2.tar.gz  ("inofficial" and yet experimental doxygen-generated source code documentation)  

ssh.h File Reference
This graph shows which files directly or indirectly include this file:

Go to the source code of this file.

Data Structures

struct  ssh_ctx
 
struct  ssh
 

Macros

#define SSH_MAX_PADLEN   8
 
#define SSH_MAX_PKTLEN   262144
 
#define SSH_AUTH_PASSWORD   3
 
#define SSH_CIPHER_NONE   0
 
#define SSH_CIPHER_3DES   3
 
#define SSH_CIPHER_BLOWFISH   6
 
#define SSH_MSG_DISCONNECT   1
 
#define SSH_SMSG_PUBLIC_KEY   2
 
#define SSH_CMSG_SESSION_KEY   3
 
#define SSH_CMSG_USER   4
 
#define SSH_CMSG_AUTH_PASSWORD   9
 
#define SSH_SMSG_SUCCESS   14
 
#define SSH_SMSG_FAILURE   15
 
#define SSH_CMSG_STDIN_DATA   16
 
#define SSH_SMSG_STDOUT_DATA   17
 
#define SSH_SMSG_STDERR_DATA   18
 
#define SSH_SMSG_EXITSTATUS   20
 

Typedefs

typedef struct ssh_ctx SSH_CTX
 
typedef struct ssh SSH
 

Functions

void SSH_init (void)
 
SSH_CTXSSH_CTX_new (void)
 
SSHSSH_new (SSH_CTX *ctx)
 
void SSH_set_fd (SSH *ssh, int fd)
 
int SSH_accept (SSH *ssh)
 
int SSH_connect (SSH *ssh)
 
int SSH_recv (SSH *ssh, u_char *buf, int size)
 
int SSH_send (SSH *ssh, u_char *buf, int len)
 
void SSH_close (SSH *ssh)
 

Macro Definition Documentation

◆ SSH_AUTH_PASSWORD

#define SSH_AUTH_PASSWORD   3

Definition at line 18 of file ssh.h.

◆ SSH_CIPHER_3DES

#define SSH_CIPHER_3DES   3

Definition at line 22 of file ssh.h.

◆ SSH_CIPHER_BLOWFISH

#define SSH_CIPHER_BLOWFISH   6

Definition at line 23 of file ssh.h.

◆ SSH_CIPHER_NONE

#define SSH_CIPHER_NONE   0

Definition at line 21 of file ssh.h.

◆ SSH_CMSG_AUTH_PASSWORD

#define SSH_CMSG_AUTH_PASSWORD   9

Definition at line 30 of file ssh.h.

◆ SSH_CMSG_SESSION_KEY

#define SSH_CMSG_SESSION_KEY   3

Definition at line 28 of file ssh.h.

◆ SSH_CMSG_STDIN_DATA

#define SSH_CMSG_STDIN_DATA   16

Definition at line 33 of file ssh.h.

◆ SSH_CMSG_USER

#define SSH_CMSG_USER   4

Definition at line 29 of file ssh.h.

◆ SSH_MAX_PADLEN

#define SSH_MAX_PADLEN   8

Definition at line 14 of file ssh.h.

◆ SSH_MAX_PKTLEN

#define SSH_MAX_PKTLEN   262144

Definition at line 15 of file ssh.h.

◆ SSH_MSG_DISCONNECT

#define SSH_MSG_DISCONNECT   1

Definition at line 26 of file ssh.h.

◆ SSH_SMSG_EXITSTATUS

#define SSH_SMSG_EXITSTATUS   20

Definition at line 36 of file ssh.h.

◆ SSH_SMSG_FAILURE

#define SSH_SMSG_FAILURE   15

Definition at line 32 of file ssh.h.

◆ SSH_SMSG_PUBLIC_KEY

#define SSH_SMSG_PUBLIC_KEY   2

Definition at line 27 of file ssh.h.

◆ SSH_SMSG_STDERR_DATA

#define SSH_SMSG_STDERR_DATA   18

Definition at line 35 of file ssh.h.

◆ SSH_SMSG_STDOUT_DATA

#define SSH_SMSG_STDOUT_DATA   17

Definition at line 34 of file ssh.h.

◆ SSH_SMSG_SUCCESS

#define SSH_SMSG_SUCCESS   14

Definition at line 31 of file ssh.h.

Typedef Documentation

◆ SSH

typedef struct ssh SSH

◆ SSH_CTX

typedef struct ssh_ctx SSH_CTX

Function Documentation

◆ SSH_accept()

◆ SSH_close()

void SSH_close ( SSH ssh)

Definition at line 578 of file ssh.c.

References ssh::fd.

Referenced by mitm_child().

◆ SSH_connect()

◆ SSH_CTX_new()

SSH_CTX* SSH_CTX_new ( void  )

◆ SSH_init()

void SSH_init ( void  )

Definition at line 178 of file ssh.c.

Referenced by mitm_init().

◆ SSH_new()

SSH* SSH_new ( SSH_CTX ctx)

Definition at line 207 of file ssh.c.

References ssh::ctx, and ssh::fd.

Referenced by mitm_child().

◆ SSH_recv()

int SSH_recv ( SSH ssh,
u_char *  buf,
int  size 
)

Definition at line 489 of file ssh.c.

References atomicio(), ssh::decrypt, ssh::dstate, ssh::fd, hex_print(), Opt_debug, ssh_crc32(), and warnx().

Referenced by mitm_child(), SSH_accept(), and SSH_connect().

◆ SSH_send()

int SSH_send ( SSH ssh,
u_char *  buf,
int  len 
)

Definition at line 533 of file ssh.c.

References atomicio(), ssh::encrypt, ssh::estate, ssh::fd, pkt, ssh_crc32(), and SSH_MAX_PKTLEN.

Referenced by mitm_child(), SSH_accept(), and SSH_connect().

◆ SSH_set_fd()

void SSH_set_fd ( SSH ssh,
int  fd 
)

Definition at line 221 of file ssh.c.

References ssh::fd.

Referenced by mitm_child().