| 97 |
SSH2_CIPHER_CAMELLIA128_CTR, SSH2_CIPHER_CAMELLIA192_CTR, SSH2_CIPHER_CAMELLIA256_CTR, |
SSH2_CIPHER_CAMELLIA128_CTR, SSH2_CIPHER_CAMELLIA192_CTR, SSH2_CIPHER_CAMELLIA256_CTR, |
| 98 |
SSH2_CIPHER_AES128_GCM, SSH2_CIPHER_AES256_GCM, |
SSH2_CIPHER_AES128_GCM, SSH2_CIPHER_AES256_GCM, |
| 99 |
SSH_CIPHER_MAX = SSH2_CIPHER_AES256_GCM, |
SSH_CIPHER_MAX = SSH2_CIPHER_AES256_GCM, |
| 100 |
} SSHCipher; |
} SSHCipherId; |
| 101 |
|
|
| 102 |
typedef enum { |
typedef enum { |
| 103 |
SSH_AUTH_NONE, SSH_AUTH_RHOSTS, SSH_AUTH_RSA, SSH_AUTH_PASSWORD, |
SSH_AUTH_NONE, SSH_AUTH_RHOSTS, SSH_AUTH_RSA, SSH_AUTH_PASSWORD, |
| 376 |
|
|
| 377 |
|
|
| 378 |
typedef struct ssh2_cipher { |
typedef struct ssh2_cipher { |
| 379 |
SSHCipher id; |
SSHCipherId id; |
| 380 |
char *name; |
char *name; |
| 381 |
int block_size; |
int block_size; |
| 382 |
int key_len; |
int key_len; |
| 384 |
int iv_len; |
int iv_len; |
| 385 |
int auth_len; |
int auth_len; |
| 386 |
const EVP_CIPHER *(*func)(void); |
const EVP_CIPHER *(*func)(void); |
| 387 |
} ssh2_cipher_t; |
} SSH2Cipher; |
| 388 |
|
|
| 389 |
static ssh2_cipher_t ssh2_ciphers[] = { |
static SSH2Cipher ssh2_ciphers[] = { |
| 390 |
{SSH2_CIPHER_3DES_CBC, "3des-cbc", 8, 24, 0, 0, 0, EVP_des_ede3_cbc}, // RFC4253 |
{SSH2_CIPHER_3DES_CBC, "3des-cbc", 8, 24, 0, 0, 0, EVP_des_ede3_cbc}, // RFC4253 |
| 391 |
{SSH2_CIPHER_AES128_CBC, "aes128-cbc", 16, 16, 0, 0, 0, EVP_aes_128_cbc}, // RFC4253 |
{SSH2_CIPHER_AES128_CBC, "aes128-cbc", 16, 16, 0, 0, 0, EVP_aes_128_cbc}, // RFC4253 |
| 392 |
{SSH2_CIPHER_AES192_CBC, "aes192-cbc", 16, 24, 0, 0, 0, EVP_aes_192_cbc}, // RFC4253 |
{SSH2_CIPHER_AES192_CBC, "aes192-cbc", 16, 24, 0, 0, 0, EVP_aes_192_cbc}, // RFC4253 |
| 773 |
BOOL do_SSH2_userauth(PTInstVar pvar); |
BOOL do_SSH2_userauth(PTInstVar pvar); |
| 774 |
BOOL do_SSH2_authrequest(PTInstVar pvar); |
BOOL do_SSH2_authrequest(PTInstVar pvar); |
| 775 |
void debug_print(int no, char *msg, int len); |
void debug_print(int no, char *msg, int len); |
| 776 |
int get_cipher_block_size(ssh2_cipher_t *cipher); |
int get_cipher_block_size(SSH2Cipher *cipher); |
| 777 |
int get_cipher_key_len(ssh2_cipher_t *cipher); |
int get_cipher_key_len(SSH2Cipher *cipher); |
| 778 |
int get_cipher_iv_len(ssh2_cipher_t *cipher); |
int get_cipher_iv_len(SSH2Cipher *cipher); |
| 779 |
int get_cipher_auth_len(ssh2_cipher_t *cipher); |
int get_cipher_auth_len(SSH2Cipher *cipher); |
| 780 |
ssh2_cipher_t *get_cipher_by_name(char *name); |
SSH2Cipher *get_cipher_by_name(char *name); |
| 781 |
char* get_kex_algorithm_name(kex_algorithm kextype); |
char* get_kex_algorithm_name(kex_algorithm kextype); |
| 782 |
const EVP_CIPHER* get_cipher_EVP_CIPHER(ssh2_cipher_t *cipher); |
const EVP_CIPHER* get_cipher_EVP_CIPHER(SSH2Cipher *cipher); |
| 783 |
const EVP_MD* get_kex_algorithm_EVP_MD(kex_algorithm kextype); |
const EVP_MD* get_kex_algorithm_EVP_MD(kex_algorithm kextype); |
| 784 |
char* get_ssh2_mac_name(hmac_type type); |
char* get_ssh2_mac_name(hmac_type type); |
| 785 |
const EVP_MD* get_ssh2_mac_EVP_MD(hmac_type type); |
const EVP_MD* get_ssh2_mac_EVP_MD(hmac_type type); |
| 787 |
char* get_ssh2_comp_name(compression_type type); |
char* get_ssh2_comp_name(compression_type type); |
| 788 |
char* get_ssh_keytype_name(ssh_keytype type); |
char* get_ssh_keytype_name(ssh_keytype type); |
| 789 |
char* get_digest_algorithm_name(digest_algorithm id); |
char* get_digest_algorithm_name(digest_algorithm id); |
| 790 |
int get_cipher_discard_len(ssh2_cipher_t *cipher); |
int get_cipher_discard_len(SSH2Cipher *cipher); |
| 791 |
void ssh_heartbeat_lock_initialize(void); |
void ssh_heartbeat_lock_initialize(void); |
| 792 |
void ssh_heartbeat_lock_finalize(void); |
void ssh_heartbeat_lock_finalize(void); |
| 793 |
void ssh_heartbeat_lock(void); |
void ssh_heartbeat_lock(void); |