-
-
Notifications
You must be signed in to change notification settings - Fork 595
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
Encrypted Current User in browser #1036
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.
This looks good to me. I have a few comments.
I just realized if you remove the check for browser, this would still work for node and react-native no? |
At Node I believe there's no problem just let me check react-native compatibility. |
I think it should work sad that package uses vanilla js. Also you have conflict. I’ll pull this down and use this in production. |
Ok, thanks |
Let me try with this package Forge. |
Codecov Report
@@ Coverage Diff @@
## master #1036 +/- ##
==========================================
+ Coverage 92.11% 92.19% +0.07%
==========================================
Files 53 54 +1
Lines 5114 5152 +38
Branches 1142 1145 +3
==========================================
+ Hits 4711 4750 +39
+ Misses 403 402 -1
Continue to review full report at Codecov.
|
@macarthuror I made a few changes to this PR. There is a CryptoController that allows users to add their own implementation. I also updated the tests. @davimacedo Anything you want to add? |
@dplewis Looks amazing 👌 |
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.
nice
UPDATE 17/12/19
Problem
Sometimes we don't want or we don't need to show the information of the current user in the local storage
Solution
With this implementation the information of the current user will be encrypted in the Local Storage to prevent expose the data.
Made it with the crypto-js package.
To implement it you only need to use the next code
#967