diff options
-rw-r--r-- | buffer.c | 10 | ||||
-rw-r--r-- | debian/changelog | 6 |
2 files changed, 12 insertions, 4 deletions
@@ -69,6 +69,7 @@ buffer_append(Buffer *buffer, const void *data, u_int len) | |||
69 | void * | 69 | void * |
70 | buffer_append_space(Buffer *buffer, u_int len) | 70 | buffer_append_space(Buffer *buffer, u_int len) |
71 | { | 71 | { |
72 | u_int newlen; | ||
72 | void *p; | 73 | void *p; |
73 | 74 | ||
74 | if (len > 0x100000) | 75 | if (len > 0x100000) |
@@ -98,11 +99,12 @@ restart: | |||
98 | goto restart; | 99 | goto restart; |
99 | } | 100 | } |
100 | /* Increase the size of the buffer and retry. */ | 101 | /* Increase the size of the buffer and retry. */ |
101 | buffer->alloc += len + 32768; | 102 | newlen = buffer->alloc + len + 32768; |
102 | if (buffer->alloc > 0xa00000) | 103 | if (newlen > 0xa00000) |
103 | fatal("buffer_append_space: alloc %u not supported", | 104 | fatal("buffer_append_space: alloc %u not supported", |
104 | buffer->alloc); | 105 | newlen); |
105 | buffer->buf = xrealloc(buffer->buf, buffer->alloc); | 106 | buffer->buf = xrealloc(buffer->buf, newlen); |
107 | buffer->alloc = newlen; | ||
106 | goto restart; | 108 | goto restart; |
107 | /* NOTREACHED */ | 109 | /* NOTREACHED */ |
108 | } | 110 | } |
diff --git a/debian/changelog b/debian/changelog index 2799cfdd9..b5be7720c 100644 --- a/debian/changelog +++ b/debian/changelog | |||
@@ -1,3 +1,9 @@ | |||
1 | openssh (1:3.6.1p2-6.0) unstable; urgency=high | ||
2 | |||
3 | * SECURITY: fix for CAN-2003-0693, buffer allocation error | ||
4 | |||
5 | -- Michael Stone <mstone@debian.org> Tue, 16 Sep 2003 08:27:07 -0400 | ||
6 | |||
1 | openssh (1:3.6.1p2-6) unstable; urgency=medium | 7 | openssh (1:3.6.1p2-6) unstable; urgency=medium |
2 | 8 | ||
3 | * Use a more CVS-friendly means of setting SSH_VERSION. | 9 | * Use a more CVS-friendly means of setting SSH_VERSION. |