]> andersk Git - openssh.git/blobdiff - compat.c
- tim@mindrot.org 2001/03/17 18:45:25 [compat.c]
[openssh.git] / compat.c
index a2d3a33831a7c1ddc5b900436d3e54ab267fade1..9d23f9a03ad8059968cb2888b05c7590fc350c9a 100644 (file)
--- a/compat.c
+++ b/compat.c
  */
 
 #include "includes.h"
-RCSID("$OpenBSD: compat.c,v 1.32 2000/12/09 23:51:11 provos Exp $");
+RCSID("$OpenBSD: compat.c,v 1.38 2001/03/10 15:31:00 deraadt Exp $");
 
-#include "ssh.h"
-#include "packet.h"
-#include "xmalloc.h"
-#include "compat.h"
 #ifdef HAVE_LIBPCRE
 #  include <pcreposix.h>
 #else /* Use native regex libraries */
-#  include <regex.h>
+#  ifdef HAVE_REGEX_H
+#    include <regex.h>
+#  else
+#    include "openbsd-compat/fake-regex.h"
+#  endif
 #endif /* HAVE_LIBPCRE */
 
+#include "packet.h"
+#include "xmalloc.h"
+#include "compat.h"
+#include "log.h"
+
 int compat13 = 0;
 int compat20 = 0;
 int datafellows = 0;
@@ -62,22 +67,36 @@ compat_datafellows(const char *version)
                char    *pat;
                int     bugs;
        } check[] = {
-               { "^OpenSSH[-_]2\\.[012]",      SSH_OLD_SESSIONID },
+               { "^OpenSSH[-_]2\\.[012]",
+                                       SSH_OLD_SESSIONID|SSH_BUG_BANNER },
+               { "^OpenSSH_2\\.3\\.0", SSH_BUG_BANNER },
+               { "^OpenSSH",           0 },
                { "MindTerm",           0 },
                { "^2\\.1\\.0",         SSH_BUG_SIGBLOB|SSH_BUG_HMAC|
                                        SSH_OLD_SESSIONID|SSH_BUG_DEBUG },
+               { "^2\\.1 ",            SSH_BUG_SIGBLOB|SSH_BUG_HMAC|
+                                       SSH_OLD_SESSIONID|SSH_BUG_DEBUG },
                { "^2\\.0\\.1[3-9]",    SSH_BUG_SIGBLOB|SSH_BUG_HMAC|
                                        SSH_OLD_SESSIONID|SSH_BUG_DEBUG|
-                                       SSH_BUG_PKSERVICE|SSH_BUG_X11FWD },
+                                       SSH_BUG_PKSERVICE|SSH_BUG_X11FWD|
+                                       SSH_BUG_PKOK },
                { "^2\\.0\\.",          SSH_BUG_SIGBLOB|SSH_BUG_HMAC|
                                        SSH_OLD_SESSIONID|SSH_BUG_DEBUG|
                                        SSH_BUG_PKSERVICE|SSH_BUG_X11FWD|
-                                       SSH_BUG_PKAUTH },
-               { "^2\\.[23]\\.0",      SSH_BUG_HMAC},
+                                       SSH_BUG_PKAUTH|SSH_BUG_PKOK },
+               { "^2\\.[23]\\.0",      SSH_BUG_HMAC },
                { "^2\\.[2-9]\\.",      0 },
-               { "^2\\.4$",            SSH_OLD_SESSIONID}, /* Van Dyke */
-               { "^3\\.0 SecureCRT",   SSH_OLD_SESSIONID},
-               { "^1\\.7 SecureFX",    SSH_OLD_SESSIONID},
+               { "^2\\.4$",            SSH_OLD_SESSIONID },    /* Van Dyke */
+               { "^3\\.0 SecureCRT",   SSH_OLD_SESSIONID },
+               { "^1\\.7 SecureFX",    SSH_OLD_SESSIONID },
+               { "^1\\.2\\.1[89]",     SSH_BUG_IGNOREMSG },
+               { "^1\\.2\\.2[012]",    SSH_BUG_IGNOREMSG },
+               { "^SSH Compatible Server",                     /* Netscreen */
+                                       SSH_BUG_PASSWORDPAD },
+               { "^OSU_0",             SSH_BUG_PASSWORDPAD },
+               { "^OSU_1\\.[0-4]",     SSH_BUG_PASSWORDPAD },
+               { "^OSU_1\\.5alpha[1-3]",
+                                       SSH_BUG_PASSWORDPAD },
                { NULL,                 0 }
        };
        /* process table, return first match */
This page took 0.049927 seconds and 4 git commands to generate.