Fail if not finding iv.

git-svn-id: svn://svn.h5l.se/heimdal/trunk/heimdal@21141 ec53bebd-3082-4978-b11e-865c3cabbd6b
This commit is contained in:
Love Hörnquist Åstrand
2007-06-18 21:30:11 +00:00
parent 7c5b097a53
commit 8e9ebe14de

View File

@@ -232,7 +232,13 @@ parse_rsa_private_key(hx509_context context, const char *fn,
}
iv = strchr(type, ',');
if (iv)
if (iv == NULL) {
free(type);
hx509_set_error_string(context, 0, HX509_PARSING_KEY_FAILED,
"IV missing");
return HX509_PARSING_KEY_FAILED;
}
*iv++ = '\0';
size = strlen(iv);