Decrypt sensitive data from the user profile
What does it do?
This rule will get a sensitive value in the app_metadata and decrypt it (see the Encrypt sensitive data in the user profile rule for information on how to encrypt the data).
Note, for this to work you'll need to set 2 configuration settings:
ENCRYPT_PASSWORD, eg: S0me,Password!è§
ENCRYPT_IV, eg: abcjfiekdpaifjfd
And here's an example of how you would decrypt this in .NET:
How do I use it?
Just create a new rule in the Auth0 dashboard, and copy the following code replacing the placeholders with the appropriate values.
What is Rule-Based Authentication?
Rules can be used to enrich and transform the user profile, deny access to specific users under certain conditions, retrieve information from external services and much more. For more information about rules, please check the documentation