フィルタリングルール一括設定
API情報
| API種別 | メソッド | URI | 対象 | 名称 | 実行 |
|---|---|---|---|---|---|
| 設定 | PUT | /:GisServiceCode/fw-lbs/:IflServiceCode/filters/:IpVersion/:Direction.json | FW+LB | フィルタリングルール一括設定 | 同期 |
- フィルタリングルールを一括設定する。フィルタリングルールは一つずつ設定することはできません。
リクエストパラメータ
| パラメータ | 必須 | 意味 | 値 | |
|---|---|---|---|---|
| URL | GisServiceCode | ○ | P2契約のサービスコード | gis######## |
| IflServiceCode | ○ | FW+LB 専有タイプのサービスコード | ifl######## | |
| IpVersion | ○ | IPv4ルールかIPv6ルール | "v4" "v6" | |
| Direction | ○ | 入力方向(ExternalからInternalへ)のルールか出力方向のルールか。IPv6は"in"のみ指定可能 | "in" "out" | |
| ボディ | FilterRuleList | ○ | フィルタリングルール情報 | オブジェクトの配列 |
| SourceNetwork | ○ | ソースネットワーク | IPアドレス/マスク長 "ANY" | |
| DestinationNetwork | ○ | デスティネーションネットワーク | IPアドレス/マスク長 "ANY" | |
| DestinationPort | ○ | デスティネーションポート番号 | 数字 | |
| Protocol | ○ | プロトコル | "TCP" "UDP" | |
| Action | ○ | ルールにマッチしたパケットに対する処理 | "ACCEPT"(許可) "DROP"(破棄) "REJECT"(拒否) | |
| Label | ○ | ラベル | 文字列 |
レスポンス
| フィールド | タイプ | 意味 | 値 |
|---|---|---|---|
| Current.FilterList | Array | 設定したフィルタリングルール | オブジェクトの配列 |
| Previous.FilterList | Array | 設定前のフィルタリングルール | オブジェクトの配列 |
| FilterId | String | フィルタID | v4_番号 v6_番号 |
| SourceNetwork | String | ソースネットワーク | IPアドレス/マスク長 "ANY" |
| DestinationNetwork | String | デスティネーションネットワーク | IPアドレス/マスク長 "ANY" |
| DestinationPort | String | デスティネーションポート番号 | 数字 "ANY" |
| Protocol | String | プロトコル | "TCP" "UDP" |
| Action | String | ルールにマッチしたパケットに対する処理 | "ACCEPT"(許可) "DROP"(破棄) "REJECT"(拒否) |
| Label | String | ラベル | 文字列 |
制限
- 特になし
サンプル
リクエストボディ
{
"FilterRuleList": [
{
"SourceNetwork": "192.168.10.0/24",
"DestinationNetwork": "ANY",
"DestinationPort": "80",
"Protocol": "TCP",
"Action": "ACCEPT",
"Label": "From Segment C"
},
{
"SourceNetwork": "192.168.20.1",
"DestinationNetwork": "ANY",
"DestinationPort": "80",
"Protocol": "TCP",
"Action": "ACCEPT",
"Label": "From Host D"
},
...
]
}
レスポンス (JSON)
{
"RequestId": "xxxxxxxx-xxxxxxxx-xxxxxxxx-xxxxxxxx-xxxxxxxx",
"Current": {
"FilterList": [
{
"FilterId": "v4_133",
"SourceNetwork": "192.168.10.0/24",
"DestinationNetwork": "ANY",
"DestinationPort": "80",
"Protocol": "TCP",
"Action": "ACCEPT",
"Label": "From Segment C"
},
{
"FilterId": "v4_134",
"SourceNetwork": "192.168.20.1",
"DestinationNetwork": "ANY",
"DestinationPort": "80",
"Protocol": "TCP",
"Action": "ACCEPT",
"Label": "From Host D"
},
...
]
},
"Previous": {
"FilterList": [
{
"Id": "v4_121",
"SourceNetwork": "192.168.100.0/24",
"DestinationNetwork": "ANY",
"DestinationPort": "80",
"Protocol": "TCP",
"Action": "ACCEPT",
"Label": "From Segment A"
},
{
"Id": "v4_124",
"SourceNetwork": "192.168.200.11",
"DestinationNetwork": "ANY",
"DestinationPort": "80",
"Protocol": "TCP",
"Action": "ACCEPT",
"Label": "From Host B"
},
...
]
}
}