Can I hash/encrypt or otherwise protect emails in my Django app from hackers?
Asked Answered
F

1

5

Hoping for a simple function I can use to store emails securely and retrieve easily when required to send emails.

Faubion answered 17/12, 2013 at 23:52 Comment(0)
M
7

Kind of a general question, but here are a few solutions I'm familiar with:

  • use django-encrypted-fields, which has an EncryptedEmailField
  • you can override the save method for encrypting the email yourself, then override the post_init signal for decryption. See example here (which is based on this)
  • you can build your own encrypted email field, see django snippet here (uses pyCrypto)
  • you can use django-extension's EncryptedCharField
  • If none of the above seems good enough, try google-ing around by yourself. You're probably not the first to tackle this problem

good luck.

Moersch answered 18/12, 2013 at 0:17 Comment(1)
I'm sure I can get one of those to work. Thanks for the quick summary of options.Faubion

© 2022 - 2024 — McMap. All rights reserved.