Closed ebpmp closed 10 years ago
If you model a VARCHAR(255) and the encrypted data is longer than 255, then the data will be truncated. We learned this the hard way. It is the non-default option, so for Eventbrite compatibility, I would like to leave it in there and document the rationale why it is needed for others. Thanks for pulling and making those tweaks! We are working on integrating this into our system replacing our models with django-encrypted-fields. If any issues come up, I will let you know.
Django won't create the fields as VARCHAR
, but I suppose if you have legacy fields it's a valid consideration.
Yeah, existing applications will almost certainly have some fixed length character fields that may need encryption. I think it's a good idea to leave it in. I am going to update the README.md file too with descriptions on the new options.
I'm not sure that the
enforce_max_length
option is needed. All the fields are treated like aTextField
from Django's perspective. This should effectively disable themax_length
argument.Thoughts?