Mask a field for consumers onlyv1.3+

Redact an email field for the client that reads it. The record in the backend cluster doesn’t change, so systems that are permitted to see the original value keep their access to it.

The email strategy applies a separate strategy to each part of the address. This example keeps the first character of the local part and the whole domain, which is enough to recognize an account without exposing the full address.

Prerequisites

Environment variables

  • PARENT_POLICY_ID: The UUID of the parent Schema Validation policy.

Set up the policy

Help us make these docs great!

Kong Developer docs are open source. If you find these useful and want to make them better, contribute today!