I am unable to open my existing keystore file in Android Studio or use the jarsigner
from the command line.
In both cases the error message is:
java.security.cert.CertificateException: Unable to initialize, java.io.IOException: DerInputStream.getLength(): Redundant length bytes found
Apparently this was an issue that should be fixed with JDK8_131 but does not work for me. (We are all using OSX)
I also get the same error on travis. (See "Update" section below.)
I found another SO question (Signing android app throws IOException: Redundant length bytes found) where they converted the .pkc12
file to .keystore
but we are already using .keystore
UPDATE
I found that the build also started failing on travis because they are moving builds to their new distro trusty
which downloads the newest JDK whereas precise
used JDK7 by default. Adding dist: precise
to the top of the .travis.yml
file works for now but this is definitely not a permanent solution.
Can we only hope for a JDK update that fixes the issue or is there a way to remove the redundant length bytes from the keystore?