Legacy Java code use of com.sun.net.ssl.internal.ssl.Provider()
问题 I am working with some code from back in 2003. There is a reference to the following class: new com.sun.net.ssl.internal.ssl.Provider() It is causing an error: Access restriction: The type Provider is not accessible due to restriction on required library /Library/Java/JavaVirtualMachines/1.7.0.jdk/Contents/Home/jre/lib/jsse.jar Does anyone have any suggestions for a suitable alternative to using this class? 回答1: Most of the time, you don't actually need to create or get hold of a provider