セキュリティグループのインバウンドルールを作成します。この操作により、他のデバイスからセキュリティグループ内のインスタンスへのインバウンドトラフィックを許可または拒否します。
今すぐお試しください
テスト
RAM 認証
|
アクション |
アクセスレベル |
リソースタイプ |
条件キー |
依存アクション |
|
ens:AuthorizeSecurityGroup |
update |
*All Resource
|
なし | なし |
リクエストパラメーター
|
パラメーター |
型 |
必須 / 任意 |
説明 |
例 |
| IpProtocol |
string |
必須 |
トランスポート層プロトコル。このパラメーターの値では大文字と小文字が区別されます。有効な値:
|
all |
| PortRange |
string |
必須 |
セキュリティグループルール N のトランスポート層プロトコルに対応する宛先ポートの範囲。有効な値:
|
22/22 |
| SecurityGroupId |
string |
必須 |
セキュリティグループの ID。 |
sg-bp67acfmxazb4ph*** |
| Policy |
string |
任意 |
インバウンドアクセスを許可するかどうかを決定するセキュリティグループルール N の操作。有効な値:
デフォルト値:accept。 |
accept |
| Priority |
integer |
任意 |
セキュリティグループルール N の優先度。有効な値:1~100。 デフォルト値:1。 |
1 |
| SourceCidrIp |
string |
必須 |
ソース IPv4 CIDR ブロック。CIDR ブロックと IPv4 アドレスがサポートされています。 このパラメーターはデフォルトで空です。 |
10.0.XX.XX/8 |
| SourcePortRange |
string |
任意 |
ソースセキュリティグループのトランスポート層プロトコルに対応するポート番号の範囲。有効な値:
|
22/22 |
レスポンスフィールド
|
フィールド |
型 |
説明 |
例 |
|
object |
|||
| RequestId |
string |
リクエスト ID。 |
473469C7-AA6F-4DC5-B3DB-A3DC0DE3C83E |
例
成功レスポンス
JSONJSON
{
"RequestId": "473469C7-AA6F-4DC5-B3DB-A3DC0DE3C83E"
}
エラーコード
|
HTTP ステータスコード |
エラーコード |
エラーメッセージ |
説明 |
|---|---|---|---|
| 400 | MissingParameter | The input parameter that is mandatory for processing this request is not supplied. | |
| 400 | NoPermission | Permission denied. | |
| 400 | InvalidParameter.%s | The specified field %s invalid. Please check it again. | |
| 400 | InvalidParameter | The errorMessage is %s. Please check it again. | |
| 400 | InvalidSecurityGroupId.NotFound | The specified SecurityGroupId does not exist. | |
| 400 | SecurityGroupRuleConflict.Duplicated | The SecurityGroup rule already exists. | |
| 400 | AuthorizationLimitExceed | The limit of authorization records in the security group reaches. | |
| 400 | ens.interface.error | An error occurred while calling the API. | |
| 400 | CallInterface | Call Interface Happen Error. |
完全なリストについては、「エラーコード」をご参照ください。
変更履歴
完全なリストについては、「変更履歴」をご参照ください。