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
  • Overview
  • API Discovery and API Schema Validation
  • Terminology

Was this helpful?

  1. Additional Security Engines

API Protection

PreviousAnti-BotNextAPI Discovery

Last updated 1 year ago

Was this helpful?

Overview

CloudGuard WAF has strong capabilities to protect Web Servers from malicious attacks, whether those servers serve human customers via a Web Application or programmatic access via Web APIs.

When serving Web APIs for programmatic access the server exposes API for external use. Over time that API changes. New APIs are added, new versions of existing APIs are created, parameters within an existing API might be added as well and APIs can be deleted.

Best security is achieved when we:

  1. Allow traffic to reach the web server only if it matches an approved API with correct parameters.

  2. Are able to maintain the API schema - Review changes and allow only traffic for reviewed changes to pass, as well as prevent access to deleted/deprecated APIs.

  3. Approve which API usage can contain sensitive data, to prevent data leaks.

Given the life cycle of a web server, providing APIs to its users - as APIs are added, sometimes modified or deleted, sometimes very frequently - a security administrator needs a solution that will rise to challenge of not only approving a schema and enforcing it, but also comparing that schema to the actual usage to make sure there are no security holes, yet prevent connectivity issues.

API Discovery and API Schema Validation

The combination of the main two offerings of CloudGuard WAF provide the best API security:

  1. API discovery - Providing Security by Visibility. Providing a schema, as learned by the API discovery engine, and analysis of API usage. Periodic analysis of the findings allows the security administrator to keep up with the fast development process of the web server's APIs, while not compromising its security.

  2. API Schema Validation - Preventing traffic that does not conform with the approved schema for the Web API asset's APIs. The initial schema can be:

    1. API Discovery engine's schema (Recommended). This allows the schema to continue to be maintained and reviewed as additions will create new suggested schema versions to be approved by the security administrator. It is always possible to use API Discovery's schema as the basis and add on top of it, manual changes.

    2. An approved and maintained schema file created by your own development processes. API discovery can still be used to review suggested changes according to the traffic sent to the web server and passing through CloudGuard WAF's agent.

You can activate without using API Discovery, but it is not recommended.

Terminology

Endpoints

The Endpoint in REST APIs is the URI without the domain. i.e. "/api/my-assets" in "https://myapp.com/api/my-assets".

However, REST-based endpoint can contain "path parameters" which essentially combine different endpoints to a single one with the same meaning. For example, joining /api/my-assets/asset-id-4af4, and /api/my-assets/asset-id-8d2a into a single /api/my-assets/{asset-id} that represents all the potential APIs that have this format, have different asset IDs, yet serve the same purpose in terms of security configuration, and request body structure.

In GraphQL the endpoint is the function being called.

Methods

In REST APIs the method is the HTTP protocol method. i.e. GET, POST, PUT, etc.

When using GraphQL there are 2 main methods - query (indicating a read-only endpoint) and mutation.

APIs

An API is the combination of a method and an endpoint. i.e. POST /api/my-assets/{asset-id}.

An API can have additional query parameters with certain value formats, unique headers with certain value formats, and body with a specific structure - usually a JSON format.

The API's additional/optional query parameters, and the request body's structure, is learned as well the more usage of the same API is seen, and its accepted structure is also built as part of the schema.

The API Discovery engine looks at the requests alone for the purpose of building schemas. It will not learn the response body and will not create a schema that validates the traffic from the server, as the aim is to focus on traffic from the clients, and protecting the server.

The responses are inspected for their status code which discerns accepted APIs by the web server, from APIs it does not support, and for existence of sensitive data in them.

Sensitive Data

Sensitive Data types whose usage is detected by API discovery include:

  • UUIDs.

  • Emails.

  • Credit Card Numbers.

  • IP and MAC addresses.

  • Social Security Numbers.

  • Phone Numbers.

  • IBAN.

  • SSH Keys.

  • Certificates.

  • Vehicle Identification Numbers.

Schema Validation
API Discovery
Track API Discovery Learning
Enforce API Schema