mirror of
https://git.tartarus.org/simon/putty.git
synced 2025-07-05 21:42:47 -05:00
Turn SSH-1 ciphers into a classoid.
The interchangeable system of SSH-1 ciphers previously followed the same pattern as the backends and the public-key algorithms, in that all the clients would maintain two separate pointers, one to the vtable and the other to the individual instance / context. Now I've merged them, just as I did with those other two, so that you only cart around a single pointer, which has a vtable pointer inside it and a type distinguishing it from an instance of any of the other interchangeable sets of algorithms.
This commit is contained in:
7
ssh.c
7
ssh.c
@ -2914,10 +2914,9 @@ static void do_ssh1_login(void *vctx)
|
||||
sfree(s->rsabuf);
|
||||
|
||||
{
|
||||
const struct ssh_cipher *cipher =
|
||||
(s->cipher_type == SSH_CIPHER_BLOWFISH ? &ssh_blowfish_ssh1 :
|
||||
s->cipher_type == SSH_CIPHER_DES ? &ssh_des :
|
||||
&ssh_3des);
|
||||
const struct ssh1_cipheralg *cipher =
|
||||
(s->cipher_type == SSH_CIPHER_BLOWFISH ? &ssh1_blowfish :
|
||||
s->cipher_type == SSH_CIPHER_DES ? &ssh1_des : &ssh1_3des);
|
||||
ssh1_bpp_new_cipher(ssh->bpp, cipher, ssh->session_key);
|
||||
logeventf(ssh, "Initialised %s encryption", cipher->text_name);
|
||||
}
|
||||
|
Reference in New Issue
Block a user