Rulesets API

This guide is for the Rulesets API, used to control your WAF IP and WAF ID based rulesets. Please see the API overview for information on using the Nova API.


Examples

List Rules

This will return a list of your certificates, but not the certificate itself.

Variables

Method: GET
Endpoint: /api/rulesets/{what}

Variables:
 - what: ips|waf-rules

Response

{
    "success": true,
    "data": {
        "allowed": [
            "192.168.99.0/24",
            "192.168.10.53/32"
        ],
        "blocked": [
            "127.0.0.99",
            "127.0.0.100"
        ]
    }
}

Add an IP

Add an IP to either the allowed or blocked IP list.

Variables

Method: POST
Endpoint: /api/rulesets/addIp

Variables: 
 - type: allowed|blocked
 - ip: IP or IP/CIDR

Response

{
    "success": true,
    "data": {
        "message": "The allowed list was updated to add 192.168.10.53/32"
    }
}

Remove an IP

Remove an IP from either the allowed or blocked IP list.

Variables

Method: POST
Endpoint: /api/rulesets/removeIp

Variables: 
 - type: allowed|blocked
 - ip: IP or IP/CIDR

Response

{
    "success": true,
    "data": {
        "message": "The allowed list was updated to remove 192.168.10.50/32"
    }
}