[Bug 97] New: deattack.c modifications for correct UNICOS behavior

bugzilla-daemon at mindrot.org bugzilla-daemon at mindrot.org
Tue Feb 5 06:16:23 EST 2002


http://bugzilla.mindrot.org/show_bug.cgi?id=97

           Summary: deattack.c modifications for correct UNICOS behavior
           Product: Portable OpenSSH
           Version: 3.0.2p1
          Platform: Other
        OS/Version: other
            Status: NEW
          Severity: normal
          Priority: P2
         Component: sshd
        AssignedTo: openssh-unix-dev at mindrot.org
        ReportedBy: wendyp at cray.com


--- deattack.c.orig     Mon Feb  4 12:32:51 2002
+++ deattack.c  Mon Feb  4 12:35:01 2002
@@ -101,11 +101,19 @@
        if (h == NULL) {
                debug("Installing crc compensation attack detector.");
                n = l;
+#ifdef _CRAY
+               h = (u_int16_t *) xmalloc(n * sizeof(u_int16_t));
+#else
                h = (u_int16_t *) xmalloc(n * HASH_ENTRYSIZE);
+#endif /* _CRAY */
        } else {
                if (l > n) {
                        n = l;
+#ifdef _CRAY
+                       h = (u_int16_t *) xrealloc(h, n * sizeof(u_int16_t));
+#else
                        h = (u_int16_t *) xrealloc(h, n * HASH_ENTRYSIZE);
+#endif /* _CRAY */
                }
        }

@@ -128,7 +136,11 @@
                }
                return (DEATTACK_OK);
        }
+#ifdef _CRAY
+       for (i=0; i<n; i++) h[i] = HASH_UNUSED;
+#else
        memset(h, HASH_UNUSEDCHAR, n * HASH_ENTRYSIZE);
+#endif /* _CRAY */

        if (IV)
                h[HASH(IV) & (n - 1)] = HASH_IV;



------- You are receiving this mail because: -------
You are the assignee for the bug, or are watching the assignee.



More information about the openssh-unix-dev mailing list