-
Notifications
You must be signed in to change notification settings - Fork 2k
DLP: Added sample for inspect string with exclusion dict #3200
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
DLP: Added sample for inspect string with exclusion dict #3200
Conversation
Here is the summary of changes. You are about to add 1 region tag.
This comment is generated by snippet-bot.
|
013fdac
to
05e60a2
Compare
dlp/system-test/inspect.test.js
Outdated
`node inspectStringWithExclusionDict.js ${projectId} "Some email addresses: gary@example.com, example@example.com" EMAIL_ADDRESS "gary@example.com"` | ||
); | ||
assert.notMatch(output, /Quote: gary@example.com/); | ||
assert.match(output, /Quote: example@example.com/); |
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.
The documentation surrounding this sample says
Cloud DLP using an InspectConfig that it should avoid matching on "example@example.com" in a scan that uses the infoType detector EMAIL_ADDRESS:
The corresponding Java test has
assertThat(output).contains("gary@example.com");
assertThat(output).doesNotContain("example@example.com");
If you do the opposite here, the reader will be confused.
Hi @dinesh-crest! Do you mind taking a look at the conflicts in |
e3a40f7
to
8900d9b
Compare
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.
LGTM
Added test cases for same
Added test cases for same
68195f7
to
4faab26
Compare
Added test cases for same
Description
Reference:- https://cloud.google.com/dlp/docs/creating-custom-infotypes-rules#omit_specific_email_address_from_email_address_detector_scan
Note: Before submitting a pull request, please open an issue for discussion if you are not associated with Google.
Checklist
npm test
(see Testing)npm run lint
(see Style)