Hi,
I am a newbie using htmlparser.Does this support connections to secure websites(https connections).
I get the following error when conencting to a https site.
Any immediate help will be greatly appreciiated.
Thanks!!
org.htmlparser.util.ParserException: sun.security.validator.ValidatorException: No trusted certificate found;
javax.net.ssl.SSLHandshakeException: sun.security.validator.ValidatorException: No trusted certificate found
Exception!!sun.security.validator.ValidatorException: No trusted certificate found
at com.sun.net.ssl.internal.ssl.BaseSSLSocketImpl.a(DashoA12275)
at com.sun.net.ssl.internal.ssl.SSLSocketImpl.a(DashoA12275)
at com.sun.net.ssl.internal.ssl.SSLSocketImpl.a(DashoA12275)
at com.sun.net.ssl.internal.ssl.SunJSSE_az.a(DashoA12275)
at com.sun.net.ssl.internal.ssl.SunJSSE_az.a(DashoA12275)
at com.sun.net.ssl.internal.ssl.SunJSSE_ax.a(DashoA12275)
at com.sun.net.ssl.internal.ssl.SSLSocketImpl.a(DashoA12275)
at com.sun.net.ssl.internal.ssl.SSLSocketImpl.j(DashoA12275)
at com.sun.net.ssl.internal.ssl.SSLSocketImpl.startHandshake(DashoA12275)
at sun.net.www.protocol.https.HttpsClient.afterConnect(DashoA12275)
at sun.net.www.protocol.https.AbstractDelegateHttpsURLConnection.connect(DashoA12275)
at sun.net.www.protocol.https.HttpsURLConnectionImpl.connect(DashoA12275)
at org.htmlparser.http.ConnectionManager.openConnection(ConnectionManager.java:614)
at org.htmlparser.http.ConnectionManager.openConnection(ConnectionManager.java:792)
at org.htmlparser.Parser.<init>(Parser.java:251)
at org.htmlparser.Parser.<init>(Parser.java:261)
at fbot.FetchDtls.projDtls(FetchDtls.java:30)
at fbot.ProjSrch.invokeSrch(ProjSrch.java:60)
at fbot.ProjSrch$1.run(ProjSrch.java:36)
at java.util.TimerThread.mainLoop(Timer.java:432)
at java.util.TimerThread.run(Timer.java:382)
Caused by: sun.security.validator.ValidatorException: No trusted certificate found
at sun.security.validator.SimpleValidator.buildTrustedChain(SimpleValidator.java:304)
at sun.security.validator.SimpleValidator.engineValidate(SimpleValidator.java:107)
at sun.security.validator.Validator.validate(Validator.java:202)
at com.sun.net.ssl.internal.ssl.X509TrustManagerImpl.checkServerTrusted(DashoA12275)
at com.sun.net.ssl.internal.ssl.JsseX509TrustManager.checkServerTrusted(DashoA12275)
... 18 more
If you would like to refer to this comment somewhere else in this project, copy and paste the following link:
I didn't have problems running the parser on https://sourceforge.net, but I googled your error message and found the following relevant post in the JavaWorld forum:
<http://www.javaworld.com/javaforums/showthreaded.php?Cat=&Board=JavaSecurity&Number=14856&page=0&view=collapsed&sb=5&o=&vc=1>
Derrick.
<pre>
Hi. To solve the trusted certificate problem, you need to add the certificate of the machine that you're authenticating into to Java's "cacerts" trusted certificate keystore using keytool. However, to complicate matters if you're running Windows, there may be two copies of "cacerts" on your machine: one copy in your original Java installation directory, such as <C:\java\jre\lib\security\cacerts>, and one copy in the Java runtime environment's Program Files directory installation, such as <C:\Program Files\Java\j2re1.4.1_03\lib\security>. (I don't know about how to install trusted certificates on another platform.) I've found that Java looks to the "cacerts" in the Program Files installation directory for trusted certificates, but to be safe you should add the certificate to both "cacerts" keystores.
Check out the message thread on <http://www.javaworld.com/javaforums/showflat.php?Cat=2&Board=JavaSecurity&Number=7511&page=0&view=collapsed&sb=5&o=&fpart=1> for more info.
Hope that helps!
Raj
</pre>
If you would like to refer to this comment somewhere else in this project, copy and paste the following link:
Hi,
I am a newbie using htmlparser.Does this support connections to secure websites(https connections).
I get the following error when conencting to a https site.
Any immediate help will be greatly appreciiated.
Thanks!!
org.htmlparser.util.ParserException: sun.security.validator.ValidatorException: No trusted certificate found;
javax.net.ssl.SSLHandshakeException: sun.security.validator.ValidatorException: No trusted certificate found
Exception!!sun.security.validator.ValidatorException: No trusted certificate found
at com.sun.net.ssl.internal.ssl.BaseSSLSocketImpl.a(DashoA12275)
at com.sun.net.ssl.internal.ssl.SSLSocketImpl.a(DashoA12275)
at com.sun.net.ssl.internal.ssl.SSLSocketImpl.a(DashoA12275)
at com.sun.net.ssl.internal.ssl.SunJSSE_az.a(DashoA12275)
at com.sun.net.ssl.internal.ssl.SunJSSE_az.a(DashoA12275)
at com.sun.net.ssl.internal.ssl.SunJSSE_ax.a(DashoA12275)
at com.sun.net.ssl.internal.ssl.SSLSocketImpl.a(DashoA12275)
at com.sun.net.ssl.internal.ssl.SSLSocketImpl.j(DashoA12275)
at com.sun.net.ssl.internal.ssl.SSLSocketImpl.startHandshake(DashoA12275)
at sun.net.www.protocol.https.HttpsClient.afterConnect(DashoA12275)
at sun.net.www.protocol.https.AbstractDelegateHttpsURLConnection.connect(DashoA12275)
at sun.net.www.protocol.https.HttpsURLConnectionImpl.connect(DashoA12275)
at org.htmlparser.http.ConnectionManager.openConnection(ConnectionManager.java:614)
at org.htmlparser.http.ConnectionManager.openConnection(ConnectionManager.java:792)
at org.htmlparser.Parser.<init>(Parser.java:251)
at org.htmlparser.Parser.<init>(Parser.java:261)
at fbot.FetchDtls.projDtls(FetchDtls.java:30)
at fbot.ProjSrch.invokeSrch(ProjSrch.java:60)
at fbot.ProjSrch$1.run(ProjSrch.java:36)
at java.util.TimerThread.mainLoop(Timer.java:432)
at java.util.TimerThread.run(Timer.java:382)
Caused by: sun.security.validator.ValidatorException: No trusted certificate found
at sun.security.validator.SimpleValidator.buildTrustedChain(SimpleValidator.java:304)
at sun.security.validator.SimpleValidator.engineValidate(SimpleValidator.java:107)
at sun.security.validator.Validator.validate(Validator.java:202)
at com.sun.net.ssl.internal.ssl.X509TrustManagerImpl.checkServerTrusted(DashoA12275)
at com.sun.net.ssl.internal.ssl.JsseX509TrustManager.checkServerTrusted(DashoA12275)
... 18 more
I didn't have problems running the parser on https://sourceforge.net, but I googled your error message and found the following relevant post in the JavaWorld forum:
<http://www.javaworld.com/javaforums/showthreaded.php?Cat=&Board=JavaSecurity&Number=14856&page=0&view=collapsed&sb=5&o=&vc=1>
Derrick.
<pre>
Hi. To solve the trusted certificate problem, you need to add the certificate of the machine that you're authenticating into to Java's "cacerts" trusted certificate keystore using keytool. However, to complicate matters if you're running Windows, there may be two copies of "cacerts" on your machine: one copy in your original Java installation directory, such as <C:\java\jre\lib\security\cacerts>, and one copy in the Java runtime environment's Program Files directory installation, such as <C:\Program Files\Java\j2re1.4.1_03\lib\security>. (I don't know about how to install trusted certificates on another platform.) I've found that Java looks to the "cacerts" in the Program Files installation directory for trusted certificates, but to be safe you should add the certificate to both "cacerts" keystores.
Check out the message thread on <http://www.javaworld.com/javaforums/showflat.php?Cat=2&Board=JavaSecurity&Number=7511&page=0&view=collapsed&sb=5&o=&fpart=1> for more info.
Hope that helps!
Raj
</pre>