Skip to content

Commit

Permalink
swap to personal vault
Browse files Browse the repository at this point in the history
  • Loading branch information
bphillips-99 committed Apr 16, 2024
1 parent 245703f commit bc26c4b
Show file tree
Hide file tree
Showing 2 changed files with 90 additions and 191 deletions.
90 changes: 90 additions & 0 deletions tntwgapiypr.yaml
Original file line number Diff line number Diff line change
@@ -0,0 +1,90 @@
data:
- attributes:
created_at: '2023-09-25T21:54:39'
destination_override_endpoint: 'https://api.sandbox.verygoodvault.com'
entries: []
host_endpoint: 'tnt[a-z0-9]+-[a-z0-9-]+.[A-Za-z0-9-]\.sandbox\.verygoodproxy\.com'
id: 7d893471-7b67-4d76-95f3-0162dacf648f
ordinal: null
port: 80
protocol: http
source_endpoint: '*'
tags:
name: dark-blue-cylinder
source: tokenizationCollect
updated_at: '2023-09-25T23:04:59'
id: 7d893471-7b67-4d76-95f3-0162dacf648f
type: rule_chain
- attributes:
created_at: '2023-09-25T23:13:27'
destination_override_endpoint: 'https://echo.apps.verygood.systems'
entries:
- classifiers: {}
config:
condition: AND
expression: null
rules:
- condition: null
expression:
field: PathInfo
operator: matches
type: string
values:
- /post
rules: null
- condition: null
expression:
field: ContentType
operator: equals
type: string
values:
- application/json
rules: null
id: abc62a87-620e-41c9-8416-8a5a5aa6e757
id_selector: null
operation: REDACT
operations:
- name: github.com/verygoodsecurity/common/compute/larky/http/Process
parameters:
script: |
load("@stdlib//json", json="json") # import json library
load("@stdlib//builtins", builtins="builtins")
load("@vgs//vault", "vault")
def process(input, ctx):
body = json.loads(input.body.decode("utf-8"))
# store body in a vault and replace it with an alias
body['account_number'] = vault.redact(body['account_number'])
redacted_body = builtins.bytes(json.dumps(body))
redacted_headers = {}
for k in input.headers:
redacted_headers[k] = vault.redact(input.headers[k])
# construct a redacted response
input.body = redacted_body
input.headers = redacted_headers
return input
phase: REQUEST
public_token_generator: UUID
targets:
- body
token_manager: PERSISTENT
transformer: JSON_PATH
transformer_config:
- $.account_number
transformer_config_map: null
host_endpoint: (.*)\.verygoodproxy\.com
id: 6df940d9-4476-4489-9028-245278ac13a5
ordinal: null
port: 80
protocol: http
source_endpoint: '*'
tags:
name: echo.apps.verygood.systems-medium-aqua-marine-rhombus
source: RouteContainer
updated_at: '2023-09-25T23:17:19'
id: 6df940d9-4476-4489-9028-245278ac13a5
type: rule_chain
version: 1
191 changes: 0 additions & 191 deletions tntyc17ae1g.yaml

This file was deleted.

0 comments on commit bc26c4b

Please sign in to comment.