Skip to content

Add a configurable way to mask sensitive information #220

@joe94

Description

@joe94

One of our community members reported in xmidt-org/xmidt#51 that it would be nice having a way to mask sensitive information such as device IDs (information that could be traced back to an individual customer) from log entries.

Some of the log field names that include sensitive data across our microservices are:
requestURL
requestURI
requestHeaders.Referer
instance

Suggested Approach
Compile a global regex to match device IDs from within a string and replace all characters with a * except the prefix. Ex: mac:1122334455 would become mac:**********

Configuration:

log:
  ...
  # defaults to false meaning sensitive data is masked by default
  disableSensitiveDataMasking: false

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Type

    No type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions