Issue
Data is being scrubbed and I do not know why. I want to identify the exact rule that is scrubbing a field so I can fine-tune my scrubbing rules without disabling data scrubbing entirely. There are no modifications to the event on the client, yet in Sentry some fields are shown as [Filtered].
Applies To
All SaaS Customers and Self-Hosted Users
Data Scrubbing / PII
Symptoms
Fields are being scrubbed even though they do not contain PII.
Resolution
Sentry scrubs events server-side by default, based on key names and values. When it detects a key or value that is commonly sensitive or may contain PII, it replaces the value with [Filtered]. Only a set list of fields is scanned.
To find the exact rule that scrubbed a field:
Open the event, then open its raw JSON (the JSON view in the event header).
Find the
_metaobject. It lists each scrubbed field along with the rule that scrubbed it.
The rule identifies why the field was scrubbed:
@password: matched Sentry's default auth/password scrubbing.@creditcard: the value matched the credit card regular expression.strip-fields: the field matched an entry you added to Global Sensitive Fields (organization level) or Additional Sensitive Fields (project level), either as a full or partial match.
To get finer control without disabling data scrubbing, add the field you want to keep to Safe Fields, in Settings > Security & Privacy (organization) or Settings > Projects > [project] > Security & Privacy (project). Safe Fields exempt specific fields from scrubbing. You can also adjust your Additional Sensitive Fields or Global Sensitive Fields entries if a custom rule is scrubbing too broadly.
Note that organization-wide data scrubbing settings override project-level settings, so if a rule is defined at the organization level, change it there rather than in the project.
For details, see the server-side data scrubbing documentation and the Safe Fields section.
