Insert firewall rule in firewall policy
Inserts a firewall rule in a firewall policy relative to the position of other rules.
URI
/v2.0/fw/firewall_policies/{firewall_policy-id}/insert_rule
HTTP method
PUT
Request parameter
Key | Description | Type | Required/optional |
---|---|---|---|
firewall_rule_id | uuid of firewall rule for insertion. | xsd:uuid | Required |
insert_after | Insert the specified firewall rule on firewall_rule_id after this rule. | xsd:uuid | Optional |
insert_before | Insert the specified firewall rule on firewall_rule_id before this rule. | xsd:uuid | Optional |
Example request
{
"firewall_rule_id": "7bc34b8c-8d3b-4ada-a9c8-1f4c11c65692",
"insert_after": "a08ef905-0ff6-4784-8374-175fffe7dade",
"insert_before": ""
}
Response status
Status code | Description |
---|---|
200 | Normal response codes |
Bad Request (400) | Error response codes Bad Request error is returned in the case the rule information is missing. |
Unauthorized (401) | Error response codes |
Not Found (404) | Error response codes |
Response body (normal status)
{
"audited": false,
"description": "",
"firewall_list": [],
"firewall_rules": [
"a08ef905-0ff6-4784-8374-175fffe7dade",
"7bc34b8c-8d3b-4ada-a9c8-1f4c11c65692",
"8722e0e0-9cc9-4490-9660-8c9a5732fbb0"
],
"id": "c69933c1-b472-44f9-8226-30dc4ffd454c",
"name": "test-policy",
"shared": false,
"tenant_id": "45977fa2dbd7482098dd68d0d8970117",
"availability_zone": "AZ1"
}
Description of response body (normal status)
Item | Description |
---|---|
audited | When set to True by the policy owner indicates that the firewall policy has been audited. This attribute is meant to aid in the firewall policy audit workflows. Each time the firewall policy or the associated firewall rules are changed, this attribute will be set to False and will have to be explicitly set to True through an update operation. |
description | Human readable description for the firewall policy (1024 character limit) |
firewall_list | The list of firewall uuid that associates with.this firewall policy These firewalls will implement the rules contained in this firewall policy. |
firewall_rules | This is an ordered list of firewall rule uuids. The firewall applies the rules in the order in which they appear in this list. |
id | Unique identifier for the firewall policy object. |
name | Human readable name for the firewall policy (255 character limit). Does not have to be unique. |
shared | Indicates whether this firewall rule is shared across all projects. This value is always False. |
tenant_id | Owner of the firewall policy. Only admin users can specify a project identifier other than their own. |
availability_zone | The Availability Zone name. |