CloudGuard WAF
  • Documentation Overview
  • What is CloudGuard WAF?
  • Getting started
    • Prepare key information
    • Log in to the Infinity Portal
    • Protect a Web Application / API
    • Deploy Enforcement Point
      • Gateway/Virtual Machine
        • AWS
          • Store Certificates in AWS
          • Store certificates on Gateway
        • Azure
          • Store Certificates in Azure
          • Store Certificates on Gateway
        • VMware
          • Store Certificates on Gateway
          • Configure networking in VMware Deployments
      • WAF as a Service
        • Certificates Managed by Check Point
        • Bring Your Own Certificate
      • Kubernetes Ingress
        • Kong Application Security
        • Istio Application Security
      • Docker
        • Single Docker
          • Deployment using 'docker' command
            • Store Certificates Locally on Docker
          • Deployment in Azure App Services
        • Dual Docker: NGINX/Kong/Envoy + Security Agent
      • Linux / NGINX / Kong
    • Monitor Events
  • Concepts
    • Gateways & Agents
    • Management & Automation
    • Security Practices
    • Contextual Machine Learning
  • Additional Security Engines
    • Anti-Bot
    • API Protection
      • API Discovery
      • Track API Discovery Learning
      • Enforce API Schema
    • File Security
    • Intrusion Prevention System (IPS)
    • Rate Limit
    • Snort Rules
  • SETUP INSTRUCTIONS
    • Setup Custom Rules and Exceptions
    • Setup Web User Response Pages
    • Setup Log Triggers
    • Setup Report Triggers
    • Setup Notification Triggers
    • Setup Behavior Upon Failure
    • Setup Agent Upgrade Schedule
  • HOW TO
    • Edit Web Application/API Settings
    • Edit Reverse Proxy Advanced Settings for a Web Asset
    • Protect an existing production site with CloudGuard WAF's Gateway
    • View Policy of all your Web Applications/APIs
    • Add Data Loss Prevention (DLP) rules
    • Configure Contextual Machine Learning for Best Accuracy
    • Track Agent Status
    • Track Learning and Move from Learn/Detect to Prevent
    • Rotate profile authentication token
    • Upgrade your Reverse Proxy when a Linux/NGINX agent is installed
    • Use Terraform to Manage CloudGuard WAF
    • Authorize Temporary Access for Check Point Support
    • Restrict Access to Backend Servers from CloudGuard WAF as a Service IPs Only
  • Troubleshooting
    • WAF Gateway / Virtual Machine
      • Azure
        • "Unable to find a tag containing the vault's name in the VMSS" Error
        • How To: Configure Key Vault for a Single Gateway
      • NGINX Error: Upstream Sent Too Big Header While Reading Response Header from Upstream
      • How To: Compare Between the Gateway's Certificate and the Upstream Certificate
    • Linux
      • SELinux: Checking Status and Disabling
    • WAF as a Service
      • Certificate Validation Failed: Adjusting CAA Record
      • How To: Redirect a Root Domain to a Subdomain Protected by WAF SaaS
      • How To: Extend Connection Timeout to Upstream
      • How To: Update Expired Certificates
  • references
    • Agent CLI
    • Management API
    • Event Query Language
    • Writing Snort Signatures
    • Events/Logs Schema
    • CVE-2022-3786 and CVE-2022-3602: OpenSSL X.509 Email Address Buffer Overflows (HIGH)
    • CVE-2025-1097, CVE-2025-1098, CVE-2025-24514, CVE-2025-1974: Ingress NGINX Controller RCE (Critical)
  • Resources
    • GitHub
    • Docker Hub
Powered by GitBook
On this page
  • How to set up rate limit in a CloudGuard WAF agent
  • Advanced option in CloudGuard WAF's AppSec Gateways - Limit only according to IP addresses

Was this helpful?

  1. Additional Security Engines

Rate Limit

PreviousIntrusion Prevention System (IPS)NextSnort Rules

Last updated 3 months ago

Was this helpful?

CloudGuard WAF agents have the ability to limit the number of requests to a matched URI within a configured time scope, according to the source identifier.

How to set up rate limit in a CloudGuard WAF agent

Step 1: Activate Rate Limit from the Practices tab when editing an asset

Browse to Policy->Assets and edit the relevant Web Application / API asset.

Once the asset edit window opens, select the Rate Limit tab and click on Click to add a new Rate Limit Practice.

Pay attention to the configuration of Source Identity. When counting requests to see if a limit was exceeded, the source identity is the key according to which they are counted.

i.e. "X requests from the same source identifier..."

If the source identity configuration doesn't match a value, the source IP address is used instead for the purposes of counting the request.

Step 2: Add a New Rate Limit Rule

Click on Click to add a new Rate Limit rule. When creating a new rule or editing an existing rule, a configuration window will open:

A rate limit rule consists of:

  • Action configuration. there are 3 options:

    1. According to practice - The action will be determined by the practice mode previously configured.

    2. Detect - Only logs will be issued if the rate limit for this rule is reached. This will override the practice mode unless it is Inactive.

    3. Prevent - Rate limit for this rule is enforced. This will override the practice mode unless it is Inactive.

  • Match conditions:

    • URI - A string written in this field is concatenated as a suffix to all defined URLs of the Web Application or Web API asset. The concatenation result is considered the prefix for all requests that will match this rule. While the URI field does not accept a regular expression, it does support usage of '*' wildcard character. Example - If the Asset's defined URLs are "http://www.myapp.com" and "https://www.mysecureapp.com" and the URI in the rule is "/docs", it will be matched on all requests starting with either http://www.myapp.com/docs or https://www.mysecureapp.com/docs.

      Use "/" to match all requests to the asset's domains.

    • Additional Conditions - An optional logical expression in addition to the main URI regular expression. The logical expression can use AND/OR/NOT between matching key-value pairs to decide what traffic should be counted to determine if rate of requests has exceeded. There are several keys that can be used:

      • URI - A regular expression that is matched on the URI field. Since the main URI field already creates an initial prefix match of the URI path, the regular expression is usually used to match specific states if a wildcard was used, or strings in the full URI beyond the prefix.

      • Source Identifier - A regular expression matching the source identifier values according to Source Identity configuration of the asset. If source identifier is not detected in traffic according to configuration, the value will be matched vs the source IP address.

      • Source IP - A network IP address in X.X.X.X format or CIDR (e.g. 11.22.33.44/24).

  • Limit configuration:

    • Limit - the maximum number of requests in a specific time scope.

    • Time Unit - the time scope in which the limit is enforced.

If Limit is set to 7000 and Unit is set to "Minute" then an Active Rate Limit practice will prevent requests to the matched URI if they exceed 7000 requests from the same source identifier, in a single minute.

  • Trigger configuration: Configure the trigger (usually the log trigger) that will activate when a Rate Limit rule is fully matched by URI as well as requests rate.

    In Detect/Learn mode, the Trigger is the only action that will occur if the rate of matched URIs from the same source identifier has exceeded configured limits.

After clicking OK, you will see the full rule:

Match priority - The rate is enforced according to a single matched rule. When the URI of the request matches multiple URIs in multiple rules, the longest match takes precedence and determines the rate limit count.

Example - if there are 2 rules - one limiting the URI "/docs" for 10000 requests from the same source identifier in one minute, and the second limiting "/docs/external" for 3000 requests from the same source identifier in one minute, then requests to /docs/external/latest will be blocked if they exceed 3000 requests from the same source identifier in one minute, as this rule creates a longer match.

Step 4: Enforce Policy

Click Enforce on the top banner of the Infinity Portal.

Advanced option in CloudGuard WAF's AppSec Gateways - Limit only according to IP addresses

To configure rate limit using this enforcement method, go to your CloudGuard WAF AppSec Gateway profile in Policy->Profiles and open the Advanced tab. In the Advanced Settings table add the following key-value: agent.rpmanager.enableNginxRateLimit : true

Click "Enforce Policy".

CloudGuard WAF's deployments provide a Check Point-managed reverse proxy as part of the deployment. It is possible to configure a CloudGuard WAF AppSec Gateway to enforce rate limit by using the reverse proxy settings. As the Reverse Proxy server does not have access to the agent's parsing capabilities, the rate limit in this case is done only using source IP addresses as the key to count requests.

AppSec Gateway