<div dir="ltr">Hi<br><br>In attempting to validate jar signing I am seeing warnings as such displaying Invalid certificate chain<br><br>-----------------------<br>>jarsigner -verify -certs bcprov-jdk15on-1.66.jar<br><br>s     606774 Sat Jul 04 15:48:42 EDT 2020 META-INF/MANIFEST.MF<br><br>      >>> Signer<br>      X.509, CN=Legion of the Bouncy Castle Inc., OU=Java Software Code Signing, O=Sun Microsystems Inc<br>      [certificate expired on 4/25/20 3:00 AM]<br>      X.509, CN=JCE Code Signing CA, OU=Java Software Code Signing, O=Sun Microsystems Inc, L=Palo Alto, ST=CA, C=US<br>      [certificate expired on 4/25/20 3:00 AM]<br>      [Invalid certificate chain: PKIX path building failed: sun.security.provider.certpath.SunCertPathBuilderException: unable to find valid certification path to requested target]<br><br>      >>> Signer<br>      X.509, CN=Legion of the Bouncy Castle Inc., OU=Java Software Code Signing, O=Oracle Corporation<br>      [certificate is valid from 3/10/17 8:07 PM to 3/10/22 8:07 PM]<br>      X.509, CN=JCE Code Signing CA, OU=Java Software Code Signing, O=Oracle Corporation<br>      [certificate is valid from 7/6/16 7:48 PM to 12/30/30 7:00 PM]<br>      [Invalid certificate chain: PKIX path building failed: sun.security.provider.certpath.SunCertPathBuilderException: unable to find valid certification path to requested target]<br><br>-----------------------<br>jarsigner -keystore ...\jre\lib\security\cacerts -verify -verbose -certs bcprov-jdk15on-1.66.jar >out.txt<br><br><br>s     606774 Sat Jul 04 15:48:42 EDT 2020 META-INF/MANIFEST.MF<br><br>      X.509, CN=Legion of the Bouncy Castle Inc., OU=Java Software Code Signing, O=Sun Microsystems Inc<br>      [certificate expired on 4/25/20 3:00 AM]<br>      X.509, CN=JCE Code Signing CA, OU=Java Software Code Signing, O=Sun Microsystems Inc, L=Palo Alto, ST=CA, C=US<br>      [certificate expired on 4/25/20 3:00 AM]<br>      [CertPath not validated: Path does not chain with any of the trust anchors]<br><br>      [entry was signed on 7/4/20 1:48 AM]<br>      X.509, CN=Legion of the Bouncy Castle Inc., OU=Java Software Code Signing, O=Oracle Corporation<br>      [certificate is valid from 3/10/17 8:07 PM to 3/10/22 8:07 PM]<br>      X.509, CN=JCE Code Signing CA, OU=Java Software Code Signing, O=Oracle Corporation<br>      [certificate is valid from 7/6/16 7:48 PM to 12/30/30 7:00 PM]<br>      [CertPath not validated: Path does not chain with any of the trust anchors]<br>     <br>-----------------------<br><br><br><br>Why do we get warnings of  "Invalid certificate chain"?<br><br>(I do not believe it's related to the expired warning as I see newer jars exhibiting the same outcome without an expired notice)<br><br>Is the jar incorrectly signed or is the required chain simply not found in cacerts and if so why is it not there. I do see that at the end of the listing it says "jar verified"<br><br>The samples in<br><a href="https://docs.oracle.com/en/java/javase/15/docs/specs/man/jarsigner.html#errors-and-warnings">https://docs.oracle.com/en/java/javase/15/docs/specs/man/jarsigner.html#errors-and-warnings</a><br>seem to show a fully validated chain.<br> <br>thanks<br>Raj</div>