Session Data Filtering
Basic session data filtering in the AppSignal integrations works with a denylist, a list of keys to filter out and to not send. In the integrations it’s possible to set a “filter session data” option in the AppSignal configuration with a list of session data keys to filter. Any session data values that are filtered out by these systems will be replaced with a[FILTERED] value. This way the list of session data in the app data on AppSignal.com still includes the session data key, but not the value. Making it easier to see that a value was sent, but the potentially sensitive data was filtered out.
Example
For example, an application with this AppSignal config:Ruby
In the Ruby integration, AppSignal automatically stores the contents of the user’s session for Rails apps and other frameworks. Specific values can be filtered out or it can be disabled entirely. In session data filtering, there’s support for nested hashes and nested hashes in arrays. Any hash we encounter in your session data will be filtered. To use this filtering, add the following to yourconfig/appsignal.yml file in the environment group you want it to apply. The filter_session_data value is an Array of Strings.
Elixir
In the Elixir integration, AppSignal automatically stores the contents of the user’s session for Phoenix apps. Specific values can be filtered out or it can be disabled entirely. In the session data filtering, there’s support for nested hashes and nested hashes in arrays. Any hash we encounter in your session data will be filtered. To use this filtering, add the following to yourconfig/appsignal.exs file. The filter_session_data value is an Array of Strings.
Node.js
If a request stores session data on the sample, use the session data filter to filter out any data you do not want to include. In the session data filtering, there’s support for nested hashes and nested hashes in arrays. Any hash we encounter in your session data will be filtered. To use this filtering, use thefilterSessionData config option to select which session data keys to filter out.
Python
If a request stores session data on the sample, use the session data filter to filter out any data you do not want to include. In the session data filtering, there’s support for nested hashes and nested dictionaries in lists. Any dictionary we encounter in your session data will be filtered. To use this filtering, use thefilter_session_data config option to select which session data keys to filter out.
Go
If a request stores session data on the sample, use the session data filter to filter out any data you do not want to include. In the session data filtering, there’s support for nested slices and nested maps. Any map we encounter in your session data will be filtered. Use thefilter_request_session_data denylist for request session data filtering. Set the send_request_session_data option to false to not send any request session data at all.
See the Go configuration page for more information on how to configure OpenTelemetry for Go apps.
Java
If a request stores session data on the sample, use the session data filter to filter out any data you do not want to include. In the session data filtering, there’s support for nested maps and arrays. Any map encountered in your session data will be filtered. Use thefilter_request_session_data denylist for session data filtering. Set the send_request_session_data option to false to avoid sending any session data.
See the Java configuration page for more information on how to configure OpenTelemetry for Java apps.
PHP
If a request stores session data on the sample, use the session data filter to filter out any data you do not want to include. In the session data filtering, there’s support for nested arrays. Any array encountered in your session data will be filtered. Use thefilter_request_session_data denylist for session data filtering. Set the send_request_session_data option to false to avoid sending any session data.