From 448a88a5c88f3352eb5f5e0504445f563154eb89 Mon Sep 17 00:00:00 2001 From: Sergey Ponomarev Date: Sun, 16 Jun 2024 00:27:48 +0300 Subject: [PATCH] Refactorings (#500) * fix typo in getSignerCerificates() Signed-off-by: Sergey Ponomarev * JarParser.getSignerCerificates(): early break Signed-off-by: Sergey Ponomarev * use Path.of() to avoid depending on a system's file separator Signed-off-by: Sergey Ponomarev * Use Path.of() for DUpgradeCryptoStrength.ManualInstructions.message Signed-off-by: Sergey Ponomarev * i18n ru improve Signed-off-by: Sergey Ponomarev * Simplify usage of System.getProperty() Signed-off-by: Sergey Ponomarev * DUserNoticeChooser: remove unnecessary boxing Signed-off-by: Sergey Ponomarev * ObjectIdUtil: Stream may be extended replacing 'toArray' Signed-off-by: Sergey Ponomarev * Use isEmpty() Signed-off-by: Sergey Ponomarev * Remove Conditional break inside loop Signed-off-by: Sergey Ponomarev * Fix typos Signed-off-by: Sergey Ponomarev --------- Signed-off-by: Sergey Ponomarev --- .../java/org/kse/AuthorityCertificates.java | 4 +-- .../java/org/kse/crypto/csr/spkac/Spkac.java | 2 +- .../kse/crypto/jcepolicy/JcePolicyUtil.java | 4 +-- .../org/kse/crypto/signing/JarParser.java | 26 +++++++++---------- .../java/org/kse/gui/CurrentDirectory.java | 2 +- .../kse/gui/actions/ExamineFileAction.java | 2 +- .../ExportSelectedCertificatesAction.java | 2 +- .../gui/crypto/DUpgradeCryptoStrength.java | 8 +++--- .../policyinformation/DUserNoticeChooser.java | 4 +-- .../org/kse/gui/dialogs/DialogHelper.java | 4 +-- .../dialogs/extensions/DAddExtensionType.java | 6 ++--- .../dialogs/extensions/DAddExtensions.java | 2 +- .../main/java/org/kse/gui/jar/DJarInfo.java | 2 +- .../utilities/history/KeyStoreHistory.java | 8 ++---- .../org/kse/utilities/oid/ObjectIdUtil.java | 3 +-- .../kse/gui/actions/resources_ru.properties | 8 ++++-- .../org/kse/gui/crypto/resources.properties | 2 +- .../kse/gui/crypto/resources_de.properties | 2 +- .../kse/gui/crypto/resources_fr.properties | 2 +- .../importexport/resources_ru.properties | 2 ++ .../kse/gui/password/resources_ru.properties | 2 +- 21 files changed, 47 insertions(+), 50 deletions(-) diff --git a/kse/src/main/java/org/kse/AuthorityCertificates.java b/kse/src/main/java/org/kse/AuthorityCertificates.java index d7a0c7417..d5ae4236f 100644 --- a/kse/src/main/java/org/kse/AuthorityCertificates.java +++ b/kse/src/main/java/org/kse/AuthorityCertificates.java @@ -21,6 +21,7 @@ import java.io.File; import java.io.IOException; +import java.nio.file.Path; import java.security.KeyStore; import org.kse.crypto.CryptoException; @@ -80,8 +81,7 @@ public void setCaCertificates(KeyStore caCertificates) { */ public static File getDefaultCaCertificatesLocation() { String javaInstallDir = System.getProperty("java.home"); - String fileSep = System.getProperty("file.separator"); - File cacertsFile = new File(javaInstallDir, "lib" + fileSep + "security" + fileSep + "cacerts"); + File cacertsFile = Path.of(javaInstallDir, "lib", "security", "cacerts").toFile(); try { return cacertsFile.getCanonicalFile(); } catch (IOException e) { diff --git a/kse/src/main/java/org/kse/crypto/csr/spkac/Spkac.java b/kse/src/main/java/org/kse/crypto/csr/spkac/Spkac.java index 3fc552e15..4c89a9dd8 100644 --- a/kse/src/main/java/org/kse/crypto/csr/spkac/Spkac.java +++ b/kse/src/main/java/org/kse/crypto/csr/spkac/Spkac.java @@ -100,7 +100,7 @@ public class Spkac { private static ResourceBundle res = ResourceBundle.getBundle("org/kse/crypto/csr/spkac/resources"); private static final String SPKAC_PROPERTY = "SPKAC"; - private static final String NEWLINE = System.getProperty("line.separator"); + private static final String NEWLINE = System.lineSeparator(); private String challenge; private SpkacSubject subject; diff --git a/kse/src/main/java/org/kse/crypto/jcepolicy/JcePolicyUtil.java b/kse/src/main/java/org/kse/crypto/jcepolicy/JcePolicyUtil.java index e17e7fd9d..d3064b480 100644 --- a/kse/src/main/java/org/kse/crypto/jcepolicy/JcePolicyUtil.java +++ b/kse/src/main/java/org/kse/crypto/jcepolicy/JcePolicyUtil.java @@ -26,6 +26,7 @@ import java.io.IOException; import java.io.InputStreamReader; import java.io.StringWriter; +import java.nio.file.Path; import java.security.NoSuchAlgorithmException; import java.security.Security; import java.text.MessageFormat; @@ -167,9 +168,8 @@ public static String getPolicyDetails(JcePolicy jcePolicy) throws CryptoExceptio * @return JAR file */ public static File getJarFile(JcePolicy jcePolicy) { - String fileSeperator = System.getProperty("file.separator"); String javaHome = System.getProperty("java.home"); - File libSecurityFile = new File(javaHome, "lib" + fileSeperator + "security"); + File libSecurityFile = Path.of(javaHome, "lib", "security").toFile(); return new File(libSecurityFile, jcePolicy.jar()); } diff --git a/kse/src/main/java/org/kse/crypto/signing/JarParser.java b/kse/src/main/java/org/kse/crypto/signing/JarParser.java index b1a8ba6c0..aecae8fa1 100644 --- a/kse/src/main/java/org/kse/crypto/signing/JarParser.java +++ b/kse/src/main/java/org/kse/crypto/signing/JarParser.java @@ -49,31 +49,29 @@ public JarParser(File jarFile) { * @return Unordered array with signer certificates * @throws IOException if an I/O error has occurred */ - public X509Certificate[] getSignerCerificates() throws IOException { + public X509Certificate[] getSignerCertificates() throws IOException { try (JarFile jf = new JarFile(jarFile, true)) { - Set allSignerCerts = new HashSet<>(); Enumeration entries = jf.entries(); while (entries.hasMoreElements()) { - JarEntry entry = entries.nextElement(); - // reading entry completely is required for calling getCodeSigners()/getCertificates() readEntry(jf, entry); - if (!entry.isDirectory()) { - CodeSigner[] codeSigners = entry.getCodeSigners(); - if (codeSigners != null) { - for (CodeSigner cs : entry.getCodeSigners()) { - allSignerCerts.addAll(cs.getSignerCertPath().getCertificates()); - } + if (entry.isDirectory()) { + continue; + } + CodeSigner[] codeSigners = entry.getCodeSigners(); + if (codeSigners != null) { + for (CodeSigner cs : entry.getCodeSigners()) { + allSignerCerts.addAll(cs.getSignerCertPath().getCertificates()); } + } - Certificate[] certificates = entry.getCertificates(); - if (certificates != null) { - allSignerCerts.addAll(Arrays.asList(certificates)); - } + Certificate[] certificates = entry.getCertificates(); + if (certificates != null) { + allSignerCerts.addAll(Arrays.asList(certificates)); } } diff --git a/kse/src/main/java/org/kse/gui/CurrentDirectory.java b/kse/src/main/java/org/kse/gui/CurrentDirectory.java index 1f0af25b2..5da8b921d 100644 --- a/kse/src/main/java/org/kse/gui/CurrentDirectory.java +++ b/kse/src/main/java/org/kse/gui/CurrentDirectory.java @@ -43,7 +43,7 @@ private static void initialiseWorkingDirToBeHomeDir() { } /** - * Update CurrentSirectory to be the supplied directory. + * Update CurrentDirectory to be the supplied directory. * * @param directory Used to set current directory */ diff --git a/kse/src/main/java/org/kse/gui/actions/ExamineFileAction.java b/kse/src/main/java/org/kse/gui/actions/ExamineFileAction.java index 3e741537a..be9a9e419 100644 --- a/kse/src/main/java/org/kse/gui/actions/ExamineFileAction.java +++ b/kse/src/main/java/org/kse/gui/actions/ExamineFileAction.java @@ -110,7 +110,7 @@ public void openFile(File file) { switch (fileType) { case JAR: JarParser jarParser = new JarParser(file); - X509Certificate[] signerCertificates = jarParser.getSignerCerificates(); + X509Certificate[] signerCertificates = jarParser.getSignerCertificates(); showCerts(signerCertificates, file.getName()); break; case JCEKS_KS: diff --git a/kse/src/main/java/org/kse/gui/actions/ExportSelectedCertificatesAction.java b/kse/src/main/java/org/kse/gui/actions/ExportSelectedCertificatesAction.java index e558ae977..9bd74b66f 100644 --- a/kse/src/main/java/org/kse/gui/actions/ExportSelectedCertificatesAction.java +++ b/kse/src/main/java/org/kse/gui/actions/ExportSelectedCertificatesAction.java @@ -46,7 +46,7 @@ protected void doAction() { List listCertificate = getCertificates(); File exportFile = null; try { - if (listCertificate.size() > 0) { + if (!listCertificate.isEmpty()) { KeyStoreHistory history = kseFrame.getActiveKeyStoreHistory(); String fileName = FileNameUtil.removeExtension(history.getName()); DExportCertificates dExportCertificates = new DExportCertificates(frame, fileName, false, true); diff --git a/kse/src/main/java/org/kse/gui/crypto/DUpgradeCryptoStrength.java b/kse/src/main/java/org/kse/gui/crypto/DUpgradeCryptoStrength.java index 3878a5448..204666de9 100644 --- a/kse/src/main/java/org/kse/gui/crypto/DUpgradeCryptoStrength.java +++ b/kse/src/main/java/org/kse/gui/crypto/DUpgradeCryptoStrength.java @@ -45,6 +45,7 @@ import java.io.IOException; import java.net.URI; import java.nio.file.Files; +import java.nio.file.Path; import java.text.MessageFormat; import java.util.Enumeration; import java.util.List; @@ -80,7 +81,7 @@ import net.miginfocom.swing.MigLayout; /** - * Dialog to upgrade cyptography strength. + * Dialog to upgrade cryptography strength. */ public class DUpgradeCryptoStrength extends JEscDialog { private static final long serialVersionUID = 1L; @@ -234,10 +235,9 @@ private void upgradeFailedShowManualInstructions() { JOptionPane.WARNING_MESSAGE); String javaHome = System.getProperty("java.home"); - String fileSeparator = System.getProperty("file.separator"); - + String javaSecurityLibFolder = Path.of(javaHome, "lib", "security").toString(); String manualInstructions = MessageFormat.format( - res.getString("DUpgradeCryptoStrength.ManualInstructions.message"), javaHome, fileSeparator); + res.getString("DUpgradeCryptoStrength.ManualInstructions.message"), javaSecurityLibFolder); JOptionPane.showMessageDialog(this, manualInstructions, getTitle(), JOptionPane.INFORMATION_MESSAGE); } diff --git a/kse/src/main/java/org/kse/gui/crypto/policyinformation/DUserNoticeChooser.java b/kse/src/main/java/org/kse/gui/crypto/policyinformation/DUserNoticeChooser.java index 82d81b0b4..b7ef859c2 100644 --- a/kse/src/main/java/org/kse/gui/crypto/policyinformation/DUserNoticeChooser.java +++ b/kse/src/main/java/org/kse/gui/crypto/policyinformation/DUserNoticeChooser.java @@ -287,11 +287,9 @@ private void okPressed() { NoticeReference noticeReference = null; if (!organizationString.isEmpty()) { // If organization is present then so is al of notice reference - Vector noticeNumbers = new Vector<>(); - for (int noticeNumber : noticeNumberInts) { - noticeNumbers.add(new Integer(noticeNumber)); + noticeNumbers.add(noticeNumber); } noticeReference = new NoticeReference(organizationString, noticeNumbers); diff --git a/kse/src/main/java/org/kse/gui/dialogs/DialogHelper.java b/kse/src/main/java/org/kse/gui/dialogs/DialogHelper.java index b8e5abe9a..4d1cae4c2 100644 --- a/kse/src/main/java/org/kse/gui/dialogs/DialogHelper.java +++ b/kse/src/main/java/org/kse/gui/dialogs/DialogHelper.java @@ -114,8 +114,8 @@ public static void populateSigAlgs(KeyPairType keyPairType, PrivateKey privateKe */ public static void populatePkcs10Challenge(Attribute[] attributes, JTextField textField) { - ASN1ObjectIdentifier pkcs9AtChallengepassword = PKCSObjectIdentifiers.pkcs_9_at_challengePassword; - populateTextField(attributes, textField, pkcs9AtChallengepassword); + ASN1ObjectIdentifier pkcs9AtChallengePassword = PKCSObjectIdentifiers.pkcs_9_at_challengePassword; + populateTextField(attributes, textField, pkcs9AtChallengePassword); } /** diff --git a/kse/src/main/java/org/kse/gui/dialogs/extensions/DAddExtensionType.java b/kse/src/main/java/org/kse/gui/dialogs/extensions/DAddExtensionType.java index f90d3e5ca..0509e7599 100644 --- a/kse/src/main/java/org/kse/gui/dialogs/extensions/DAddExtensionType.java +++ b/kse/src/main/java/org/kse/gui/dialogs/extensions/DAddExtensionType.java @@ -192,9 +192,9 @@ private void populateExtensionTypes() { // Population is the supported set minus those already added ArrayList availableExtensions = new ArrayList<>(); - for (X509ExtensionType extentionType : SUPPORTED_EXTENSIONS) { - if (extensions.getExtensionValue(extentionType.oid()) == null) { - availableExtensions.add(extentionType); + for (X509ExtensionType extensionType : SUPPORTED_EXTENSIONS) { + if (extensions.getExtensionValue(extensionType.oid()) == null) { + availableExtensions.add(extensionType); } } diff --git a/kse/src/main/java/org/kse/gui/dialogs/extensions/DAddExtensions.java b/kse/src/main/java/org/kse/gui/dialogs/extensions/DAddExtensions.java index 31abc0bb1..f0c352eae 100644 --- a/kse/src/main/java/org/kse/gui/dialogs/extensions/DAddExtensions.java +++ b/kse/src/main/java/org/kse/gui/dialogs/extensions/DAddExtensions.java @@ -825,7 +825,7 @@ public static void saveTemplatePressed(X509ExtensionSet extensionsToSave, JDialo } /** - * Get chosen certficate extensions. + * Get chosen certificate extensions. * * @return Certificate extensions or null if dialog cancelled. */ diff --git a/kse/src/main/java/org/kse/gui/jar/DJarInfo.java b/kse/src/main/java/org/kse/gui/jar/DJarInfo.java index 89c67491f..391cf02ba 100644 --- a/kse/src/main/java/org/kse/gui/jar/DJarInfo.java +++ b/kse/src/main/java/org/kse/gui/jar/DJarInfo.java @@ -145,7 +145,7 @@ private JarFile[] getClassPathJars() throws IOException { Vector jars = new Vector<>(); String classPath = System.getProperty("java.class.path"); - String pathSeparator = System.getProperty("path.separator"); + String pathSeparator = File.pathSeparator; StringTokenizer strTok = new StringTokenizer(classPath, pathSeparator); diff --git a/kse/src/main/java/org/kse/utilities/history/KeyStoreHistory.java b/kse/src/main/java/org/kse/utilities/history/KeyStoreHistory.java index ad4caef12..c8e713678 100644 --- a/kse/src/main/java/org/kse/utilities/history/KeyStoreHistory.java +++ b/kse/src/main/java/org/kse/utilities/history/KeyStoreHistory.java @@ -91,14 +91,10 @@ public KeyStoreState getCurrentState() { public void nullPasswords() { KeyStoreState state = initialState; - while (true) { + do { state.nullPasswords(); state = state.nextState(); - - if (state == null) { - break; - } - } + } while (state != null); } /** diff --git a/kse/src/main/java/org/kse/utilities/oid/ObjectIdUtil.java b/kse/src/main/java/org/kse/utilities/oid/ObjectIdUtil.java index 910438aea..f444e1a64 100644 --- a/kse/src/main/java/org/kse/utilities/oid/ObjectIdUtil.java +++ b/kse/src/main/java/org/kse/utilities/oid/ObjectIdUtil.java @@ -2311,8 +2311,7 @@ private static void validate(int[] arcs) throws InvalidObjectIdException { */ public static ObjectOid[] getAllOidsStartingWith(String prefix) { ObjectOid[] oids = oidToNameMapping.entrySet().stream().filter(e -> e.getKey().startsWith(prefix)) - .map(e -> new ObjectOid(prefix, e.getKey(), e.getValue())).sorted() - .collect(Collectors.toList()).toArray(new ObjectOid[0]); + .map(e -> new ObjectOid(prefix, e.getKey(), e.getValue())).sorted().toArray(ObjectOid[]::new); return oids; } diff --git a/kse/src/main/resources/org/kse/gui/actions/resources_ru.properties b/kse/src/main/resources/org/kse/gui/actions/resources_ru.properties index f6c8e7d97..aabec2de9 100644 --- a/kse/src/main/resources/org/kse/gui/actions/resources_ru.properties +++ b/kse/src/main/resources/org/kse/gui/actions/resources_ru.properties @@ -110,6 +110,9 @@ ExportKeyPairAction.ExportKeyPair.Title=\u042D\u043A\u0441\u043F\u043E\u0440\u04 ExportKeyPairAction.text=\u042D\u043A\u0441\u043F\u043E\u0440\u0442\u0438\u0440\u043E\u0432\u0430\u0442\u044C \u043F\u0430\u0440\u0443 \u043A\u043B\u044E\u0447\u0435\u0439 ExportKeyPairAction.tooltip=\u042D\u043A\u0441\u043F\u043E\u0440\u0442\u0438\u0440\u043E\u0432\u0430\u0442\u044C \u0437\u0430\u043F\u0438\u0441\u044C \u043F\u0430\u0440\u044B \u043A\u043B\u044E\u0447\u0435\u0439 ExportKeyPairCertificateChainAction.ExportCertificateChain.Title=\u042D\u043A\u0441\u043F\u043E\u0440\u0442\u0438\u0440\u043E\u0432\u0430\u0442\u044C \u0446\u0435\u043F\u043E\u0447\u043A\u0443 \u0441\u0435\u0440\u0442\u0438\u0444\u0438\u043A\u0430\u0442\u0430 +ExportKeyPairCertificateChainAction.ExportCertificateChainSuccessful.message=\u042D\u043A\u0441\u043F\u043E\u0440\u0442 \u0446\u0435\u043F\u043E\u0447\u043A\u0438 \u0441\u0435\u0440\u0442\u0438\u0444\u0438\u043A\u0430\u0442\u0430 \u0443\u0441\u043F\u0435\u0448\u0435\u043D. +ExportKeyPairCertificateChainAction.statusbar=\u042D\u043A\u0441\u043F\u043E\u0440\u0442\u0438\u0440\u043E\u0432\u0430\u0442\u044C \u0446\u0435\u043F\u043E\u0447\u043A\u0443 \u0441\u0435\u0440\u0442\u0438\u0444\u0438\u043A\u0430\u0442\u0430 \u0437\u0430\u043F\u0438\u0441\u0438 \u043F\u0430\u0440\u044B \u043A\u043B\u044E\u0447\u0435\u0439 \u043A\u0430\u043A X.509, PKCS #7, PKI Path \u0438\u043B\u0438 SPC +ExportKeyPairCertificateChainAction.text=\u042D\u043A\u0441\u043F\u043E\u0440\u0442\u0438\u0440\u043E\u0432\u0430\u0442\u044C \u0446\u0435\u043F\u043E\u0447\u043A\u0443 \u0441\u0435\u0440\u0442\u0438\u0444\u0438\u043A\u0430\u0442\u0430 ExportKeyPairPrivateKeyAction.ExportPrivateKeyPvk.Title=\u042D\u043A\u0441\u043F\u043E\u0440\u0442\u0438\u0440\u043E\u0432\u0430\u0442\u044C \u043F\u0440\u0438\u0432\u0430\u0442\u043D\u044B\u0439 \u043A\u043B\u044E\u0447 \u043A\u0430\u043A PVK ExportKeyPairPrivateKeyAction.text=\u042D\u043A\u0441\u043F\u043E\u0440\u0442\u0438\u0440\u043E\u0432\u0430\u0442\u044C \u043F\u0440\u0438\u0432\u0430\u0442\u043D\u044B\u0439 \u043A\u043B\u044E\u0447 ExportKeyPairPublicKeyAction.text=\u042D\u043A\u0441\u043F\u043E\u0440\u0442\u0438\u0440\u043E\u0432\u0430\u0442\u044C \u043E\u0442\u043A\u0440\u044B\u0442\u044B\u0439 \u043A\u043B\u044E\u0447 @@ -210,10 +213,11 @@ OpenCaCertificatesAction.OpenCaCertificatesKeyStore.Title=\u041E\u0442\u043A\u04 OpenCaCertificatesAction.statusbar=\u041E\u0442\u043A\u0440\u044B\u0442\u044C \u0445\u0440\u0430\u043D\u0438\u043B\u0438\u0449\u0435 \u0441\u0435\u0440\u0442\u0438\u0444\u0438\u043A\u0430\u0442\u043E\u0432 \u0423\u0434\u043E\u0441\u0442\u043E\u0432\u0435\u0440\u044F\u044E\u0449\u0438\u0445 \u0426\u0435\u043D\u0442\u0440\u043E\u0432 (\u0423\u0426) OpenCaCertificatesAction.text=\u041E\u0442\u043A\u0440\u044B\u0442\u044C \u0441\u0435\u0440\u0442\u0438\u0444\u0438\u043A\u0430\u0442\u044B \u0423\u0426 OpenCaCertificatesAction.tooltip=\u041E\u0442\u043A\u0440\u044B\u0442\u044C \u0441\u0435\u0440\u0442\u0438\u0444\u0438\u043A\u0430\u0442\u044B \u0423\u0426 +OpenDefaultAction.NoDefaultKeyStoreCreate.message=\u0425\u0440\u0430\u043D\u0438\u043B\u0438\u0449\u0435 \u043A\u043B\u044E\u0447\u0435\u0439 \u043F\u043E \u0443\u043C\u043E\u043B\u0447\u0430\u043D\u0438\u044E \u043E\u0442\u0441\u0443\u0442\u0441\u0442\u0432\u0443\u0435\u0442.\n\u0412\u044B \u0436\u0435\u043B\u0430\u0435\u0442\u0435 \u0435\u0433\u043E \u0441\u043E\u0437\u0434\u0430\u0442\u044C? OpenDefaultAction.OpenDefaultKeyStore.Title=\u041E\u0442\u043A\u0440\u044B\u0442\u044C \u0445\u0440\u0430\u043D\u0438\u043B\u0438\u0449\u0435 \u043A\u043B\u044E\u0447\u0435\u0439 \u043F\u043E \u0443\u043C\u043E\u043B\u0447\u0430\u043D\u0438\u044E OpenDefaultAction.statusbar=\u041E\u0442\u043A\u0440\u044B\u0442\u044C \u0445\u0440\u0430\u043D\u0438\u043B\u0438\u0449\u0435 \u043A\u043B\u044E\u0447\u0435\u0439 \u043F\u043E \u0443\u043C\u043E\u043B\u0447\u0430\u043D\u0438\u044E -OpenDefaultAction.text=\u041E\u0442\u043A\u0440\u044B\u0442\u044C \u043F\u043E \u0443\u043C\u043E\u043B\u0447\u0430\u043D\u0438\u044E -OpenDefaultAction.tooltip=\u041E\u0442\u043A\u0440\u044B\u0442\u044C \u043F\u043E \u0443\u043C\u043E\u043B\u0447\u0430\u043D\u0438\u044E +OpenDefaultAction.text=\u041E\u0442\u043A\u0440\u044B\u0442\u044C \u0445\u0440\u0430\u043D\u0438\u043B\u0438\u0449\u0435 \u043F\u043E \u0443\u043C\u043E\u043B\u0447\u0430\u043D\u0438\u044E +OpenDefaultAction.tooltip=\u041E\u0442\u043A\u0440\u044B\u0442\u044C \u0445\u0440\u0430\u043D\u0438\u043B\u0438\u0449\u0435 \u043F\u043E \u0443\u043C\u043E\u043B\u0447\u0430\u043D\u0438\u044E OpenMsCapiAction.TabTitle=Windows-MY OpenMsCapiAction.text=\u041E\u0442\u043A\u0440\u044B\u0442\u044C Windows-MY OpenMsCapiAction.tooltip=\u041E\u0442\u043A\u0440\u044B\u0442\u044C \u0445\u0440\u0430\u043D\u0438\u043B\u0438\u0449\u0435 \u043A\u043B\u044E\u0447\u0435\u0439 Windows-MY diff --git a/kse/src/main/resources/org/kse/gui/crypto/resources.properties b/kse/src/main/resources/org/kse/gui/crypto/resources.properties index 563ca85e5..ef4a9ab86 100644 --- a/kse/src/main/resources/org/kse/gui/crypto/resources.properties +++ b/kse/src/main/resources/org/kse/gui/crypto/resources.properties @@ -59,7 +59,7 @@ DProviderInfo.jbCopy.text = Copy DProviderInfo.jbCopy.tooltip = Copy security provider information to the clipboard DProviderInfo.jbOK.text = OK -DUpgradeCryptoStrength.ManualInstructions.message = Manual Instructions to Upgrade Cryptography Strength

Press OK to exit KeyStore Explorer before proceeding with these instructions as it can lock existing policy files.
  1. Open the Unlimited Strength Jurisdiction Policy ZIP and extract the files local_policy.jar and US_export_policy.jar.
  2. Locate the Java Security Lib folder on your computer: {0}{1}lib{1}security.
  3. Make backup copies the existing local_policy.jar and US_export_policy.jar files present in the Java Security Lib folder.
  4. Copy the extracted copies of the local_policy.jar and US_export_policy.jar files into the Java Security Lib folder.
  5. Restart KeyStore Explorer for the above steps to take effect.
+DUpgradeCryptoStrength.ManualInstructions.message = Manual Instructions to Upgrade Cryptography Strength

Press OK to exit KeyStore Explorer before proceeding with these instructions as it can lock existing policy files.
  1. Open the Unlimited Strength Jurisdiction Policy ZIP and extract the files local_policy.jar and US_export_policy.jar.
  2. Locate the Java Security Lib folder on your computer: {0}.
  3. Make backup copies the existing local_policy.jar and US_export_policy.jar files present in the Java Security Lib folder.
  4. Copy the extracted copies of the local_policy.jar and US_export_policy.jar files into the Java Security Lib folder.
  5. Restart KeyStore Explorer for the above steps to take effect.
DUpgradeCryptoStrength.NoLaunchBrowser.message = Could not launch web browser. Policy download web address is ''{0}''. DUpgradeCryptoStrength.NoUpdatePolicy.message = Could not upgrade cryptography strength automatically.\nThis was probably due to insufficient privileges.\nManual upgrade instructions will now be displayed. DUpgradeCryptoStrength.NotPolicyZip.message = The supplied file is not a valid Unlimited Strength Jurisdiction Policy ZIP. diff --git a/kse/src/main/resources/org/kse/gui/crypto/resources_de.properties b/kse/src/main/resources/org/kse/gui/crypto/resources_de.properties index fc7523285..34e540a2a 100644 --- a/kse/src/main/resources/org/kse/gui/crypto/resources_de.properties +++ b/kse/src/main/resources/org/kse/gui/crypto/resources_de.properties @@ -60,7 +60,7 @@ DProviderInfo.jbCopy.text = Kopieren DProviderInfo.jbCopy.tooltip = Informationen zum Sicherheitsanbieter in die Zwischenablage kopieren DProviderInfo.jbOK.text = OK -DUpgradeCryptoStrength.ManualInstructions.message = Anleitung zum manuellen Upgrade der kryptographischen St\u00E4rke

Klicken Sie auf \u00BBOK\u00AB um \u00BBKeystore Explorer\u00AB zu verlassen, bevor sie mit diesen Anweisungen fortfahren. Die Richtlinien-Dateien k\u00F6nnten durch diese Anwendung gesperrt sein.
  1. \u00D6ffnen sie die Archivdatei \u00BBUnlimited Strength Jurisdiction Policy ZIP\u00AB und entpacken daraus die Dateien local_policy.jar und US_export_policy.jar.
  2. Navigieren sie zum Verzeichnis Java Security Bibliotheken auf ihrem Computer: {0}{1}lib{1}security.
  3. Erstellen sie eine Sicherheitskopie der in diesem Verzeichnis vorhandenen Dateien local_policy.jar und US_export_policy.jar.
  4. Kopieren sie die zuvor entpackten Dateien local_policy.jar und US_export_policy.jar in das Verzeichnis Java Security Bibliotheken.
  5. Beim n\u00E4chsten Start von \u00BBKeyStore Explorer\u00AB werden die neuen Richtlinien angewendet.
+DUpgradeCryptoStrength.ManualInstructions.message = Anleitung zum manuellen Upgrade der kryptographischen St\u00E4rke

Klicken Sie auf \u00BBOK\u00AB um \u00BBKeystore Explorer\u00AB zu verlassen, bevor sie mit diesen Anweisungen fortfahren. Die Richtlinien-Dateien k\u00F6nnten durch diese Anwendung gesperrt sein.
  1. \u00D6ffnen sie die Archivdatei \u00BBUnlimited Strength Jurisdiction Policy ZIP\u00AB und entpacken daraus die Dateien local_policy.jar und US_export_policy.jar.
  2. Navigieren sie zum Verzeichnis Java Security Bibliotheken auf ihrem Computer: {0}.
  3. Erstellen sie eine Sicherheitskopie der in diesem Verzeichnis vorhandenen Dateien local_policy.jar und US_export_policy.jar.
  4. Kopieren sie die zuvor entpackten Dateien local_policy.jar und US_export_policy.jar in das Verzeichnis Java Security Bibliotheken.
  5. Beim n\u00E4chsten Start von \u00BBKeyStore Explorer\u00AB werden die neuen Richtlinien angewendet.
DUpgradeCryptoStrength.NoLaunchBrowser.message = Der Webbrowser konnte nicht gestartet werden. Die Download-Adresse ist \u00BB{0}\u00AB. DUpgradeCryptoStrength.NoUpdatePolicy.message = Die kryptographische St\u00E4rke konnte nicht automatisch auf unbegrenzt erweitert werden.\nVermutlich aufgrund fehlender Berechtigungen.\nEine Anleitung zur manuellen Erweiterung wird nun angezeigt. DUpgradeCryptoStrength.NotPolicyZip.message = Das angegebene ZIP-Archiv enth\u00E4lt keine g\u00FCltigen \u00BBUnlimited Strength Jurisdiction Policy\u00AB Dateien. diff --git a/kse/src/main/resources/org/kse/gui/crypto/resources_fr.properties b/kse/src/main/resources/org/kse/gui/crypto/resources_fr.properties index 97e149b39..88d7ee79f 100644 --- a/kse/src/main/resources/org/kse/gui/crypto/resources_fr.properties +++ b/kse/src/main/resources/org/kse/gui/crypto/resources_fr.properties @@ -60,7 +60,7 @@ DProviderInfo.jbCopy.text = Copier DProviderInfo.jbCopy.tooltip = Copier les informations du fournisseur de s\u00E9curit\u00E9 dans le presse\u2010papiers DProviderInfo.jbOK.text = Valider -DUpgradeCryptoStrength.ManualInstructions.message = Instructions de mise \u00E0 niveau manuelle de la robustesse cryptographique

Veuillez cliquer sur le bouton OK pour quitter KeyStore Explorer avant d\u2019ex\u00E9cuter les instructions suivantes car cela peut verrouiller le fichier existant\u00A0:
  1. ouvrir l\u2019archive ZIP \u00AB\u00A0Unlimited Strength Jurisdiction Policy\u00A0\u00BB et extraire les fichiers local_policy.jar et US_export_policy.jar.
  2. Localiser le r\u00E9pertoire des biblioth\u00E8ques de s\u00E9curit\u00E9 de Java sur votre ordinateur\u00A0: {0}{1}lib{1}security\u202F;
  3. faites des copies de sauvegarde des fichiers local_policy.jar et US_export_policy.jar pr\u00E9sents dans le r\u00E9pertoire des biblioth\u00E8ques de s\u00E9curit\u00E9 de Java\u202F;
  4. copier les fichiers local_policy.jar et US_export_policy.jar extraits de l\u2019archive ZIP dans le r\u00E9pertoire des biblioth\u00E8ques de s\u00E9curit\u00E9 de Java\u202F;
  5. red\u00E9marrer KeyStore Explorer pour que les changements soient pris en compte.
+DUpgradeCryptoStrength.ManualInstructions.message = Instructions de mise \u00E0 niveau manuelle de la robustesse cryptographique

Veuillez cliquer sur le bouton OK pour quitter KeyStore Explorer avant d\u2019ex\u00E9cuter les instructions suivantes car cela peut verrouiller le fichier existant\u00A0:
  1. ouvrir l\u2019archive ZIP \u00AB\u00A0Unlimited Strength Jurisdiction Policy\u00A0\u00BB et extraire les fichiers local_policy.jar et US_export_policy.jar.
  2. Localiser le r\u00E9pertoire des biblioth\u00E8ques de s\u00E9curit\u00E9 de Java sur votre ordinateur\u00A0: {0}\u202F;
  3. faites des copies de sauvegarde des fichiers local_policy.jar et US_export_policy.jar pr\u00E9sents dans le r\u00E9pertoire des biblioth\u00E8ques de s\u00E9curit\u00E9 de Java\u202F;
  4. copier les fichiers local_policy.jar et US_export_policy.jar extraits de l\u2019archive ZIP dans le r\u00E9pertoire des biblioth\u00E8ques de s\u00E9curit\u00E9 de Java\u202F;
  5. red\u00E9marrer KeyStore Explorer pour que les changements soient pris en compte.
DUpgradeCryptoStrength.NoLaunchBrowser.message = Impossible de lancer le navigateur Web. L\u2019adresse de t\u00E9l\u00E9chargement de l\u2019archive est \u00AB\u00A0{0}\u00A0\u00BB. DUpgradeCryptoStrength.NoUpdatePolicy.message = Impossible de mettre \u00E0 niveau la robustesse cryptographique automatiquement.\nCela est probablement d\u00FB \u00E0 des privil\u00E8ges insuffisants.\nLes instructions de mise \u00E0 niveau manuelle vont \u00E0 pr\u00E9sent \u00EAtre affich\u00E9es. DUpgradeCryptoStrength.NotPolicyZip.message = Le fichier founit n\u2019est pas une archive ZIP permettant la politique de robustesse cryptographique illimit\u00E9e. diff --git a/kse/src/main/resources/org/kse/gui/dialogs/importexport/resources_ru.properties b/kse/src/main/resources/org/kse/gui/dialogs/importexport/resources_ru.properties index 55c49dba9..804b76049 100644 --- a/kse/src/main/resources/org/kse/gui/dialogs/importexport/resources_ru.properties +++ b/kse/src/main/resources/org/kse/gui/dialogs/importexport/resources_ru.properties @@ -1,3 +1,5 @@ +DExportCertificates.CertificateChain.Simple.Title=\u042D\u043A\u0441\u043F\u043E\u0440\u0442\u0438\u0440\u043E\u0432\u0430\u0442\u044C \u0446\u0435\u043F\u043E\u0447\u043A\u0443 \u0441\u0435\u0440\u0442\u0438\u0444\u0438\u043A\u0430\u0442\u0430 +DExportCertificates.CertificateChain.Title=\u042D\u043A\u0441\u043F\u043E\u0440\u0442\u0438\u0440\u043E\u0432\u0430\u0442\u044C \u0446\u0435\u043F\u043E\u0447\u043A\u0443 \u0441\u0435\u0440\u0442\u0438\u0444\u0438\u043A\u0430\u0442\u0430 ''{0}'' DExportCertificates.ChooseExportFile.button=\u0412\u044B\u0431\u0440\u0430\u0442\u044C DExportCertificates.jbBrowse.mnemonic=B DExportCertificates.jbBrowse.text=\u041F\u0440\u043E\u0441\u043C\u043E\u0442\u0440\u0435\u0442\u044C diff --git a/kse/src/main/resources/org/kse/gui/password/resources_ru.properties b/kse/src/main/resources/org/kse/gui/password/resources_ru.properties index 187bc5c96..144d0e90e 100644 --- a/kse/src/main/resources/org/kse/gui/password/resources_ru.properties +++ b/kse/src/main/resources/org/kse/gui/password/resources_ru.properties @@ -1,7 +1,7 @@ DGetPassword.Title=\u041F\u043E\u043B\u0443\u0447\u0438\u0442\u044C \u043F\u0430\u0440\u043E\u043B\u044C DGetPassword.jbOK.text=OK DGetPassword.jbCancel.text=\u041E\u0442\u043C\u0435\u043D\u0430 -DGetPassword.jlPassword.text=\u0412\u0432\u0435\u0434\u0438\u0442\u0435 \u043D\u043E\u0432\u044B\u0439 \u043F\u0430\u0440\u043E\u043B\u044C: +DGetPassword.jlPassword.text=\u0412\u0432\u0435\u0434\u0438\u0442\u0435 \u043F\u0430\u0440\u043E\u043B\u044C: DGetNewPassword.Title=\u041F\u043E\u043B\u0443\u0447\u0438\u0442\u044C \u043D\u043E\u0432\u044B\u0439 \u043F\u0430\u0440\u043E\u043B\u044C DGetNewPassword.jbOK.text=OK DGetNewPassword.jbCancel.text=\u041E\u0442\u043C\u0435\u043D\u0430