summaryrefslogtreecommitdiff
path: root/usr.bin/ssh/ssh-dss.c
diff options
context:
space:
mode:
authorMarkus Friedl <markus@cvs.openbsd.org>2001-11-07 22:10:29 +0000
committerMarkus Friedl <markus@cvs.openbsd.org>2001-11-07 22:10:29 +0000
commit3498712abf04f58becab7ec0ba632b7006520409 (patch)
tree5962d9f20732156bf6a0c5bf8a0dd29d04fc7b0f /usr.bin/ssh/ssh-dss.c
parent56d6e8bacefe690d9c27fccebdebbc1caafa6bf0 (diff)
missing free and sync dss/rsa code.
Diffstat (limited to 'usr.bin/ssh/ssh-dss.c')
-rw-r--r--usr.bin/ssh/ssh-dss.c12
1 files changed, 7 insertions, 5 deletions
diff --git a/usr.bin/ssh/ssh-dss.c b/usr.bin/ssh/ssh-dss.c
index 22fffa02afa..9f3a28706dd 100644
--- a/usr.bin/ssh/ssh-dss.c
+++ b/usr.bin/ssh/ssh-dss.c
@@ -23,7 +23,7 @@
*/
#include "includes.h"
-RCSID("$OpenBSD: ssh-dss.c,v 1.8 2001/09/17 19:27:15 stevesk Exp $");
+RCSID("$OpenBSD: ssh-dss.c,v 1.9 2001/11/07 22:10:28 markus Exp $");
#include <openssl/bn.h>
#include <openssl/evp.h>
@@ -138,17 +138,19 @@ ssh_dss_verify(
if (strcmp("ssh-dss", ktype) != 0) {
error("ssh_dss_verify: cannot handle type %s", ktype);
buffer_free(&b);
+ xfree(ktype);
return -1;
}
+ xfree(ktype);
sigblob = buffer_get_string(&b, &len);
rlen = buffer_len(&b);
+ buffer_free(&b);
if(rlen != 0) {
- error("remaining bytes in signature %d", rlen);
- buffer_free(&b);
+ error("ssh_dss_verify: "
+ "remaining bytes in signature %d", rlen);
+ xfree(sigblob);
return -1;
}
- buffer_free(&b);
- xfree(ktype);
}
if (len != SIGBLOB_LEN) {