Skip to content

Commit aaedfb3

Browse files
committed
8178806: Better exception logging in crypto code
Backport-of: b814cfc39d2a49951e8e1839cb2f42d9b7cf705d
1 parent 691657a commit aaedfb3

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
@@ -228,7 +228,11 @@ final class JceSecurity {
228228

229229
// return whether this provider is properly signed and can be used by JCE
230230
static boolean canUseProvider(Provider p) {
231-
return getVerificationResult(p) == null;
231+
Exception e = getVerificationResult(p);
232+
if (debug != null && e != null) {
233+
debug.println("Provider verification result: " + e);
234+
}
235+
return e == null;
232236
}
233237

234238
// dummy object to represent null

0 commit comments

Comments
 (0)