Detection IDs は、人間のトラフィックと重ならない、予測可能なボット挙動を検出する静的ルールです。各 ID は、ヒューリスティック、検証済みボット検出、異常検出など、特定の 検出方法 に対応します。たとえば、クライアントが自称ブラウザーとは異なる順でヘッダーを送った場合を、Detection ID で識別できます。
ヒューリスティックに問題がある場合、お客様が設定できるヒューリスティックで、ゾーンに適用するヒューリスティックを選べます。Cloudflare のヒューリスティックエンジンで検出したボットごとに、異なるアクションを選べます。サイトのトラフィックに合わせて、特定のボットをブロック、許可、または別コンテンツの配信ができます。
cf.bot_management.detection_ids フィールドは、次のようなツールで使えます。
- Custom rules
- Advanced Rate Limiting
- Transform Rules
- Workers(
request.cf.botManagement.detectionIdsとして)
Bot Detection IDs とタグは、Bot Analytics と Security Analytics でも利用できます。
検出タグは、Cloudflare がボットをフィンガープリントした時点で、その Detection ID に紐づくカテゴリです。たとえば検出タグが go なら、その Detection ID のトラフィックを、Go 言語のボットから観測したことを意味します。
-
Cloudflare ダッシュボードで Security Analytics ページを開きます。
Analytics を開く ↗ -
フィルターを適用し、Create custom security rule を選択して、フィルターに基づくカスタムルールを作成します。
すでにカスタムルールがある場合は、Security rules で既存ルールを開き、フィルターに基づいて式を編集することもできます。
Security rules を開く ↗ -
ルール式で
cf.bot_management.detection_idsフィールドを使います。 -
Deploy を選択します。
any(cf.bot_management.detection_ids[*] eq 3355446)
and not cf.bot_management.verified_bot
and http.request.uri.path eq "/login"
and http.request.method eq "POST"cf.bot_management.score lt 30
and not cf.bot_management.verified_bot
and http.request.uri.path eq "/login"
and http.request.method eq "POST"
and not any(cf.bot_management.detection_ids[*] in {3355446 12577893})新しい Logpush ジョブを作成するか、既存ジョブを編集して、Bot Detection IDs フィールドを含められます。ヒューリスティックに一致した各リクエストの ID 配列が得られます。BotDetectionIDs フィールドは HTTP Requests データセットの一部です。Logpush API または Cloudflare ダッシュボードで、新規または既存ジョブに追加できます。Detection IDs を見つける主な方法です。
-
Cloudflare ダッシュボードで Logpush ページを開きます。
Logpush を開く ↗ -
Create a Logpush Job を選択します。
-
送信先情報を選択して入力します。
-
データセットとして HTTP Requests を選択します。
-
General データフィールドカテゴリの BotDetectionIDs を選択します。
-
所有権を証明します。
-
Save を選択します。
output_options: パラメーターに BotDetectionIDs を追加して、Logpush ジョブを更新 します。
Detection IDs は、Enterprise Bot Management のお客様が利用できます。