Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Add "redactors" API to enable easy redacting of (possibly sensitive) data #13

Open
wants to merge 7 commits into
base: main
Choose a base branch
from

Conversation

Zsailer
Copy link
Member

@Zsailer Zsailer commented Aug 16, 2022

Building on #12, this adds a set of helpful "modifiers" that are specifically designed to redact data from events. These objects are configurable and easy to extend.

An immediate use-case for these redactors is to redact sensitive data. As Jupyter applications begin to emit events, it's critical that we provide easy configuration to handle sensitive data under different deployment requirements. This API becomes the foundation for these applications or deployers to easily redact sensitive data in ways that suit their requirements.

The API is quite simple. To redact events, either configure or extend one of the provided Redactor classes. Redactors can act on whole schemas, individual properties within schemas, or all properties that match a certain (regex) pattern. They can be appended to the EventLogger through the .add_modifier API and chained with other modifiers to mutate events.

Over time, we can offer different types of Redactors as the need arises. In this PR, I've provided a MaskRedactor (just replaced redacted values with a configurable string) and a RemovalRedactor (deletes key/values from a schema).

Todo:

  • Handle nested properties
  • documentation

@Zsailer Zsailer added the enhancement New feature or request label Aug 16, 2022
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
enhancement New feature or request
Projects
None yet
Development

Successfully merging this pull request may close these issues.

1 participant