0

I have been working on a task assigned by my senior where i need to encrypt my application database but not allowed to do any of the following things:

  1. no use of 3rd party jar files (guardian project or something)
  2. cannot encrypt field-by-field encryption

I just have to encrypt and decrypt my database file through my application but excluding above conditions.

If anybody has done this, please lemme know anything you can tel me. And i would like to tell you as per my senior it is possible to encrypt database, so there is no question whether it is possible or not without using 3rd party jar files or something.

Ankit
  • 1,148
  • 3
  • 15
  • 31
  • I think it isn't possible without the excludes, i once had the same problem: http://stackoverflow.com/questions/6043984/sqlite-encryption-for-android – 2red13 Aug 23 '11 at 10:53

2 Answers2

0

I just have to encrypt and decrypt my database file through my application but excluding above conditions.

This is not possible given your restrictions, unless you rebuild the firmware with an encryption-enabled copy of SQLite (and I do not know if that is possible either).

CommonsWare
  • 986,068
  • 189
  • 2,389
  • 2,491
0

Well you could use the android Cipher class. This link might help you

http://www.helloandroid.com/tutorials/encrypting-your-data

blessanm86
  • 31,439
  • 14
  • 68
  • 79
  • That would entail field-by-field encryption, which the OP indicated was not an option. For ordinary use cases, field-by-field encryption is certainly a viable choice, but not for the OP, apparently. – CommonsWare Aug 23 '11 at 11:07
  • With all his restrictions, that was the only option I could think of. – blessanm86 Aug 23 '11 at 11:10