diff options
Diffstat (limited to 'signkey.c')
-rw-r--r-- | signkey.c | 4 |
1 files changed, 4 insertions, 0 deletions
@@ -577,6 +577,10 @@ int cmp_base64_key(const unsigned char* keyblob, unsigned int keybloblen, /* now we have the actual data */ len = line->len - line->pos; + if (len == 0) { + /* base64_decode doesn't like NULL argument */ + return DROPBEAR_FAILURE; + } decodekeylen = len * 2; /* big to be safe */ decodekey = buf_new(decodekeylen); |