Skip to content

Commit 69c0d76

Browse files
Add DLP settings page for account-level DLP configuration (#29967)
* Add DLP settings page for account-level DLP configuration - Create new dlp-settings.mdx page with OCR, AI context analysis, payload encryption key, and payload log masking documentation - Update logging-options.mdx to link to new DLP settings page for encryption key and masking configuration - Update advanced-settings.mdx with deprecation notices for profile-level OCR and AI context analysis - Update troubleshoot-dlp.mdx sidebar order to 6 and link to new DLP settings for OCR * Fix dashboard URLs: use dash.cloudflare.com with Zero Trust path * Remove Beta badge from AI context analysis * Remove invalid tag to fix build --------- Co-authored-by: Cody Anthony <canthony@cloudflare.com>
1 parent 13ae31a commit 69c0d76

4 files changed

Lines changed: 108 additions & 47 deletions

File tree

src/content/docs/cloudflare-one/data-loss-prevention/dlp-policies/logging-options.mdx

Lines changed: 2 additions & 36 deletions
Original file line numberDiff line numberDiff line change
@@ -24,43 +24,9 @@ The data that triggers a DLP policy is stored in the body of the HTTP request
2424

2525
## Set a DLP payload encryption public key
2626

27-
Before you begin logging DLP payloads, you will need to set a DLP payload encryption public key. DLP uses public-key encryption so that matched sensitive data is readable only by you — Cloudflare does not have access to your private key and cannot decrypt your logs.
27+
Before you begin logging DLP payloads, you will need to [set a DLP payload encryption public key](/cloudflare-one/data-loss-prevention/dlp-settings/#payload-encryption-key). DLP uses public-key encryption so that matched sensitive data is readable only by you — Cloudflare does not have access to your private key and cannot decrypt your logs.
2828

29-
### Generate a key pair
30-
31-
You will generate two keys: a public key (uploaded to Cloudflare to encrypt log data) and a private key (kept by you to decrypt log data later).
32-
33-
To generate a public/private key pair in the command line, refer to [Generate a key pair](/waf/managed-rules/payload-logging/command-line/generate-key-pair/).
34-
35-
### Upload the public key to Cloudflare
36-
37-
1. In the [Cloudflare dashboard](https://dash.cloudflare.com/), go to **Zero Trust** > **Data loss prevention** > **DLP settings**.
38-
2. In the **Set a DLP payload and prompt encryption public key** field, select **Edit**.
39-
3. Paste your public key.
40-
4. Select **Save**.
41-
42-
:::note
43-
The matching private key is required to view logs. If you lose your private key, you will need to [generate](#generate-a-key-pair) and [upload](#upload-the-public-key-to-cloudflare) a new public key. The payload of new requests will be encrypted with the new public key. Previously logged data encrypted with the old key will be permanently unreadable.
44-
:::
45-
46-
## Configure payload log masking
47-
48-
You can control how sensitive data appears in your DLP payload logs by selecting a masking level. This determines how much of the matched content is visible after decryption.
49-
50-
1. In the [Cloudflare dashboard](https://dash.cloudflare.com/), go to **Zero Trust** > **Data loss prevention** > **DLP settings**.
51-
2. Go to the **Payload log masking** card.
52-
3. Choose one of the following masking levels:
53-
- **Full Mask (default):** Masks the match while preserving character count and visual formatting. For example, a Social Security Number appears as `***-**-****`.
54-
- **Partial Mask:** Reveals 25% of the matched content while masking the remainder. For example, `***-**-6789`.
55-
- **Clear Text:** Stores the full, unmasked match for detailed investigation. For example, `123-45-6789`.
56-
57-
:::note
58-
The masking level is applied at detection time, before the payload is encrypted. Your team will see the selected format when they decrypt the log with your private key.
59-
:::
60-
61-
:::caution
62-
The selected masking level applies to all sensitive data matches found within a payload window — not just the match that triggered the policy.
63-
:::
29+
You can also [configure payload log masking](/cloudflare-one/data-loss-prevention/dlp-settings/#payload-log-masking) to control how DLP redacts sensitive data in logs.
6430

6531
## Log the payload of matched rules
6632

src/content/docs/cloudflare-one/data-loss-prevention/dlp-profiles/advanced-settings.mdx

Lines changed: 11 additions & 9 deletions
Original file line numberDiff line numberDiff line change
@@ -31,27 +31,29 @@ Match count sets a minimum threshold for detections. DLP does not trigger an act
3131

3232
### Optical Character Recognition (OCR)
3333

34+
:::note[Deprecation notice]
35+
Profile-level OCR settings will be deprecated in a future release. We recommend configuring OCR in [DLP settings](/cloudflare-one/data-loss-prevention/dlp-settings/#optical-character-recognition-ocr) instead.
36+
:::
37+
3438
Optical Character Recognition (OCR) analyzes and interprets text within image files. When used with DLP profiles, OCR can detect sensitive data within images your users upload.
3539

3640
OCR supports scanning `.jpg`/`.jpeg` and `.png` files between 4 KB and 1 MB in size. Text is encoded in UTF-8 format, including support for non-Latin characters.
3741

42+
For more information, refer to [DLP settings](/cloudflare-one/data-loss-prevention/dlp-settings/#optical-character-recognition-ocr).
43+
3844
### AI context analysis {/* ai-context-analysis */}
3945

46+
:::note[Deprecation notice]
47+
Profile-level AI context analysis settings will be deprecated in a future release. We recommend configuring AI context analysis in [DLP settings](/cloudflare-one/data-loss-prevention/dlp-settings/#ai-context-analysis) instead.
48+
:::
49+
4050
:::note
4151
AI context analysis only supports Gateway HTTP and HTTPS traffic.
4252
:::
4353

4454
AI context analysis uses a pretrained model to analyze surrounding context and adjust the confidence level of a detection. For example, a number that matches a credit card pattern may receive a lower confidence score if it appears in a context where credit card numbers are unlikely. DLP will log any matches that are above your confidence threshold.
4555

46-
DLP redacts any matched text, then converts the surrounding context into a vector embedding and submits it to [Cloudflare Workers AI](/workers-ai/). Vector embeddings (not raw text) are stored in user-specific private namespaces for up to six months, along with hit count and the [false positive/negative report](/cloudflare-one/data-loss-prevention/dlp-policies/logging-options/#report-false-and-true-positives-to-ai-context-analysis).
47-
48-
To use AI context analysis:
49-
50-
1. Choose the **Confidence threshold** in a DLP profile.
51-
2. [Add the profile](/cloudflare-one/data-loss-prevention/dlp-policies/#2-create-a-dlp-policy) to a DLP policy.
52-
3. When configuring the DLP policy, turn on [payload logging](/cloudflare-one/data-loss-prevention/dlp-policies/logging-options/#log-the-payload-of-matched-rules).
53-
54-
AI context analysis results will appear in the payload section of your [DLP logs](/cloudflare-one/data-loss-prevention/dlp-policies/#4-view-dlp-logs). To improve future detections of sensitive data, you need to [report false and true positives](/cloudflare-one/data-loss-prevention/dlp-policies/logging-options/#report-false-and-true-positives-to-ai-context-analysis).
56+
For full documentation on AI context analysis, refer to [DLP settings](/cloudflare-one/data-loss-prevention/dlp-settings/#ai-context-analysis).
5557

5658
### Confidence thresholds
5759

Lines changed: 93 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,93 @@
1+
---
2+
pcx_content_type: how-to
3+
title: DLP settings
4+
sidebar:
5+
order: 5
6+
---
7+
8+
DLP settings allow you to configure account-level settings that apply across all DLP profiles and policies. These settings are located in **Zero Trust** > **Data loss prevention** > **DLP settings** in the [Cloudflare dashboard](https://dash.cloudflare.com/).
9+
10+
## Optical Character Recognition (OCR)
11+
12+
Optical Character Recognition (OCR) analyzes and interprets text within image files. When turned on, OCR can detect sensitive data within images your users upload.
13+
14+
OCR supports scanning `.jpg`/`.jpeg` and `.png` files between 4 KB and 1 MB in size. Text is encoded in UTF-8 format, including support for non-Latin characters.
15+
16+
To turn on OCR:
17+
18+
1. In the [Cloudflare dashboard](https://dash.cloudflare.com/), go to **Zero Trust** > **Data loss prevention** > **DLP settings**.
19+
2. Turn on **Optical Character Recognition (OCR)**.
20+
21+
## AI context analysis
22+
23+
:::note
24+
AI context analysis only supports Gateway HTTP and HTTPS traffic.
25+
:::
26+
27+
AI context analysis uses a pretrained model to analyze surrounding context and adjust the confidence level of a detection. For example, a number that matches a credit card pattern may receive a lower confidence score if it appears in a context where credit card numbers are unlikely. DLP will log any matches that are above your confidence threshold.
28+
29+
DLP redacts any matched text, then converts the surrounding context into a vector embedding and submits it to [Cloudflare Workers AI](/workers-ai/). Vector embeddings (not raw text) are stored in user-specific private namespaces for up to six months, along with hit count and the [false positive/negative report](/cloudflare-one/data-loss-prevention/dlp-policies/logging-options/#report-false-and-true-positives-to-ai-context-analysis).
30+
31+
To turn on AI context analysis:
32+
33+
1. In the [Cloudflare dashboard](https://dash.cloudflare.com/), go to **Zero Trust** > **Data loss prevention** > **DLP settings**.
34+
2. Turn on **AI context analysis**.
35+
3. [Add the profile](/cloudflare-one/data-loss-prevention/dlp-policies/#2-create-a-dlp-policy) to a DLP policy.
36+
4. When configuring the DLP policy, turn on [payload logging](/cloudflare-one/data-loss-prevention/dlp-policies/logging-options/#log-the-payload-of-matched-rules).
37+
38+
AI context analysis results will appear in the payload section of your [DLP logs](/cloudflare-one/data-loss-prevention/dlp-policies/#4-view-dlp-logs). To improve future detections of sensitive data, you need to [report false and true positives](/cloudflare-one/data-loss-prevention/dlp-policies/logging-options/#report-false-and-true-positives-to-ai-context-analysis).
39+
40+
## Payload encryption key
41+
42+
Before you begin logging DLP payloads, you will need to set a DLP payload encryption public key. DLP uses public-key encryption so that matched sensitive data is readable only by you — Cloudflare does not have access to your private key and cannot decrypt your logs.
43+
44+
### Generate a key pair
45+
46+
You will generate two keys: a public key (uploaded to Cloudflare to encrypt log data) and a private key (kept by you to decrypt log data later).
47+
48+
To generate a public/private key pair in the command line, refer to [Generate a key pair](/waf/managed-rules/payload-logging/command-line/generate-key-pair/).
49+
50+
### Upload the public key to Cloudflare
51+
52+
1. In the [Cloudflare dashboard](https://dash.cloudflare.com/), go to **Zero Trust** > **Data loss prevention** > **DLP settings**.
53+
2. In the **DLP Payload Encryption public key** field, paste your public key.
54+
3. Select **Save**.
55+
56+
:::note
57+
The matching private key is required to view logs. If you lose your private key, you will need to [generate](#generate-a-key-pair) and [upload](#upload-the-public-key-to-cloudflare) a new public key. The payload of new requests will be encrypted with the new public key. Previously logged data encrypted with the old key will be permanently unreadable.
58+
:::
59+
60+
## Payload log masking
61+
62+
You can control how sensitive data appears in your DLP payload logs by selecting a masking level. This determines how much of the matched content is visible after decryption.
63+
64+
To configure payload log masking:
65+
66+
1. In the [Cloudflare dashboard](https://dash.cloudflare.com/), go to **Zero Trust** > **Data loss prevention** > **DLP settings**.
67+
2. Go to the **Payload log masking** card.
68+
3. Choose one of the following masking levels:
69+
- **Full Mask (default):** Masks the match while preserving character count and visual formatting. For example, a Social Security Number appears as `***-**-****`.
70+
- **Partial Mask:** Reveals 25% of the matched content while masking the remainder. For example, `***-**-6789`.
71+
- **Clear Text:** Stores the full, unmasked match for detailed investigation. For example, `123-45-6789`.
72+
73+
:::note
74+
The masking level is applied at detection time, before the payload is encrypted. Your team will see the selected format when they decrypt the log with your private key.
75+
:::
76+
77+
:::caution
78+
The selected masking level applies to all sensitive data matches found within a payload window — not just the match that triggered the policy.
79+
:::
80+
81+
## Migrate from profile-level settings
82+
83+
OCR and AI context analysis are available at both the profile level (**Data loss prevention** > **Profiles**) and the account level (**Data loss prevention** > **DLP settings**) during the migration period. When both are configured, DLP uses OR logic for evaluation. A match occurs if either the profile-level or account-level setting would trigger a detection.
84+
85+
Profile-level OCR and AI context analysis settings will be deprecated in a future release. We recommend migrating to account-level settings in **DLP settings** to ensure consistent behavior across all profiles.
86+
87+
To migrate:
88+
89+
1. In the [Cloudflare dashboard](https://dash.cloudflare.com/), go to **Zero Trust** > **Data loss prevention** > **DLP settings**.
90+
2. Turn on **Optical Character Recognition (OCR)** and/or **AI context analysis** as needed.
91+
3. Go to **Zero Trust** > **Data loss prevention** > **Profiles**.
92+
4. For each profile with OCR or AI context analysis enabled, edit the profile and turn off the profile-level settings.
93+
5. Select **Save profile**.

src/content/docs/cloudflare-one/data-loss-prevention/troubleshoot-dlp.mdx

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -5,7 +5,7 @@ description: Troubleshoot Troubleshoot DLP issues in Cloudflare One.
55
products:
66
- cloudflare-one
77
sidebar:
8-
order: 5
8+
order: 6
99
tags:
1010
- Debugging
1111
---
@@ -59,7 +59,7 @@ You can also create policies that match trusted applications using the [**Do Not
5959

6060
If DLP detects sensitive data in plain text but not within images or certain applications, check for the following issues:
6161

62-
- **OCR is turned on**: For DLP to scan text within images (such as a picture of a credit card), you must turn on [Optical Character Recognition (OCR)](/cloudflare-one/data-loss-prevention/dlp-profiles/advanced-settings/#optical-character-recognition-ocr) in the corresponding DLP profile.
62+
- **OCR is turned on**: For DLP to scan text within images (such as a picture of a credit card), you must turn on [Optical Character Recognition (OCR)](/cloudflare-one/data-loss-prevention/dlp-settings/#optical-character-recognition-ocr) in DLP settings.
6363
- **Application-specific behavior**: Some applications, such as WhatsApp Web, use protocols or encryption methods (such as WebSocket connections) that Gateway may not be able to fully inspect with HTTP policies.
6464
- **Supported file types**: Content must be in a [supported file type](/cloudflare-one/data-loss-prevention/#supported-file-types) for DLP inspection.
6565

0 commit comments

Comments
 (0)