We read every piece of feedback, and take your input very seriously.
To see all available qualifiers, see our documentation.
1 parent 2b7780a commit 499b3feCopy full SHA for 499b3fe
1 file changed
src/main/java/com/wolfssl/provider/jce/WolfCryptPKIXCertPathValidator.java
@@ -1185,9 +1185,11 @@ public CertPathValidatorResult engineValidate(
1185
certs.get(certs.size() - 1));
1186
1187
/* Check trust anchor public key constraints */
1188
- if (trustAnchor != null) {
1189
- checkTrustAnchorConstraints(trustAnchor);
+ if (trustAnchor == null) {
+ throw new CertPathValidatorException(
1190
+ "Unable to find matching trust anchor");
1191
}
1192
+ checkTrustAnchorConstraints(trustAnchor);
1193
1194
} finally {
1195
/* Free native WolfSSLCertManager resources */
0 commit comments