Kong · Schema

JsonThreatProtectionPluginConfig

API GatewayAI GatewayAI ConnectivityAgent GatewayEvent GatewayMCP RegistryService MeshLLMKafkaKonnectOpen Source

Properties

Name Type Description
config object
name object
protocols array A set of strings representing HTTP protocols.
route object If set, the plugin will only activate when receiving requests via the specified route. Leave unset for the plugin to activate regardless of the route being used.
service object If set, the plugin will only activate when receiving requests via one of the routes belonging to the specified Service. Leave unset for the plugin to activate regardless of the Service being matched.
View JSON Schema on GitHub

JSON Schema

kong-jsonthreatprotectionpluginconfig-schema.json Raw ↑
{
  "$schema": "https://json-schema.org/draft/2020-12/schema",
  "$id": "#/components/schemas/JsonThreatProtectionPluginConfig",
  "title": "JsonThreatProtectionPluginConfig",
  "x-speakeasy-entity": "PluginJsonThreatProtection",
  "properties": {
    "config": {
      "type": "object",
      "properties": {
        "allow_duplicate_object_entry_name": {
          "description": "Allow or disallow duplicate object entry name.",
          "type": "boolean",
          "default": true
        },
        "allow_non_json_requests": {
          "description": "Allow non-json requests to bypass the rules",
          "type": "boolean",
          "default": false
        },
        "enforcement_mode": {
          "description": "Enforcement mode of the security policy.",
          "type": "string",
          "default": "block",
          "enum": [
            "block",
            "log_only"
          ]
        },
        "error_message": {
          "description": "The response message when validation fails",
          "type": "string",
          "default": "Bad Request"
        },
        "error_status_code": {
          "description": "The response status code when validation fails.",
          "type": "integer",
          "default": 400,
          "maximum": 499,
          "minimum": 400
        },
        "max_array_element_count": {
          "description": "Max number of elements in an array. -1 means unlimited.",
          "type": "integer",
          "default": -1,
          "maximum": 2147483648,
          "minimum": -1
        },
        "max_body_size": {
          "description": "Max size of the request body. -1 means unlimited.",
          "type": "integer",
          "default": 8192,
          "maximum": 2147483648,
          "minimum": -1
        },
        "max_container_depth": {
          "description": "Max nested depth of objects and arrays. -1 means unlimited.",
          "type": "integer",
          "default": -1,
          "maximum": 2147483648,
          "minimum": -1
        },
        "max_object_entry_count": {
          "description": "Max number of entries in an object. -1 means unlimited.",
          "type": "integer",
          "default": -1,
          "maximum": 2147483648,
          "minimum": -1
        },
        "max_object_entry_name_length": {
          "description": "Max string length of object name. -1 means unlimited.",
          "type": "integer",
          "default": -1,
          "maximum": 2147483648,
          "minimum": -1
        },
        "max_string_value_length": {
          "description": "Max string value length. -1 means unlimited.",
          "type": "integer",
          "default": -1,
          "maximum": 2147483648,
          "minimum": -1
        }
      }
    },
    "name": {
      "const": "json-threat-protection"
    },
    "protocols": {
      "description": "A set of strings representing HTTP protocols.",
      "type": "array",
      "items": {
        "enum": [
          "grpc",
          "grpcs",
          "http",
          "https"
        ],
        "type": "string"
      },
      "format": "set",
      "default": [
        "grpc",
        "grpcs",
        "http",
        "https"
      ]
    },
    "route": {
      "description": "If set, the plugin will only activate when receiving requests via the specified route. Leave unset for the plugin to activate regardless of the route being used.",
      "type": "object",
      "additionalProperties": false,
      "properties": {
        "id": {
          "type": "string"
        }
      }
    },
    "service": {
      "description": "If set, the plugin will only activate when receiving requests via one of the routes belonging to the specified Service. Leave unset for the plugin to activate regardless of the Service being matched.",
      "type": "object",
      "additionalProperties": false,
      "properties": {
        "id": {
          "type": "string"
        }
      }
    }
  }
}