介绍
这篇文章将为大家详细讲解有关如何查询一个安全组和其他哪些安全组有安全组级别的授权行为,文章内容质量较高,因此小编分享给大家做个参考,希望大家阅读完这篇文章后对相关知识有一定的了解。
DescribeSecurityGroupReferences
查询一个安全组和其他哪些安全组有安全组级别的授权行为。
调用该接口时,您需要注意:
授权行为包括入方向授权和出方向授权。
该接口单次最多返回100条记录。
当您无法删除某一安全组(DeleteSecurityGroup)时,可以调用该接口查看指定的安全组是否已被其他安全组授权。如果指定的安全组已被授权,您需要在删除该安全组之前解除授权行为。
<强>请求示例强>
https://ecs.aliyuncs.com/?Action=DescribeSecurityGroupReferences ,RegionId=cn-hangzhou ,SecurityGroupId.1=sg - 1133 aa ,& lt;公共请求参数在
<强>返回示例强>
<强> XML格式强>
& lt; DescribeSecurityGroupReferencesResponse> & lt; RequestId> CEF72CEB-54B6-4AE8-B225-F876FF7BA984 & lt; SecurityGroupReferences> & lt; SecurityGroupReference> & lt; SecurityGroupId> sg - 1133 aa & lt; ReferencingSecurityGroups> & lt; ReferencingSecurityGroup> & lt; SecurityGroupId> sg - 2255 cc & lt; AliUid> 123 & lt;/AliUid> & lt;/ReferencingSecurityGroup> & lt; ReferencingSecurityGroup> & lt; SecurityGroupId> sg - 2255 dd & lt; AliUid> 123 & lt;/AliUid> & lt;/ReferencingSecurityGroup> & lt;/ReferencingSecurityGroups> & lt;/SecurityGroupReference> & lt;/SecurityGroupReferences> & lt;/DescribeSecurityGroupReferencesResponse>
<强> JSON格式强>
{ “RequestId":“CEF72CEB-54B6-4AE8-B225-F876FF7BA984" “SecurityGroupReferences":( { “SecurityGroupId":“sg - 1133 aa" “SecurityReferencingGroups":( { “AliUid": 123, “SecurityGroupId":“sg - 2255 cc" }, { “AliUid": 123, “SecurityGroupId":“sg - 2255 dd" } ] } ] }
以下为本接口特有的错误码。更多错误码,请访问API错误中心。
关于如何查询一个安全组和其他哪些安全组有安全组级别的授权行为就分享到这里了,希望以上内容可以对大家有一定的帮助,可以学到更多知识。如果觉得文章不错,可以把它分享出去让更多的人看的到。