diff options
author | Damien Miller <djm@mindrot.org> | 2000-04-04 14:38:59 +1000 |
---|---|---|
committer | Damien Miller <djm@mindrot.org> | 2000-04-04 14:38:59 +1000 |
commit | 33b13568b520b25990261206e10c941a9270238f (patch) | |
tree | be9d549ee0c9c7774e3ec1da8d807b2e04b00bec /compat.c | |
parent | 193ba88dd6e9d6bcd5f476c7f5ddde8fd0b752bf (diff) |
- OpenBSD CVS update:
- [packet.h packet.c]
ssh2 packet format
- [packet.h packet.c nchan2.ms nchan.h compat.h compat.c]
[channels.h channels.c]
channel layer support for ssh2
- [kex.h kex.c hmac.h hmac.c dsa.c dsa.h]
DSA, keyexchange, algorithm agreement for ssh2
Diffstat (limited to 'compat.c')
-rw-r--r-- | compat.c | 33 |
1 files changed, 32 insertions, 1 deletions
@@ -28,15 +28,46 @@ | |||
28 | */ | 28 | */ |
29 | 29 | ||
30 | #include "includes.h" | 30 | #include "includes.h" |
31 | RCSID("$Id: compat.c,v 1.3 1999/11/25 00:54:59 damien Exp $"); | 31 | RCSID("$Id: compat.c,v 1.4 2000/04/04 04:39:01 damien Exp $"); |
32 | 32 | ||
33 | #include "ssh.h" | 33 | #include "ssh.h" |
34 | #include "packet.h" | ||
34 | 35 | ||
35 | int compat13 = 0; | 36 | int compat13 = 0; |
37 | int compat20 = 0; | ||
38 | int datafellows = 0; | ||
36 | 39 | ||
37 | void | 40 | void |
41 | enable_compat20(void) | ||
42 | { | ||
43 | fatal("protocol 2.0 not implemented"); | ||
44 | } | ||
45 | void | ||
38 | enable_compat13(void) | 46 | enable_compat13(void) |
39 | { | 47 | { |
40 | verbose("Enabling compatibility mode for protocol 1.3"); | 48 | verbose("Enabling compatibility mode for protocol 1.3"); |
41 | compat13 = 1; | 49 | compat13 = 1; |
42 | } | 50 | } |
51 | /* datafellows bug compatibility */ | ||
52 | void | ||
53 | compat_datafellows(const char *version) | ||
54 | { | ||
55 | int i; | ||
56 | size_t len; | ||
57 | static const char *check[] = { | ||
58 | "2.0.1", | ||
59 | "2.1.0.beta.9", | ||
60 | "2.1.0.pre.3", | ||
61 | "2.1.0.public.beta.1", | ||
62 | NULL | ||
63 | }; | ||
64 | for (i = 0; check[i]; i++) { | ||
65 | len = strlen(check[i]); | ||
66 | if (strlen(version) >= len && | ||
67 | (strncmp(version, check[i], len) == 0)) { | ||
68 | log("datafellows: %.200s", version); | ||
69 | datafellows = 1; | ||
70 | return; | ||
71 | } | ||
72 | } | ||
73 | } | ||