Rails 7 #120 Active Record Encryption usage and troubleshooting

23/03/2023 (about 1 year ago)
SupeRails Encryption usage troubleshooting ruby bonnie in english Active Record Encryption encryption ruby on rails encryption ruby on rails encrypted credentials Encryption usage and troubleshooting rails encryption javascript tutorial active record encryption usage and troubleshooting security how to safely encrypt data encrypt data encryption with source code

Active Record Encryption let's you encrypt data that is stored in the database (it's a very useful layer of security in case your database gets exposed).

In this episode we will add encryption to a few PII and PHI fields. We will encrypt data that is already present in the database, and ensure all new data is safely encrypted.

Episode source code: https://github.com/corsego/120-active-record-encryption/commit/75ece9c396baee3983358cee68733e3b26420d94
Based on this blogpost: https://blog.corsego.com/encrypted-credentials

0:00 ChatGPT is confidently wrong
1:12 What is Active Record Encryption
2:10 Add encryption to a Rails app
5:10 Non-deterministic encryption
5:56 Deterministic encrypyion can be queried
7:55 Encrypt all existing records
8:56 Encrypt an integer?
12:03 Display encrypted values

Sign in to join the conversation