diff options
-rw-r--r-- | ChangeLog | 6 | ||||
-rw-r--r-- | compat.c | 20 | ||||
-rw-r--r-- | compat.h | 3 | ||||
-rw-r--r-- | sshconnect.c | 6 |
4 files changed, 25 insertions, 10 deletions
@@ -9,6 +9,10 @@ | |||
9 | - stevesk@cvs.openbsd.org 2001/03/10 15:02:05 | 9 | - stevesk@cvs.openbsd.org 2001/03/10 15:02:05 |
10 | [ttymodes.c ttymodes.h] | 10 | [ttymodes.c ttymodes.h] |
11 | remove unused sgtty macros; ok markus@ | 11 | remove unused sgtty macros; ok markus@ |
12 | - deraadt@cvs.openbsd.org 2001/03/10 15:31:00 | ||
13 | [compat.c compat.h sshconnect.c] | ||
14 | all known netscreen ssh versions, and older versions of OSU ssh cannot | ||
15 | handle password padding (newer OSU is fixed) | ||
12 | 16 | ||
13 | 20010310 | 17 | 20010310 |
14 | - OpenBSD CVS Sync | 18 | - OpenBSD CVS Sync |
@@ -4480,4 +4484,4 @@ | |||
4480 | - Wrote replacements for strlcpy and mkdtemp | 4484 | - Wrote replacements for strlcpy and mkdtemp |
4481 | - Released 1.0pre1 | 4485 | - Released 1.0pre1 |
4482 | 4486 | ||
4483 | $Id: ChangeLog,v 1.936 2001/03/10 17:17:28 mouring Exp $ | 4487 | $Id: ChangeLog,v 1.937 2001/03/10 17:22:20 mouring Exp $ |
@@ -23,7 +23,7 @@ | |||
23 | */ | 23 | */ |
24 | 24 | ||
25 | #include "includes.h" | 25 | #include "includes.h" |
26 | RCSID("$OpenBSD: compat.c,v 1.37 2001/03/08 21:42:31 markus Exp $"); | 26 | RCSID("$OpenBSD: compat.c,v 1.38 2001/03/10 15:31:00 deraadt Exp $"); |
27 | 27 | ||
28 | #ifdef HAVE_LIBPCRE | 28 | #ifdef HAVE_LIBPCRE |
29 | # include <pcreposix.h> | 29 | # include <pcreposix.h> |
@@ -84,13 +84,19 @@ compat_datafellows(const char *version) | |||
84 | SSH_OLD_SESSIONID|SSH_BUG_DEBUG| | 84 | SSH_OLD_SESSIONID|SSH_BUG_DEBUG| |
85 | SSH_BUG_PKSERVICE|SSH_BUG_X11FWD| | 85 | SSH_BUG_PKSERVICE|SSH_BUG_X11FWD| |
86 | SSH_BUG_PKAUTH|SSH_BUG_PKOK }, | 86 | SSH_BUG_PKAUTH|SSH_BUG_PKOK }, |
87 | { "^2\\.[23]\\.0", SSH_BUG_HMAC}, | 87 | { "^2\\.[23]\\.0", SSH_BUG_HMAC }, |
88 | { "^2\\.[2-9]\\.", 0 }, | 88 | { "^2\\.[2-9]\\.", 0 }, |
89 | { "^2\\.4$", SSH_OLD_SESSIONID}, /* Van Dyke */ | 89 | { "^2\\.4$", SSH_OLD_SESSIONID }, /* Van Dyke */ |
90 | { "^3\\.0 SecureCRT", SSH_OLD_SESSIONID}, | 90 | { "^3\\.0 SecureCRT", SSH_OLD_SESSIONID }, |
91 | { "^1\\.7 SecureFX", SSH_OLD_SESSIONID}, | 91 | { "^1\\.7 SecureFX", SSH_OLD_SESSIONID }, |
92 | { "^1\\.2\\.1[89]", SSH_BUG_IGNOREMSG}, | 92 | { "^1\\.2\\.1[89]", SSH_BUG_IGNOREMSG }, |
93 | { "^1\\.2\\.2[012]", SSH_BUG_IGNOREMSG}, | 93 | { "^1\\.2\\.2[012]", SSH_BUG_IGNOREMSG }, |
94 | { "^SSH Compatible Server", /* Netscreen */ | ||
95 | SSH_BUG_PASSWORDPAD }, | ||
96 | { "^OSU_0", SSH_BUG_PASSWORDPAD }, | ||
97 | { "^OSU_1\\.[0-4]", SSH_BUG_PASSWORDPAD }, | ||
98 | { "^OSU_1\\.5alpha[1-3]", | ||
99 | SSH_BUG_PASSWORDPAD }, | ||
94 | { NULL, 0 } | 100 | { NULL, 0 } |
95 | }; | 101 | }; |
96 | /* process table, return first match */ | 102 | /* process table, return first match */ |
@@ -21,7 +21,7 @@ | |||
21 | * (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF | 21 | * (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF |
22 | * THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE. | 22 | * THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE. |
23 | */ | 23 | */ |
24 | /* RCSID("$OpenBSD: compat.h,v 1.16 2001/03/08 21:42:32 markus Exp $"); */ | 24 | /* RCSID("$OpenBSD: compat.h,v 1.17 2001/03/10 15:31:00 deraadt Exp $"); */ |
25 | 25 | ||
26 | #ifndef COMPAT_H | 26 | #ifndef COMPAT_H |
27 | #define COMPAT_H | 27 | #define COMPAT_H |
@@ -41,6 +41,7 @@ | |||
41 | #define SSH_BUG_BANNER 0x0080 | 41 | #define SSH_BUG_BANNER 0x0080 |
42 | #define SSH_BUG_IGNOREMSG 0x0100 | 42 | #define SSH_BUG_IGNOREMSG 0x0100 |
43 | #define SSH_BUG_PKOK 0x0200 | 43 | #define SSH_BUG_PKOK 0x0200 |
44 | #define SSH_BUG_PASSWORDPAD 0x0400 | ||
44 | 45 | ||
45 | void enable_compat13(void); | 46 | void enable_compat13(void); |
46 | void enable_compat20(void); | 47 | void enable_compat20(void); |
diff --git a/sshconnect.c b/sshconnect.c index 9962d49bd..573ae76b1 100644 --- a/sshconnect.c +++ b/sshconnect.c | |||
@@ -13,7 +13,7 @@ | |||
13 | */ | 13 | */ |
14 | 14 | ||
15 | #include "includes.h" | 15 | #include "includes.h" |
16 | RCSID("$OpenBSD: sshconnect.c,v 1.98 2001/03/04 17:42:28 millert Exp $"); | 16 | RCSID("$OpenBSD: sshconnect.c,v 1.99 2001/03/10 15:31:00 deraadt Exp $"); |
17 | 17 | ||
18 | #include <openssl/bn.h> | 18 | #include <openssl/bn.h> |
19 | 19 | ||
@@ -777,6 +777,10 @@ ssh_put_password(char *password) | |||
777 | int size; | 777 | int size; |
778 | char *padded; | 778 | char *padded; |
779 | 779 | ||
780 | if (datafellows & SSH_BUG_PASSWORDPAD) { | ||
781 | packet_put_string(password, strlen(password)); | ||
782 | return; | ||
783 | } | ||
780 | size = roundup(strlen(password) + 1, 32); | 784 | size = roundup(strlen(password) + 1, 32); |
781 | padded = xmalloc(size); | 785 | padded = xmalloc(size); |
782 | memset(padded, 0, size); | 786 | memset(padded, 0, size); |