You can deploy the JSON Masking Authorizer with its Helm chart, as part of the PAA Helm chart, or as a standalone service. All three read the same YAML configuration keys. One deployment serves every calculation type, so the configuration holds the Resolution keys and the Data Instructions keys side by side, and each request reads only the keys of its own mode. Configuration changes take effect when the Authorizer restarts.
Deploying via Helm Chart
The Helm chart deploys the Authorizer into Kubernetes environments. Use it for scalable production workloads and cloud-native deployments.
Downloading the Helm Chart
- Open the PlainID Platform.
- Open your Tenant or Environment Settings:
- Tenant Settings: Click the Settings icon in the Tenant Navigation bar.
- Environment Settings: In your Environment Workspace, click Environment Settings in the left sidebar.
- Click Authorizers.
- Select JSON Authorizer Helm and download it.
- Open the Helm chart from your Downloads folder.
Helm Commands
Set the keys from the Configuration Reference under config in your values.yaml file, then install or upgrade:
# Install the Authorizer
helm install json-authorizer ./json-authorizer-chart -f values.yaml
# Upgrade an existing deployment
helm upgrade json-authorizer ./json-authorizer-chart -f values.yaml
PAA Deployment
The PAA Helm chart includes the Authorizer, so you do not need a separate chart. The PAA chart disables the Authorizer by default, and you enable it in your custom values file.
Before you begin: Do not edit the PAA chart itself. Make all changes in your values-custom.yaml file.
To enable the Authorizer in the PAA package:
- Open the
values-custom.yamlfile for your PAA deployment. - Add the Authorizer section, set
enabledtotrue, and add a valid configuration from the Configuration Reference:
[JSON Authorizer key]:
enabled: true
# Add your JSON Authorizer configuration here
- Apply the changes to your PAA deployment:
helm upgrade -i my-plainid-paa plainid-paa --values values-custom.yaml
Note: The Authorizer needs both
enabled: trueand a valid configuration. If you enable it without a valid configuration, the pod fails and shows a manifest error.
To expose the Authorizer outside the cluster, or to migrate from a standalone chart, see Authorizers in the Kubernetes Deployment guide.
Standalone Deployment
The standalone service runs the Authorizer as a local process in non-Kubernetes environments. Use it for local development, VM-based deployments, and proof-of-concept setups.
Prerequisites
- Access to a PlainID PDP Runtime endpoint
- Network connectivity between the Authorizer and the PDP Runtime
- Access to the target APIs or application services
- A supported Linux or compatible runtime environment
Downloading the Standalone Package
- Open the PlainID Platform.
- Open your Tenant or Environment Settings.
- Click Policy Authorization Agents.
- Select JSON Masking Authorizer and download it.
- Open the package from your Downloads folder.
Installing and Running
- Create a local configuration file:
cp sample-config.yaml config.yaml
- Set the keys from the Configuration Reference under
configinconfig.yaml. The file uses the same format as the Helmvalues.yamlexample. - Start the service in the background, or run it in the foreground:
./start.sh
# or
./authz-jsonmasking -c "./config.yaml"
- Check the log and the health endpoints:
tail -f ./authz-jsonmasking.log
curl http://127.0.0.1:5002/health/liveness
curl http://127.0.0.1:5002/health/readiness
A successful response means the service is ready to process requests. You can connect the health endpoints to external monitoring systems.
- Stop the service when needed:
./stop.sh
Configuration Reference
Shared Keys
All calculation types read these keys.
| Key | Default | Description |
|---|---|---|
port |
5002 |
The port the Authorizer listens on. |
pdpUrl |
None | Origin of the PDP: the PlainID cloud PDP (https://<tenant>.<region>.plainid.io, region us1, eu1, or ca1) or your PAA runtime. Each mode adds its own endpoint path. Existing configurations that set the full resolution path (for example http://plainid-pdp/api/runtime/resolution/v3) keep working. |
pdpHost, pdpPort |
None | Granular alternative to pdpUrl. When you set pdpHost, the origin is pdpHost:pdpPort and it takes precedence over pdpUrl. |
assetType |
columns |
The Asset Type that represents the protected data properties. In Data Instructions mode, the masking catalog Asset Type. The request parameter parameters.assetType overrides it. |
functions |
None | The masking functions that function Actions may call: md5, last4, mask_4, first, middle, last, edges. List every function your Actions use. In Data Instructions mode, a FUNCTION Action whose function is not listed writes null, so with no list, every FUNCTION Action writes null. |
maxBody |
4 |
Maximum request body in MB. Larger requests return HTTP 413 (Payload Too Large). |
log.level |
info |
error, warn, info, debug, or trace. At debug, the Authorizer logs every PDP request and response. |
Resolution and Context Mode Keys
Requests with calculationType: "resolution", "context", or no calculation type use these keys.
Data Instructions mode ignores them.
| Key | Description |
|---|---|
pdpResolutionPath |
Path of the PDP Policy Resolution endpoint, used by Resolution mode. Default /api/runtime/resolution/v3. |
pdpTokenPath |
Path of the PDP User Access Token endpoint, used by the context calculation type. Default /api/runtime/token/v3. |
attrName |
The Asset Attribute that defines the data properties (columns) in the PDP resolution response. |
object |
The Asset Attribute that defines the prefix path of properties nested under the protected object. |
rootWord |
A root word added to the enforce request when the calling service sends JSON without a specific root. |
maskString |
Default masking for string values. |
filter |
true to filter and mask, false to mask only. |
Data Instructions Mode Keys
Requests with calculationType: "dataInstructions" use these keys.
| Key | Default | Description |
|---|---|---|
pdpDataInstructionsPath |
/api/runtime/data-instructions/v3 |
Path of the PDP Data Instructions endpoint. The default applies when the key is absent or empty. |
dataPropertyKey |
None | The Asset Attribute of the masking catalog Assets that holds the property path. Use path to take the path from the Asset ID. Replaces attrName for this mode. The request parameter parameters.dataPropertyKey overrides it. |
leastPrivileges |
false |
false: return everything that Policies do not hide. true: deny by default, and return only what Policies grant. See Deny by Default below. |
Note: Data Instructions mode takes masking values from the Actions in your Policies, not from
maskString, and takes row filtering from your Policies, not fromfilter.
Deny by Default
leastPrivileges decides what happens to data that no Policy mentions.
leastPrivileges |
Objects (rows) | Properties without an instruction |
|---|---|---|
false (default) |
Removed only when a Deny Policy matches them | Returned unchanged |
true |
Kept only when an Allow Policy matches them and no Deny Policy does | Masked by type: "***", 0, false, or null |
Test both settings before you switch. For the full rules, see Policy Implementation.
Example values.yaml Configuration
This configuration serves both modes. Use the same format in a standalone config.yaml.
config:
port: 5002
pdpUrl: "https://<tenant>.us1.plainid.io"
log:
level: "info"
maxBody: 4
assetType: "DataCatalog"
functions:
- md5
- last4
- mask_4
- first
- middle
- last
- edges
# Resolution mode (default)
pdpResolutionPath: "/api/runtime/resolution/v3"
rootWord: "result"
attrName: "column"
object: "table"
maskString: "***"
filter: true
# Data Instructions mode
pdpDataInstructionsPath: "/api/runtime/data-instructions/v3"
dataPropertyKey: "path"
leastPrivileges: false