Sensitive-Field Identification
Identify event fields that may contain credentials, personal information, authentication data, or other protected information.
Determine which event attributes require protection.
Sentry is an application monitoring and error-tracking platform that collects application error events and associated diagnostic information. Error events can contain exception messages, stack traces, request information, user attributes, tags, and additional application context.
Error-monitoring data can become a data-protection concern when sensitive information is unintentionally included in an event. Application failures may expose credentials, authentication tokens, API keys, session identifiers, personal information, internal URLs, request parameters, or other confidential values through error messages or contextual event data.
In this use case, a controlled Sentry environment is deployed on an Ubuntu virtual machine. A controlled test application generates synthetic error events containing ordinary diagnostic information as well as deliberately inserted test secrets and sensitive values.
A controlled sensitive-error disclosure scenario is created by generating an application error containing synthetic credentials, tokens, authorization values, and sensitive fields. The assessment does not use real credentials, personal information, or production application data. Instead, it demonstrates how sensitive values in error-event data can be identified and removed before they remain available in the Sentry event store.
Sentry provides project- and organization-level data-scrubbing controls that can remove known sensitive values, apply built-in sensitive-field rules, define additional sensitive fields, exempt safe fields, scrub IP addresses, and apply advanced Relay PII configurations before events are stored.
The proposed data-protection mechanism combines error-event inspection, sensitive-field identification, event filtering, secret detection, server-side data scrubbing, custom sensitive-field rules, redaction, event validation, and protected-event storage.
The objective is to prevent sensitive information from being retained in Sentry error events while preserving sufficient diagnostic information for legitimate application troubleshooting.
After implementing the protection workflow, the controlled sensitive-error scenario is repeated to verify that sensitive values are filtered or redacted, non-sensitive diagnostic information remains available, and the protected event does not retain prohibited secret values.
Complete Data Protection Workflow: Sensitive-Event Generation → Event Collection → Sensitive-Field Identification → Secret Detection → Event Filtering → Server-Side Scrubbing → Secret Redaction → Protected Event Storage → Event Validation → Data-Protection Verification.
Sentry collects application events for error tracking and investigation. An event can contain diagnostic information associated with an application failure, including event metadata and error details. Sentry also provides APIs for retrieving event information and event bodies, demonstrating that collected event data can subsequently be accessed for investigation. If an application unintentionally includes secrets or sensitive information in an error event, that information may become part of the monitoring data and may subsequently be visible to authorized Sentry users or accessible through event-management workflows.
Traditional application-error monitoring focuses primarily on detecting and investigating failures. If sensitive values are included in a diagnostic event, the monitoring platform can unintentionally become another location where protected information is retained.
The security problem is therefore:
The proposed solution inspects incoming event data, identifies sensitive fields and secret patterns, applies server-side filtering and redaction controls, stores only the protected event representation, and validates that prohibited sensitive values are no longer retained while useful diagnostic information remains available.
The attack scenario represents accidental or deliberate inclusion of sensitive information inside an application error event that is subsequently collected by Sentry. An application may place credentials, API tokens, authorization headers, session identifiers, email addresses, internal URLs, or other sensitive values inside an exception message, request context, tags, breadcrumbs, or additional event data. An attacker who gains access to the affected monitoring data, or an unauthorized recipient of the event information, could potentially obtain sensitive values if the event is stored without adequate filtering or redaction. The controlled scenario uses synthetic secrets and synthetic sensitive values to demonstrate the exposure condition without using real credentials or personal information.
Event-data filtering examines application telemetry before sensitive information is retained by the monitoring platform. The filtering process identifies event fields and values that should not be stored according to the defined data-protection policy.
Secret redaction replaces or removes sensitive values while preserving the surrounding diagnostic information required for troubleshooting. Sentry supports server-side data scrubbing, built-in sensitive-field scrubbing, custom sensitive fields, safe-field configuration, IP-address scrubbing, and advanced data-scrubbing rules through Relay configuration. The protection model separates diagnostic information from sensitive information, allowing useful error details to remain available while prohibited values are removed before protected event storage.
The secure processing flow is:
Identify event fields that may contain credentials, personal information, authentication data, or other protected information.
Determine which event attributes require protection.
Inspect event content for controlled patterns representing API keys, tokens, passwords, authorization values, and other secret-like data.
Identify sensitive values embedded within event content.
Filter events or event fields that violate the defined data-protection policy before sensitive information is retained.
Prevent prohibited event data from entering protected monitoring storage.
Enable server-side scrubbing to remove sensitive values from incoming event data before storage. Sentry provides project-level and organization-level data-scrubbing controls for this purpose.
Provide a centralized protection layer for collected event data.
Enable built-in sensitive-field rules where appropriate to identify common types of sensitive information.
Provide baseline protection against common sensitive-value disclosure.
Configure additional sensitive field names relevant to the controlled application.
Extend protection to application-specific sensitive attributes.
Mask or remove detected secret values according to the defined protection policy.
Prevent the original secret value from remaining in the protected event.
Apply IP-address scrubbing where IP information is classified as protected data within the laboratory policy. Sentry provides organization-level and project-level IP scrubbing controls.
Reduce unnecessary retention of network identifiers.
Review stored events after filtering and scrubbing to verify that prohibited sensitive values have been removed.
Confirm that the data-protection control operates as intended.
Preserve non-sensitive error information after redaction.
Maintain useful troubleshooting information without retaining prohibited sensitive values.
Sentry provides the controlled error-event collection and monitoring environment. It supports project- and organization-level data-scrubbing controls, custom sensitive fields, safe fields, IP scrubbing, and advanced data-scrubbing rules.
A controlled Python Flask application is used to generate synthetic application errors containing normal diagnostic information and laboratory-only sensitive values.
cURL is used to generate controlled HTTP requests that trigger predefined application errors.
Python is used to generate synthetic sensitive values and automate event-validation workflows.
Python Requests is used to automate controlled HTTP requests to the laboratory application and Sentry APIs where required.
The Sentry API is used in the controlled environment to inspect or configure project-level filtering and data-scrubbing settings where the required API permissions are available. Sentry documents project data-filter APIs and project configuration fields for data scrubbing and sensitive fields.
OpenSSL is used to validate TLS communication between the controlled application, testing system, and Sentry service.
Wireshark is used within the controlled environment to observe authorized application and Sentry communication during the testing workflow.
Ubuntu provides the controlled server environment hosting Sentry and the laboratory application.
Kali Linux provides the controlled security-testing environment used to generate and validate sensitive-event disclosure scenarios.
VirtualBox provides the isolated laboratory environment for the Ubuntu and Kali Linux virtual machines.