[ 登录 ] - [ 注册 ] | 代码示例DEMO | IP测试视频

java.security.ProviderException: java.security.KeyException

作者:数据无忧   时间:2020-09-18 13:24:53


最近做爬虫请求HTTPS网址的时候报错如下:

Caused by: java.security.ProviderException: java.security.KeyException at sun.security.ec.ECKeyPairGenerator.generateKeyPair(ECKeyPairGenerator.java:146) at java.security.KeyPairGenerator$Delegate.generateKeyPair(KeyPairGenerator.java:704) at sun.security.ssl.ECDHCrypt.<init>(ECDHCrypt.java:78) at sun.security.ssl.ClientHandshaker.serverKeyExchange(ClientHandshaker.java:717) at sun.security.ssl.ClientHandshaker.processMessage(ClientHandshaker.java:278) at sun.security.ssl.Handshaker.processLoop(Handshaker.java:913) at sun.security.ssl.Handshaker.process_record(Handshaker.java:849) at sun.security.ssl.SSLSocketImpl.readRecord(SSLSocketImpl.java:1035) at sun.security.ssl.SSLSocketImpl.performInitialHandshake(SSLSocketImpl.java:1344) at sun.security.ssl.SSLSocketImpl.startHandshake(SSLSocketImpl.java:1371) ... 52 more Caused by: java.security.KeyException at sun.security.ec.ECKeyPairGenerator.generateECKeyPair(Native Method) at sun.security.ec.ECKeyPairGenerator.generateKeyPair(ECKeyPairGenerator.java:126) ... 61 more

我的JDK环境是sun的1.8.0,操作系统CentOS 6.5

运行如下linux命令后程序可以完美运行,BUG解决:yum upgrade nss







无忧代理IP(www.data5u.com)原创文章,转载请注明出处。

电话:4007-745-096
QQ:
周一至周日8:30-18:00 技术部电话热线