Encrypt and Decrypt Data Securely in PHP: OpenSSL, Sodium & defuse/php-encryption

preview_player
Показать описание
Learn how to encrypt and decrypt data in PHP.

Topics covered:
• Symmetrical encryption and decryption with a private key in PHP
• Using OpenSSL
• Using Sodium (libsodium)
• Using a third-party encryption package

All source code shown is free to download:

Links shown in the video:

Videos:

Image used in thumbnail:

00:00 Introduction
00:23 OpenSSL
05:06 Sodium
07:52 php-encryption
10:20 Summary

#PHP #encryption #laravel
Рекомендации по теме
Комментарии
Автор

That's nice. Thank you.
One of the next steps in my PHP learning project is to encrypt data on a database for user information, such as e-mail addresses.

longrolstral
Автор

TY Dave! yr vids r ALWAYS appreciated!!

efbYouTube
Автор

What about a course about security in php and db? Some senior devs asked me all these stuff while interviewing me

DukeBerserkerTheFury
Автор

Regarding OpenSSL, I want to input this to a MySQL database. My one question is in regards to your comment at 3 minutes, I tried setting as a BINARY type in MySQL, but it added lots of zeros to the end of the IV and this presented a warning when doing a var_dump on the returned value from the database. I can't find anything obvioua online as to why this is. Could you assist with this small point please? I very much like your clear explanation, short and to the point videos.

graham
Автор

Thx! Can you show how to encrypt and decrypt using PGP keys? The goal would be to send encrypted /signed emails automatically. Would love to see a tutorial how to retrieve the recipients key and use it for it.

ruamtauzla
Автор

Where should we use this thing in real life practical application?? For session?

devhenry
Автор

Great video on encryption. When encrypting data using PHP, do you know if the encrypted data be decrypted using other languages? Say in JS, C#, C++ etc? Thanks

chriswinslow
Автор

Hi Dave, still waiting for yr full course in CI4 Shield. Its now 1.2.

truthteachers
Автор

For those who are new to encryption, please not that encryption alone is not enough, typically. You also need to authenticate which guarantees that when decrypt the ciphered text, you get the original text "Hello world!" not some gibberish text. Ckeck out these 2 sodium functions for example:


crazyingenieur
Автор

is this things defalutly implemented in frameworks like laravel?

kuthub
Автор

Hi Dave! Can you please share your email? I have a collaboration opportunity I would like to share. By the way, thank you for your amazing content!

IrynaRomaniv-egqv