Ubuntu上的OpenJDK中的Java SSL是否已损坏? [英] Is Java SSL broken in OpenJDK on Ubuntu?
问题描述
刚刚安装了OpenJDK,我正在全新安装Ubuntu:
I am on a fresh install of Ubuntu having just installed OpenJDK:
OpenJDK 64-Bit Server VM (build 19.0-b09, mixed mode) on Ubuntu 64 bit 10.10
不确定这是否相关,但我是从VMWare Fusion中运行它。
Not sure if this is relevant, but I'm running it from within VMWare Fusion.
以下行:
javax.net.SSLContext.getDefault(); // same as getInstance("Default")
throws the following exception:
java.net.SocketException: java.security.NoSuchAlgorithmException: Default SSLContext not available
我的同事和我已经在几台机器上尝试了这一点,所有新安装的Ubuntu,并继续得到这个。我被建议尝试getInstance(TLSv1),但这引发了同样的错误。看起来像是一些非常基本的工作,所以我认为我们必须做错事。
My colleagues and I have tried this on several machines, all fresh installs of Ubuntu, and keep getting this. I was advised to try getInstance("TLSv1"), but this threw the same error. Seems like something really fundamental to not be working so I figure we must be doing something wrong.
推荐答案
guido的回答指出我在正确的方向。这只是一个问题:
guido's answer pointed me in the right direction. It's just a matter of doing:
sudo apt-get install libbcprov-java
这篇关于Ubuntu上的OpenJDK中的Java SSL是否已损坏?的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持IT屋!