How to implement classifier tags on data?

Context
Before you start processing data with VGS, it is a good idea to map the use cases and the data you plan to store with VGS. Work with your team (i.e. business analyst, data engineer, or engineer) to help provide context on how you want to map and store VGS aliases in relation to your system and the relevant records.


Documentation

Once you have agreed internally on the tagging of your data, I recommend testing in your SANDBOX vault how to create the tags, include, or exclude these VGS aliases from being used in your VGS vault. Please read the overview of using tags at the link below.
https://www.verygoodsecurity.com/docs/features/data-classification


VGS Steps
Once you understand the context of how to use classifiers, I recommend testing in your SANDBOX vault to see how this would work before adding to your LIVE vault.
---
Step 1:
When you send a request to alias values in your payload, you need to specify the data classifier too (or enable a default classifier tag within the INBOUND route). Otherwise the aliases will not be properly tagged. Think of it as you need to set the tags when you create the aliases. The VGS Dashboard routes allow you to set default tags on the INBOUND route.

The examples below will give you a better picture. Please remember that if this is sensitive card information, you'll want to use VGS Collect.js and/or the VGS SDKs.

INBOUND ROUTE REQUEST:
Please note that you need to add the data classifiers to tag the values you alias; Otherwise, you need to set one of the default tags in the INBOUND route to apply a default classifier tag.

curl https://<VGS VAULT ID>.sandbox.verygoodproxy.com/post \
-H "Content-type: application/json" \
-d '{"card_number": "4111111111111111", "data": {"classifiers": [ "card-number", "PII"]}}'

INBOUND ROUTE RESPONSE:

  "json": {
    "card_number": "tok_sandbox_htyxUZKGeCqLpzYQ7YU7Ki",
    "data": {
      "classifiers": [
        "card-number",
        "PII"
      ]
    }
  },

Step 2:
Choose to include/exclude tags you will allow to reveal on OUTBOUND routes. Please remember to set within your VGS Dashboard in your OUTBOUND routes.

OUTBOUND ROUTE REQUEST:
Please note that if you use a classifier this will allow only work if the alias was originally classified.

curl https://echo.apps.verygood.systems/post -k \
-x <VGS USERNAME>:<VGS PASSWORD>@<VGS VAULT ID>.sandbox.verygoodproxy.com:8080 \
-H "Content-type: application/json" \
-d '{"card_number": "tok_sandbox_htyxUZKGeCqLpzYQ7YU7Ki"}'

RESPONSE IF MATCHING OUTBOUND TAG(S) TO INCLUDE:

  "json": {
    "card_number": "4111111111111111"
  },

RESPONSE IF NOT MATCHING OUTBOUND TAG(s) TO INCLUDE:

  "json": {
    "card_number": "tok_sandbox_htyxUZKGeCqLpzYQ7YU7Ki"
  },

---


Additional Information

In case you want to delete an existing alias, please use the Vault API to delete the alias.
https://www.verygoodsecurity.com/docs/vault/api/#operation/deleteAlias

curl -u <VGS USERNAME>:<VGS PASSWORD> \
-v -X DELETE https://api.sandbox.verygoodvault.com/aliases/tok_sandbox_htyxUZKGeCqLpzYQ7YU7Ki


In case you want to apply a classifier after an alias is already created, please use the Vault API to update the alias.
https://www.verygoodsecurity.com/docs/vault/api/#operation/updateAlias

curl https://api.sandbox.verygoodvault.com/aliases/tok_sandbox_htyxUZKGeCqLpzYQ7YU7Ki \
-X PUT \
-u <VGS USERNAME>:<VGS PASSWORD> \
-H 'Content-Type: application/json' \
-d '{"data": {"classifiers": [ "card-number", "PII"]}}'
Was this article helpful?
0 out of 0 found this helpful

Comments

0 comments

Please sign in to leave a comment.