-
-
Notifications
You must be signed in to change notification settings - Fork 1.1k
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Allow CryptTrait to accept a \Defuse\Crypto\Key as encryption key #812 #814
Conversation
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Looks good to me. The only thing I spotted was that we should update the docblocks for the setEncryptionKey functions in GrantTypeInterface
and ResponseTypeInterface
. I think once this change is made this will be good to merge in unless anyone has any objections. Thanks for creating the PR
@Sephster Ah yes, sorry, forgot about those interfaces. Phpdoc updated for the interfaces too. |
I also updated the PR to remove some code duplication in the |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Looks fine to me.
Is it possible for the if
statements in CrypTrait to be factored out by following the example set in the tests? I.e by using setEncryptionKey
And doEncrypt/doDecrypt
methods instead of encrypt/decrypt/WithPassword
.
@simonhamp So I'm not really sure how to get rid of the Note that in the tests |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
That’s fine. Nice clean PR good to go from my POV
@Sephster Is the PR ok for you too? I updated the change you requested. |
Sorry for the delay in getting this reviewed @SunMar. I've made some minor changes but all looks good so merging in. Thanks for your patience and your contribution |
…n, when combined with oauth2-server package patch from thephpleague/oauth2-server#814
…n, when combined with oauth2-server package patch from thephpleague/oauth2-server#814
…n, when combined with oauth2-server package patch from thephpleague/oauth2-server#814
…n, when combined with oauth2-server package patch from thephpleague/oauth2-server#814
…ption/decryption, when combined with oauth2-server package patch from thephpleague/oauth2-server#814
…ption/decryption, when combined with oauth2-server package patch from thephpleague/oauth2-server#814
…ption/decryption, when combined with oauth2-server package patch from thephpleague/oauth2-server#814
…ption/decryption, when combined with oauth2-server package patch from thephpleague/oauth2-server#814
…ption/decryption, when combined with oauth2-server package patch from thephpleague/oauth2-server#814
…ption/decryption, when combined with oauth2-server package patch from thephpleague/oauth2-server#814
…password to Key object encryption key (amending thephpleague#814)
…password to Key object encryption key (amending thephpleague#814)
…password to Key object encryption key (amending thephpleague#814)
See #812 for details. This allows a Key object to be used as encryption key over an alphanumeric string which improves performance of encryption and decryption.