Skip to content

Commit 14e3103

Browse files
committed
8178806: Better exception logging in crypto code
Backport-of: b814cfc39d2a49951e8e1839cb2f42d9b7cf705d
1 parent 36c1c0a commit 14e3103

File tree

1 file changed

+5
-1
lines changed

1 file changed

+5
-1
lines changed

src/java.base/share/classes/javax/crypto/JceSecurity.java.template

+5-1
Original file line numberDiff line numberDiff line change
@@ -235,7 +235,11 @@ final class JceSecurity {
235235

236236
// return whether this provider is properly signed and can be used by JCE
237237
static boolean canUseProvider(Provider p) {
238-
return getVerificationResult(p) == null;
238+
Exception e = getVerificationResult(p);
239+
if (debug != null && e != null) {
240+
debug.println("Provider verification result: " + e);
241+
}
242+
return e == null;
239243
}
240244

241245
// dummy object to represent null

0 commit comments

Comments
 (0)