Skip to content

Encrypt/decrypt - Ability for multiple keys #32898

Answered by netpok
lcallif asked this question in General
Discussion options

You must be logged in to vote

You can create multiple instance of the encrypter by passing the encryption key:
new Encrypter('key', 'cipher');

But the question is where does the keys are coming, you're app needs them to access the data? Generally when both the database and your app key is stolen than probably your source code is accessible too, so any key generated from the data is trivially accessible too.

Replies: 1 comment 1 reply

Comment options

You must be logged in to vote
1 reply
@lcallif
Comment options

Answer selected by lcallif
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
2 participants