1
0
mirror of https://git.tartarus.org/simon/putty.git synced 2025-07-04 04:52:47 -05:00

First stab at the ability to compile puttytel.exe, an SSH-free

variant which is patent-safe in the US and legal in France and
Russia. This is a horrible hack in some ways: it's shown up serious
deficiencies in the module boundaries. Needs further work, probably
once the SSH implementations are recombined.

[originally from svn r410]
This commit is contained in:
Simon Tatham
2000-03-15 15:08:48 +00:00
parent 7aa84c296f
commit 96dbf9c6e6
11 changed files with 190 additions and 57 deletions

16
ssh.c
View File

@ -385,7 +385,21 @@ static void ssh_protocol(unsigned char *in, int inlen, int ispkt) {
if (!rsabuf)
fatalbox("Out of memory");
verify_ssh_host_key(savedhost, &hostkey);
/*
* Verify the host key.
*/
{
/*
* First format the key into a string.
*/
int len = rsastr_len(&hostkey);
char *keystr = malloc(len);
if (!keystr)
fatalbox("Out of memory");
rsastr_fmt(keystr, &hostkey);
verify_ssh_host_key(savedhost, keystr);
free(keystr);
}
for (i=0; i<32; i++) {
rsabuf[i] = session_key[i];