Skip to content
Cloudflare Docs

Profile settings

This page lists the profile settings available when configuring a predefined or custom DLP profile. You can configure profile settings when you create a custom profile or edit profile settings for an existing predefined or custom profile.

Edit profile settings

To edit profile settings for an existing predefined or custom DLP profile:

  1. In Zero Trust, go to DLP > DLP profiles.
  2. Choose a profile, then select Edit.
  3. In Settings, configure the settings for your profile.
  4. Select Save profile.

Available settings

The following advanced detection settings are available for predefined and custom DLP profiles.

Match count

Match count refers to the number of times that any enabled entry in the profile can be detected before an action is triggered, such as blocking or logging. For example, if you select a match count of 10, the scanned file or HTTP body must contain 11 or more matching strings. Detections do not have to be unique.

Optical Character Recognition (OCR)

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.

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.

AI context analysis Beta

AI context analysis uses machine learning to analyze and adjust the confidence in a detection based on its surrounding context. DLP will log any matches that are above your confidence threshold.

DLP submits the context as an AI text embedding vector to Cloudflare Workers AI. Vectors are stored in a database bucket for up to six months, along with relevant metadata from the HTTP request including the URL, HTTP method, matching DLP profile, and Gateway request ID.

To use AI context analysis:

  1. Turn on AI context analysis in a DLP profile.
  2. Add the profile to a DLP policy.
  3. When configuring the DLP policy, turn on payload logging.

AI context analysis results will appear in the payload section of your DLP logs. To further train the machine learning model, you need to report false and true positives.

Confidence thresholds

Confidence thresholds indicate how confident Cloudflare DLP is in a DLP detection. DLP determines the confidence by inspecting the content for proximity keywords around the detection.

Confidence threshold is set on the DLP profile. When you select a confidence threshold in Zero Trust, you will see which DLP entries will be affected by the confidence threshold. Entries that do not reflect a confidence threshold in Zero Trust are not yet supported or are not applicable.

DLP confidence detections consist of Low, Medium, and High confidence thresholds. DLP will default to Low confidence detections, which are based on regular expressions, require few keywords, and will trigger more often. Medium and High confidence detections require more keywords, will trigger less often, and have a higher likelihood of accuracy.

To change the confidence threshold of a DLP profile:

  1. In Zero Trust, go to DLP > DLP profiles.
  2. Select the profile, then select Edit.
  3. In Settings > Confidence threshold, choose a new confidence threshold from the dropdown menu.

Setting the confidence to Low will also consider Medium and High confidence detections as matches. Setting the confidence to Medium or High will filter out lower confidence detections.

Gateway detections

For inline detections in Gateway, to display Low and Medium confidence detections but block High confidence detections, Cloudflare recommends creating two HTTP policies. The first policy should use a Low confidence DLP profile with an Allow action. The second policy should use a High confidence DLP profile with a Block action. For example:

SelectorOperatorValueAction
DLP ProfileinLow Confidence DetectionsAllow
SelectorOperatorValueAction
DLP ProfileinHigh Confidence DetectionsBlock