I have a webapp deployed wich uses a jks loaded from a database.
They work perfect on the server but when I run this app on my pc I get an error "Invalid keystore format" at this code:
public static KeyStore loadKeystore(InputStream is, String password,String type)
throws NoSuchAlgorithmException, CertificateException, IOException,
KeyStoreException {
KeyStore ks = KeyStore.getInstance(type);
ks.load(is, password.toCharArray()); //<--error thrown here
return ks;
}
Both server and I had JAVA 1.6, I installed JAVA 8 on my pc but later returned to 1.6 (changed w7 enviromentals). Could this have something to do? No code was changed.
Im running the webapp from eclipse with this in .ini: C:/Program Files (x86)/Java/jdk1.6.0_45/bin
Any idea on what I can try to detect the issue or get it working again?
Thanks
/how do i read/write/ --Insert
INSERT INTO te_keystores (fields, keystore) VALUES
(fields,
decode('/u3+7QAAAAIAAAABAAAAAQA...etc','base64'));
--Read with a select field using hibernate
<property name="keystore" type="org.springframework.orm.hibernate3.support.BlobByteArrayType"
lazy="true">
<column name="KEYSTORE" />
</property>