Check there is a SAN if subject DN is NULL.
git-svn-id: svn://svn.h5l.se/heimdal/trunk/heimdal@19874 ec53bebd-3082-4978-b11e-865c3cabbd6b
This commit is contained in:
@@ -603,9 +603,6 @@ hx509_validate_cert(hx509_context context,
|
|||||||
if (hx509_name_cmp(subject, issuer) == 0)
|
if (hx509_name_cmp(subject, issuer) == 0)
|
||||||
status.selfsigned = 1;
|
status.selfsigned = 1;
|
||||||
|
|
||||||
hx509_name_free(&subject);
|
|
||||||
hx509_name_free(&issuer);
|
|
||||||
|
|
||||||
validate_print(ctx, HX509_VALIDATE_F_VERBOSE,
|
validate_print(ctx, HX509_VALIDATE_F_VERBOSE,
|
||||||
"Validity:\n");
|
"Validity:\n");
|
||||||
|
|
||||||
@@ -687,5 +684,12 @@ hx509_validate_cert(hx509_context context,
|
|||||||
"Proxy and have IAN\n");
|
"Proxy and have IAN\n");
|
||||||
}
|
}
|
||||||
|
|
||||||
|
if (hx509_name_is_null_p(subject) && status.haveSAN)
|
||||||
|
validate_print(ctx, HX509_VALIDATE_F_VALIDATE,
|
||||||
|
"NULL subject DN and doesn't have a SAN\n");
|
||||||
|
|
||||||
|
hx509_name_free(&subject);
|
||||||
|
hx509_name_free(&issuer);
|
||||||
|
|
||||||
return 0;
|
return 0;
|
||||||
}
|
}
|
||||||
|
Reference in New Issue
Block a user