views:

256

answers:

3

A client wants to ensure that I cannot read sensitive data from their site, which will still be administered by me. In practice, this means that I'll have database access, but it can't be possible for me to read the contents of certain Model Fields. Is there any way to make the data inaccessible to me, but still decrypted by the server to be browsed by the client?

+4  A: 

No, it's not possible to have data that is both in a form you can't decrypt it, and in a form where you can decrypt it to show it to the client simultaneously. The best you can do is a reversible encryption on the content so at least if your server is compromised their data is safe.

Alex Gaynor
I was afraid of that. I guess I'll just write up a damn good privacy policy...
OwenK
A: 

You and your client could agree on them being obscured. A simple XOR operation or something similar will make the values unreadable in the admin and they can be decoded just in time they are needed in the site.

This way you can safely administer the site without "accidentally" reading something.

Make sure your client understands that it is technically possible for you to get the actual contents but that it would require active effort.

TomA
+1  A: 

Take a look at Django-fields

MMRUser