← Back to team overview

openjdk team mailing list archive

[Bug 234025] Re: java.security.NoSuchAlgorithmException: Error constructing implementation (algorithm: Default, provider: SunJSSE, class: sun.security.ssl.DefaultSSLContextImpl)

 

FWIW SunJSSE.java is in the source distribution.

dherron@dherron:~/jdk6-open$ find . -type f -name '*JSSE*' -print
./6open-b09/control/build/linux-i586/classes/sun/security/ssl/SunJSSE.class
./6open-b09/jdk/src/share/classes/sun/security/ssl/SunJSSE.java

-- 
java.security.NoSuchAlgorithmException: Error constructing implementation (algorithm: Default, provider: SunJSSE, class: sun.security.ssl.DefaultSSLContextImpl)
https://bugs.launchpad.net/bugs/234025
You received this bug notification because you are a member of OpenJDK,
which is subscribed to openjdk-6 in ubuntu.

Status in Source Package "openjdk-6" in Ubuntu: New
Status in Source Package "sun-java6" in Ubuntu: New

Bug description:
i just tried a google calendar test application as stated here:  http://code.google.com/apis/gdata/client-java.html http://code.google.com/apis/calendar/developers_guide_java.html#GettingStarted 

when running my code with openjdk as well as sun-java6 i get the following errors:

Exception in thread "main" com.google.gdata.util.AuthenticationException: Error connecting with login URI
	at com.google.gdata.client.GoogleService.getAuthToken(Unknown Source)
	at com.google.gdata.client.GoogleService.setUserCredentials(Unknown Source)
	at com.google.gdata.client.GoogleService.setUserCredentials(Unknown Source)
	at org.sozialverein.controller.GoogleCalendar.main(GoogleCalendar.java:32)
Caused by: java.net.SocketException: java.security.NoSuchAlgorithmException: Error constructing implementation (algorithm: Default, provider: SunJSSE, class: sun.security.ssl.DefaultSSLContextImpl)
	at javax.net.ssl.DefaultSSLSocketFactory.throwException(SSLSocketFactory.java:196)
	at javax.net.ssl.DefaultSSLSocketFactory.createSocket(SSLSocketFactory.java:216)
	at sun.net.www.protocol.https.HttpsClient.afterConnect(HttpsClient.java:383)
	at sun.net.www.protocol.https.AbstractDelegateHttpsURLConnection.connect(AbstractDelegateHttpsURLConnection.java:185)
	at sun.net.www.protocol.http.HttpURLConnection.getOutputStream(HttpURLConnection.java:850)
	at sun.net.www.protocol.https.HttpsURLConnectionImpl.getOutputStream(HttpsURLConnectionImpl.java:250)
	at com.google.gdata.client.GoogleService.makePostRequest(Unknown Source)
	... 4 more
Caused by: java.security.NoSuchAlgorithmException: Error constructing implementation (algorithm: Default, provider: SunJSSE, class: sun.security.ssl.DefaultSSLContextImpl)
	at java.security.Provider$Service.newInstance(Provider.java:1262)
	at sun.security.jca.GetInstance.getInstance(GetInstance.java:236)
	at sun.security.jca.GetInstance.getInstance(GetInstance.java:164)
	at javax.net.ssl.SSLContext.getInstance(SSLContext.java:142)
	at javax.net.ssl.SSLContext.getDefault(SSLContext.java:85)
	at javax.net.ssl.SSLSocketFactory.getDefault(SSLSocketFactory.java:119)
	at javax.net.ssl.HttpsURLConnection.getDefaultSSLSocketFactory(HttpsURLConnection.java:344)
	at javax.net.ssl.HttpsURLConnection.<init>(HttpsURLConnection.java:302)
	at sun.net.www.protocol.https.HttpsURLConnectionImpl.<init>(HttpsURLConnectionImpl.java:85)
	at sun.net.www.protocol.https.Handler.openConnection(Handler.java:62)
	at sun.net.www.protocol.https.Handler.openConnection(Handler.java:57)
	at java.net.URL.openConnection(URL.java:963)
	... 5 more
Caused by: java.lang.NullPointerException
	at sun.security.ssl.TrustManagerFactoryImpl.getCacertsKeyStore(TrustManagerFactoryImpl.java:205)
	at sun.security.ssl.DefaultSSLContextImpl.getDefaultTrustManager(DefaultSSLContextImpl.java:87)
	at sun.security.ssl.DefaultSSLContextImpl.<init>(DefaultSSLContextImpl.java:57)
	at sun.reflect.NativeConstructorAccessorImpl.newInstance0(Native Method)
	at sun.reflect.NativeConstructorAccessorImpl.newInstance(NativeConstructorAccessorImpl.java:57)
	at sun.reflect.DelegatingConstructorAccessorImpl.newInstance(DelegatingConstructorAccessorImpl.java:45)
	at java.lang.reflect.Constructor.newInstance(Constructor.java:532)
	at java.lang.Class.newInstance0(Class.java:372)
	at java.lang.Class.newInstance(Class.java:325)
	at java.security.Provider$Service.newInstance(Provider.java:1238)

i am sure this can be reduced some more general error. this is just the way i found it.



References