【问题标题】:Not able to find KeyTool class in 1.7 java for AIX无法在 1.7 java for AIX 中找到 KeyTool 类
【发布时间】:2019-06-04 11:23:19
【问题描述】:

我正在尝试使用 Java 1.7 使用 JarSigner API 对 jar 进行签名。这适用于 Linux 和 Windows 机器,但在 AIX 机器中失败并出现 classnotfound 异常(对于类“sun.security.tools.KeyTool”)。

我也找不到 IBM 所说的“com.ibm.crypto.tools.KeyTool”类的 jar。

【问题讨论】:

  • 您好,您对这些包在您的 java 运行时中的重要性如何?

标签: java aix


【解决方案1】:

在 IBM/Java6 中,有一个 $JRE_HOME/lib/rt.jar(sun/security/tools/JarSigner.class) 和一个 $JRE_HOME/lib/ext/ibmjceprovider(com/ibm/crypto/tools/KeyTool.class)

在 IBM/Java7 中,有 $JDK_HOME/lib/tools.jar(sun/security/tools/JarSigner.class)$JRE_HOME/lib/ext/ibmjceprovider(com/ibm/crypto/tools/KeyTool.class)

您可以将此“tools.jar”添加到CLASSPATH

请注意,在 IBM/Java8 中,$JDK_HOME/lib/tools.jar 中没有 sun/security/tools/JarSigner.class,但有 sun/security/tools/jarsigner/Main.class

【讨论】:

    猜你喜欢
    • 2013-11-11
    • 1970-01-01
    • 1970-01-01
    • 1970-01-01
    • 2018-07-23
    • 1970-01-01
    • 2016-09-09
    • 2023-03-24
    • 2011-11-09
    相关资源
    最近更新 更多