1
1
---
2
- title : Secrets encryption and PII redaction
2
+ title : Secrets and PII redaction
3
3
description : Keep your secrets a secret
4
4
---
5
5
@@ -22,13 +22,12 @@ and PII found in your prompts.
22
22
23
23
CodeGate automatically scans all prompts for secrets and PII. This happens
24
24
transparently without requiring a specific prompt. Without interrupting your
25
- development flow, CodeGate protects your data by encrypting secrets and
25
+ development flow, CodeGate protects your data by redacting secrets and
26
26
anonymizing PII. These changes are made before the prompt is sent to the LLM and
27
27
are restored when the result is returned to your machine.
28
28
29
29
When a secret or PII is detected, CodeGate adds a message to the LLM's output
30
- and an alert is recorded in the [ dashboard] ( ../how-to/dashboard.md ) (PII alerts
31
- in the dashboard are coming soon).
30
+ and an alert is recorded in the [ dashboard] ( ../how-to/dashboard.md ) .
32
31
33
32
::: info
34
33
@@ -55,36 +54,32 @@ sequenceDiagram
55
54
deactivate CodeGate
56
55
```
57
56
58
- ### Secrets encryption
57
+ CodeGate redacts secrets and anonymizes PII by replacing each string with a
58
+ unique identifier on the fly, before sending the prompt to the LLM. This way,
59
+ CodeGate protects your sensitive data without blocking your development flow.
60
+ When the LLM returns a response, CodeGate matches up the identifier and replaces
61
+ it with the original value.
59
62
60
- CodeGate uses pattern matching to detect secrets such as:
63
+ ### Secrets filtering
64
+
65
+ CodeGate uses pattern matching to detect secrets like:
61
66
62
67
- API keys and tokens
63
- - Private keys and certificates
68
+ - Cloud provider credentials
64
69
- Database credentials
70
+ - Private keys and certificates
65
71
- SSH keys
66
- - Cloud provider credentials
67
- - ...and more - see the
68
- [ signatures file] ( https://github.com/stacklok/codegate/blob/main/signatures.yaml )
69
- in the project repo
70
72
71
- CodeGate transparently encrypts secrets before sending the prompt to the LLM.
72
- This is performed on the fly using AES256-GCM encryption with a temporary
73
- per-session key. When the LLM returns a response, CodeGate decrypts the secret
74
- before delivering it to your coding assistant, then securely erases the
75
- temporary key from memory.
73
+ For the full list of detected patterns, see the
74
+ [ signatures file] ( https://github.com/stacklok/codegate/blob/main/signatures.yaml )
75
+ in the project repo.
76
76
77
77
### PII redaction
78
78
79
- CodeGate scans for common types of PII like :
79
+ CodeGate scans for common types of PII including :
80
80
81
81
- Email addresses
82
82
- Phone numbers
83
83
- Government identification numbers
84
84
- Credit card numbers
85
85
- Bank accounts and crypto wallet IDs
86
-
87
- CodeGate anonymizes PII by replacing each string with a unique identifier before
88
- sending the prompt to the LLM. This way, CodeGate protects your sensitive data
89
- without blocking your development flow. When the LLM returns a response,
90
- CodeGate matches up the identifier and replaces it with the original value.
0 commit comments