我有一个Java EE 7,SE 8项目(glassfish 4.1,JSF,JPA,EJB)(Eclipse Neon)。它曾经正常工作。现在,当我开始使用glassfish时,它告诉我证书已经过期。
2018-10-17T19:35:58.516+0000|Info: visiting unvisited references
2018-10-17T19:35:59.920+0000|Severe: The SSL certificate has expired: [
[
Version: V3
Subject: OU=Equifax Secure Certificate Authority, O=Equifax, C=US
Signature Algorithm: SHA1withRSA, OID = 1.2.840.113549.1.1.5
Key: Sun RSA public key, 1024 bits
modulus: 135786214035069526348186531221551781468391756233528066061569654028671100866720352830303278016129003918213826297308054231261658522889438712013757624116391437358730449661353175673177742307421061340003741057138887918110217006515773038453829253517076741780039735595086881329494037450587568122088113584549069375417
public exponent: 65537
Validity: [From: Sat Aug 22 16:41:51 UTC 1998,
To: Wed Aug 22 16:41:51 UTC 2018]
Issuer: OU=Equifax Secure Certificate Authority, O=Equifax, C=US
SerialNumber: [ 35def4cf]
Certificate Extensions: 7
[1]: ObjectId: 1.2.840.113533.7.65.0 Criticality=false
Extension unknown: DER encoded OCTET string =
0000: 04 0D 30 0B 1B 05 56 33 2E 30 63 03 02 06 C0 ..0...V3.0c....
[2]: ObjectId: 2.5.29.35 Criticality=false
AuthorityKeyIdentifier [
KeyIdentifier [
0000: 48 E6 68 F9 2B D2 B2 95 D7 47 D8 23 20 10 4F 33 H.h.+....G.# .O3
0010: 98 90 9F D4 ....
]
]
[3]: ObjectId: 2.5.29.19 Criticality=false
BasicConstraints:[
CA:true
PathLen:2147483647
]
[4]: ObjectId: 2.5.29.31 Criticality=false
CRLDistributionPoints [
[DistributionPoint:
[CN=CRL1, OU=Equifax Secure Certificate Authority, O=Equifax, C=US]
现在,glassfish仍然可以启动并正常运行,因此项目也是如此。问题是上面最后一行后面的控制台中没有任何显示。但是,当我打开日志文件server.log时,每个文件都被写入那里。
我注意到打印这两个字符会导致问题]]
这来自日志文件:
[4]: ObjectId: 2.5.29.31 Criticality=false
CRLDistributionPoints [
[DistributionPoint:
[CN=CRL1, OU=Equifax Secure Certificate Authority, O=Equifax, C=US]
]]
[5]: ObjectId: 2.5.29.15 Criticality=false…
I tried to print those lines to see if Eclipse would print them and it did print them.
public static void main(String[] args) {
System.out.println("[4]: ObjectId: 2.5.29.31 Criticality=false");
System.out.println("CRLDistributionPoints [");
System.out.println(" [DistributionPoint:");
System.out.println(" [CN=CRL1, OU=Equifax Secure Certificate Authority, O=Equifax, C=US]");
System.out.println("]]");
System.out.println("");
System.out.println("[5]: ObjectId: 2.5.29.15 Criticality=false");
}
那是什么问题?我该如何解决?
我尝试使用keytool –list列出证书以删除已过期的证书。但是我收到此keytool错误:java.lang.Exception:密钥库文件不存在:C:\ Users \ Name \ .keystore
注意:Eclipse Photon中也会发生同样的事情。
答案 0 :(得分:1)
D:\Dev\Servers\glassfish4\glassfish\domains\domain1\config
keytool -list -keystore cacerts.jks -v
keytool -delete -alias equifaxsecureca -keystore
cacerts.jks