
Answer-first summary for fast verification
Answer: Create an advanced log filter matching userinfo, configure a log export in the Stackdriver console with Cloud Storage as a sink, and then configure a log exclusion with userinfo as a filter.
To address the issue of PII leaking into certain log entries in Stackdriver, the best approach involves capturing these entries in a secure location for review while preventing them from being stored in Stackdriver Logging. Option C is the correct answer because it involves creating an advanced log filter to match entries containing 'userinfo', configuring a log export to Cloud Storage as a sink for secure storage, and then setting up a log exclusion to prevent these entries from being stored in Stackdriver Logging. This approach ensures that PII is both captured for review and prevented from leaking into Stackdriver Logging. Options A and B are incomplete as they do not address the prevention of PII leakage into Stackdriver Logging. Option D is overly complex and not necessary for achieving the goal.
Author: LeetQuiz Editorial Team
Ultimate access to all questions.
No comments yet.
You are running an application on Compute Engine and collecting logs through Cloud Logging. You find that some personally identifiable information (PII) is being exposed in certain log entry fields, with all PII entries starting with the text userinfo. You need to capture these log entries in a secure location for future review while preventing them from being ingested into Cloud Logging. What should you do?
A
Create a basic log filter matching userinfo, and then configure a log export in the Stackdriver console with Cloud Storage as a sink.
B
Use a Fluentd filter plugin with the Stackdriver Agent to remove log entries containing userinfo, and then copy the entries to a Cloud Storage bucket.
C
Create an advanced log filter matching userinfo, configure a log export in the Stackdriver console with Cloud Storage as a sink, and then configure a log exclusion with userinfo as a filter.
D
Use a Fluentd filter plugin with the Stackdriver Agent to remove log entries containing userinfo, create an advanced log filter matching userinfo, and then configure a log export in the Stackdriver console with Cloud Storage as a sink.