-
Notifications
You must be signed in to change notification settings - Fork 632
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
SSL Certificate not being found. #2009
Comments
I can confirm this behaviour. The site itself can be navigated, but images are hosted on a CDN and the CDN uses a different CA (GoGetSSL) which isn't supported by default in OpenJDK (at least up to version 18, which is what I'm using). Example of a URL that fails: https://cdn5-images.motherlessmedia.com/images/F78038F.jpg Below is the CA certificate that needs to be supported. AIUI, the best way of doing this is distributing a keystore along with the application that contains all of the appropriate CA certificates. If anyone wants, I can build a system based on the default OpenJDK keystore with this one added and add code to the application to load it during startup. Does that sound useful? -----BEGIN CERTIFICATE----- |
I'd like a fix if you have one. I tried using your updated code. I couldn't seem to make it work, possibly my error. I pulled your files, and used maven to build it, then i launched the "ripme-1.7.95-jar-with-dependencies.jar" and it kept erroring saying it could not find the video. I tried on galleries and images and videos and none of them worked and they all said they couldn't find the video. Anyways, I'd be happy to help test anything else. |
Any Update on this? |
The issue can be solved without touching the source code. First some background: The actual problem is, that the content servers only send the server certificate. The trust store on the other hand only knows about the root CA certificate. The certificate of the intermediate CA is missing and hence, trust can't be established, because the middle part of the chain is missing. To make a long story short: How to fix it?
With Keystore Explorer you can execute the steps GUI based: Hope that helps! |
Not us , the user must add this certifacte to his installed JVM cacerts in his machine wich most of end users are not familiar with or don't know how really it works to begin with . the best solution to this probleme is changing the releasing strategy from a jar release to a binary file with a well configured embeded JRE for this type of issues |
Yes, with 'you' I meant the users; not developers. I have updated my post. |
openjdk version "11.0.17" 2022-10-18
OpenJDK Runtime Environment (build 11.0.17+8-post-Ubuntu-1ubuntu222.04)
OpenJDK 64-Bit Server VM (build 11.0.17+8-post-Ubuntu-1ubuntu222.04, mixed mode, sharing)
Linux Kubuntu - 4 versions. Raspberry Pis, and Vms.
Expected Behavior
For it to pull actual files and download them
Actual Behavior
It's getting SSL certificate failures. I can navigate the site just fine on a web browser, but unfortunately, something happened where it won't work to download from with Ripme. I should clarify that some stuff downloads, but a folder with 6000 items, 5500 errored with that error and the others downloaded. I have no idea any solution.
avax.net.ssl.SSLHandshakeException: PKIX path building failed: sun.security.provider.certpath.SunCertPathBuilderException: unable to find valid certification path to requested target
at java.base/sun.security.ssl.Alert.createSSLException(Alert.java:131)
at java.base/sun.security.ssl.TransportContext.fatal(TransportContext.java:353)
at java.base/sun.security.ssl.TransportContext.fatal(TransportContext.java:296)
at java.base/sun.security.ssl.TransportContext.fatal(TransportContext.java:291)
at java.base/sun.security.ssl.CertificateMessage$T13CertificateConsumer.checkServerCerts(CertificateMessage.java:1357)
at java.base/sun.security.ssl.CertificateMessage$T13CertificateConsumer.onConsumeCertificate(CertificateMessage.java:1232)
at java.base/sun.security.ssl.CertificateMessage$T13CertificateConsumer.consume(CertificateMessage.java:1175)
at java.base/sun.security.ssl.SSLHandshake.consume(SSLHandshake.java:392)
at java.base/sun.security.ssl.HandshakeContext.dispatch(HandshakeContext.java:443)
at java.base/sun.security.ssl.HandshakeContext.dispatch(HandshakeContext.java:421)
at java.base/sun.security.ssl.TransportContext.dispatch(TransportContext.java:183)
at java.base/sun.security.ssl.SSLTransport.decode(SSLTransport.java:172)
at java.base/sun.security.ssl.SSLSocketImpl.decode(SSLSocketImpl.java:1506)
at java.base/sun.security.ssl.SSLSocketImpl.readHandshakeRecord(SSLSocketImpl.java:1416)
at java.base/sun.security.ssl.SSLSocketImpl.startHandshake(SSLSocketImpl.java:456)
at java.base/sun.security.ssl.SSLSocketImpl.startHandshake(SSLSocketImpl.java:427)
at java.base/sun.net.www.protocol.https.HttpsClient.afterConnect(HttpsClient.java:572)
at java.base/sun.net.www.protocol.https.AbstractDelegateHttpsURLConnection.connect(AbstractDelegateHttpsURLConnection.java:201)
at java.base/sun.net.www.protocol.https.HttpsURLConnectionImpl.connect(HttpsURLConnectionImpl.java:168)
at com.rarchives.ripme.ripper.DownloadFileThread.run(DownloadFileThread.java:136)
at java.base/java.util.concurrent.ThreadPoolExecutor.runWorker(ThreadPoolExecutor.java:1128)
at java.base/java.util.concurrent.ThreadPoolExecutor$Worker.run(ThreadPoolExecutor.java:628)
at java.base/java.lang.Thread.run(Thread.java:829)
Caused by: sun.security.validator.ValidatorException: PKIX path building failed: sun.security.provider.certpath.SunCertPathBuilderException: unable to find valid certification path to requested target
at java.base/sun.security.validator.PKIXValidator.doBuild(PKIXValidator.java:439)
at java.base/sun.security.validator.PKIXValidator.engineValidate(PKIXValidator.java:306)
at java.base/sun.security.validator.Validator.validate(Validator.java:264)
at java.base/sun.security.ssl.X509TrustManagerImpl.validate(X509TrustManagerImpl.java:313)
at java.base/sun.security.ssl.X509TrustManagerImpl.checkTrusted(X509TrustManagerImpl.java:222)
at java.base/sun.security.ssl.X509TrustManagerImpl.checkServerTrusted(X509TrustManagerImpl.java:129)
at java.base/sun.security.ssl.CertificateMessage$T13CertificateConsumer.checkServerCerts(CertificateMessage.java:1341)
... 18 more
Caused by: sun.security.provider.certpath.SunCertPathBuilderException: unable to find valid certification path to requested target
at java.base/sun.security.provider.certpath.SunCertPathBuilder.build(SunCertPathBuilder.java:141)
at java.base/sun.security.provider.certpath.SunCertPathBuilder.engineBuild(SunCertPathBuilder.java:126)
at java.base/java.security.cert.CertPathBuilder.build(CertPathBuilder.java:297)
at java.base/sun.security.validator.PKIXValidator.doBuild(PKIXValidator.java:434)
... 24 more
Getting key exception.while.downloading.file in en_US value Exception while downloading file
The text was updated successfully, but these errors were encountered: