Thanks George, but I already tried something similar to this. In this instance I get the following error Caused by: java.sql.SQLException: Encryption algorithm 'DESede/CBC/NoPadding' does not exist But it will work if using Java1.4
I think the problem is because j9 does not include the classes to decrypt the database. J9 does have it's own enryption provider (com.ibm.j9.jce.provider.J9JCEProvider) but I'm not sure how to use it. I tried various things to try and create the database specifying this provider by to no avail. George H wrote: > > Hi, > > I have no idea about J9 but I have created encrypted derby databases and I > think your missing some parameters. > > dataEncryption=true; > bootPassword="blabla"; > encryptionProvider=com.sun.crypto.provider.SunJCE; > encryptionAlgorithm=DESede/CBC/NoPadding; > > The above will get you a somewhat decent encrypted DB.. if you consider > DES > as decent. You'd need to change the privider and algorithm to apply a > strong > crypt. > > Hope this helps. > -- > George H > [email protected] > > > On Fri, Jun 19, 2009 at 11:53 AM, Cuong <[email protected]> wrote: > >> >> Hi, >> So far I have an unencrypted embedded database which I can use within an >> OSGi bundle running inside the Knopflerfish framework. >> This database was created using the ij tool (using Java 1.4) >> CONNECT 'jdbc:derby:MYDB;create=true; >> >> This all works fine with even when I'm running with J9 (with JSR169.jar). >> >> Now I need to encrypt this database, therefore I had to change by >> database >> creation script >> CONNECT 'jdbc:derby:MYDB;create=true; >> dataEncryption=true; >> bootPassword=we1come;' >> >> The database will be created successfully, but when I try to 'open' the >> database (setting the appropriate parameters) I get the following errors >> >> java.sql.SQLException: Encryption algorithm 'DES/CBC/NoPadding' does not >> exist. Please check that the chosen provider 'default' supports this >> algorithm. >> Using Java 1.4 it will all be fine. >> >> Has anyone successfully created and opened an encrypted database using >> j9? >> There doesn't seem to be a definitive guide on how to do this. >> >> Thanks in advance. >> -- >> View this message in context: >> http://www.nabble.com/J9-%2B-Encrypted-Embedded-Database-tp24107762p24107762.html >> Sent from the Apache Derby Users mailing list archive at Nabble.com. >> >> > > -- View this message in context: http://www.nabble.com/J9-%2B-Encrypted-Embedded-Database-tp24107762p24108092.html Sent from the Apache Derby Users mailing list archive at Nabble.com.
