• Native OpenStack API

noa
  1. Help Center
  2. Native OpenStack API
  3. API Reference
  4. Neutron
  5. Firewall
  6. Updating a Firewall Rule

Updating a Firewall Rule

Function

This interface is used to update a firewall rule.

URI

PUT /v2.0/fwaas/firewall_rules/{firewall_rule_id}

Request Message

Table 1 Request parameter

Parameter

Type

Mandatory

Description

firewall_rule

Dict

Yes

Specifies the firewall rule. For details, see Table 1.

This parameter has no mandatory fields.

Response Message

Table 2 Response parameter

Parameter

Type

Description

firewall_rule

Dict

Specifies the firewall rule. For details, see Table 1.

Example:

Example request

PUT /v2.0/fwaas/firewall_rules/b94acf06-efc2-485d-ba67-a61acf2a7e28
{
    "firewall_rule": {
        "action": "deny"
    }
}

Example response

{
    "firewall_rule": {
        "protocol": "tcp", 
        "description": "", 
        "source_ip_address": null, 
        "destination_ip_address": null, 
        "source_port": null, 
        "destination_port": "80", 
        "id": "b94acf06-efc2-485d-ba67-a61acf2a7e28", 
        "name": "ALLOW_HTTP", 
        "tenant_id": "23c8a121505047b6869edf39f3062712", 
        "enabled": true, 
        "action": "deny", 
        "ip_version": 4, 
        "public": false,
        "project_id": "23c8a121505047b6869edf39f3062712"
    }
}

Status Codes

For details, see section Status Codes.