Use regular expressions to define your own custom patterns for detecting sensitive data
for each Data Detect scan policy in addition to the provided sensitive data categories. Some
custom patterns that you can use include organization-specific information such as student IDs,
employee IDs, or contract numbers. Scan results include instances of the custom patterns
detected.
Required Editions
| Available in: Lightning Experience |
| Available in: Enterprise, Performance, Unlimited, and
Developer editions with the Salesforce Shield or Data Detect
Licenses.
|
| User Permissions Needed |
| To create, edit, and view Data Detect policies |
Manage user access to Data Detect feature |
Add up to 10 regular expressions (custom patterns), plus 10 keywords, in any combination.
-
From the Data Detect Policies page, select a policy, select Detection Criteria,
then select Custom Patterns. Select Add
Pattern.
-
Provide a descriptive name for the regular expression, and then enter the regular
expression syntax.
You can optionally test your regular expression to see if it can identify what you
want it to detect in the Validate regular expression section. Ensure your regular
expression pattern or sample phrase is entered correctly for the validation to
work.
-
Enter an example of a phrase or sentence containing the pattern that you want to find, and
selectValidate. Review the validation output to see whether the pattern
is correctly identified and redacted.
-
When you’re done entering your patterns, save your work. You can come back to this section
later to edit or delete a regular expression from the drop-down menu.