I am using a SqlLite database, and I would like to ensure that the data has not been modified outside the application. (sign the data)
Does sqlite keep a last modified date of the data?
I was thinking about using the Windows last modified file date, but that is my second choice. I was hoping sqlite would have a way to tell me either a hash of the data or a timestamp of the last data modified.
One option is to calculate a hash of all the contents of the bytes of the database file, this would allow me to guarantee that the file hasn't been modified by anyone. But this is expensive and I am hoping to find a better way to verify no external sources modified the database.
Another option is to encrypt the database, but this is not ideal because we want 3rd parties to be able to read the data, just not to modify it.
Note that I am accessing the database using System.Data.Sqlite in a WPF .net client application on Windows 7.