| Summary: | deattack.c modifications for correct UNICOS behavior | ||
|---|---|---|---|
| Product: | Portable OpenSSH | Reporter: | wendy palm <wendyp> |
| Component: | sshd | Assignee: | OpenSSH Bugzilla mailing list <openssh-bugs> |
| Status: | CLOSED INVALID | ||
| Severity: | normal | ||
| Priority: | P2 | ||
| Version: | -current | ||
| Hardware: | Other | ||
| OS: | Other | ||
these patches are no longer required. Mass change of RESOLVED bugs to CLOSED |
--- 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;