Let's say I have an Access database table that has 2 columns: one is ID (from 1 to 20000, sequentially and each is unique) and one is Value (any number from 0 to 500).
How do I obfuscate the Value field (using ID or not using ID) in a simple but somewhat effective way? I expect something slightly more effective than ROT13 obfuscation but not so complicated that decoing needs more than one line of code. The decoding is done in C# code. The obfuscation is done via calculated field in Access.
I changed the "encryption" to "obfuscation" to reflect the simplicity of the goal which is NOT to prevent "attack" but only to avoid careless exposure of data.
For a number from 0 to 500, encryption is essentially useless.
First, the length is too short to effectively encrypt using normal means such as XOR. Once you know the value of one value, you can likely re-create the key to decrypt others. Encryption works best when you're working with a large original piece of data.
Second, if the data is available to a user in Access, the encryption algorithm will be too, at least to a determined person. If they can see the calculation used to encrypt the value, they can probably create their own decryption algorithm.
Third, with only 501 possible values, the value is highly prone to a dictionary attack -- i.e., someone just guessing each value, and they'll on average only have to guess 250 times. That's fewer than even a simple 3-digit lock on a briefcase. So, encrypting probably won't do you much good.
If you love us? You can donate to us via Paypal or buy me a coffee so we can maintain and grow! Thank you!
Donate Us With