Skip to content

Commit 1928a36

Browse files
committed
8331391: Enhance the keytool code by invoking the buildTrustedCerts method for essential options
Backport-of: c9bee173d61f4accfc4adc280ab5d21600191756
1 parent a29f5fb commit 1928a36

File tree

1 file changed

+1
-1
lines changed
  • src/java.base/share/classes/sun/security/tools/keytool

1 file changed

+1
-1
lines changed

src/java.base/share/classes/sun/security/tools/keytool/Main.java

+1-1
Original file line numberDiff line numberDiff line change
@@ -1125,7 +1125,6 @@ && isKeyStoreRelated(command)
11251125
}
11261126
}
11271127

1128-
KeyStore cakstore = buildTrustedCerts();
11291128
// -trustcacerts can be specified on -importcert, -printcert or -printcrl.
11301129
// Reset it so that warnings on CA cert will remain for other command.
11311130
if (command != IMPORTCERT && command != PRINTCERT
@@ -1134,6 +1133,7 @@ && isKeyStoreRelated(command)
11341133
}
11351134

11361135
if (trustcacerts) {
1136+
KeyStore cakstore = buildTrustedCerts();
11371137
if (cakstore != null) {
11381138
caks = cakstore;
11391139
} else {

0 commit comments

Comments
 (0)