Python: encryption as means to prevent data tampering -
Many of my company's customers use our data acquisition software on a research basis. In general, due to the nature of research, some customers ask that data is encrypted to avoid tampering - if their data has been proved incorrect, then there may be serious impact.
Encrypts output files with a password stored in some of our binary software sources, which looks like random characters. At the software level, we are able to open encrypted files only for read-only. If someone wanted to know the password actually so that they could change the data, it would be possible, but this would be a lot of work
I got another piece of software for faster development I'm looking at using Python. To duplicate the functionality of encryption to lose / disappoint the data tampering, the best thing I have ever done with it, is to just write ctypes
to read / write files to DLL , So that the method is "sufficient" obfuscated for encryption and decryption.
We are well aware that an "irreversible" method is unattainable, but simultaneously I am not comfortable with the encryption / decryption approach sitting in the python in plain text in the source code of a "data tampering Very strong disappointment "would be good enough, I think.
What is the best way to obtain other evidence of data integrity using a happy medium of encryption or using Python? / Strong> I talked about the creation of "proof of compromise", but if a signature was created in pure Python then it would be trivial to generate signatures for any arbitrary data. We may be able to call at home to prove the data integrity may be , but it seems that there is a major disadvantage for everyone involved.
As a general principle, you do not want to use encryption to protect against tampering, Instead you want to use digital signatures. Encryption gives you privacy , but you are behind integrity .
Calculate a hash value on your data and store the value at the place where you know it can not be tampered with or it can not be digitally signed.
It seems that you want to ensure that only files in your software can be generated? As you say, after your users have access to the software, they can not really exist in a safe way because they can isolate it and tear it apart and get any secret key you have included You can. Given that the obstacle, I think your idea of using a DLL is as good as you can.
Comments
Post a Comment