diff options
Diffstat (limited to 'ssh-rsa.c')
-rw-r--r-- | ssh-rsa.c | 4 |
1 files changed, 2 insertions, 2 deletions
@@ -14,7 +14,7 @@ | |||
14 | * OR IN CONNECTION WITH THE USE OR PERFORMANCE OF THIS SOFTWARE. | 14 | * OR IN CONNECTION WITH THE USE OR PERFORMANCE OF THIS SOFTWARE. |
15 | */ | 15 | */ |
16 | #include "includes.h" | 16 | #include "includes.h" |
17 | RCSID("$OpenBSD: ssh-rsa.c,v 1.31 2003/11/10 16:23:41 jakob Exp $"); | 17 | RCSID("$OpenBSD: ssh-rsa.c,v 1.32 2005/06/17 02:44:33 djm Exp $"); |
18 | 18 | ||
19 | #include <openssl/evp.h> | 19 | #include <openssl/evp.h> |
20 | #include <openssl/err.h> | 20 | #include <openssl/err.h> |
@@ -238,7 +238,7 @@ openssh_RSA_verify(int type, u_char *hash, u_int hashlen, | |||
238 | ERR_error_string(ERR_get_error(), NULL)); | 238 | ERR_error_string(ERR_get_error(), NULL)); |
239 | goto done; | 239 | goto done; |
240 | } | 240 | } |
241 | if (len != hlen + oidlen) { | 241 | if (len < 0 || (u_int)len != hlen + oidlen) { |
242 | error("bad decrypted len: %d != %d + %d", len, hlen, oidlen); | 242 | error("bad decrypted len: %d != %d + %d", len, hlen, oidlen); |
243 | goto done; | 243 | goto done; |
244 | } | 244 | } |