Add ModSecurity vendor rules

This function adds a new ModSecurity™ vendor rule set to the server.

Important:

When you disable the Web Server role, the system disables this function.

Authorizations:
query Parameters
url
required
string <url>

The YAML metadata that describes the vendor and how to obtain its rules.

Example: url=https://example.com/update/meta_MyVendor.yaml
enabled
integer
Default: 1

Whether to enable the vendor.

  • 1 — Enabled.
  • 0 — Disabled.
Enum: 1 0
Example: enabled=1

Responses

Response Schema: application/json
object
object

Request samples

whmapi1 --output=jsonpretty \
  modsec_add_vendor \
  url='https://example.com/update/meta_MyVendor.yaml'

Response samples

Content type
application/json
{
  • "data": {},
  • "metadata": {
    • "command": "modsec_add_vendor",
    • "reason": "OK",
    • "result": 1,
    • "version": 1
    }
}