用户已在Azure存储帐户上分配了具有以下操作的自定义角色,但用户看到This request is not authorized to perform this operation
:
{
"id": ..,
"properties": {
"roleName": "ContributorBPMD(custom)",
"description": ..
"assignableScopes": [
"/providers/Microsoft.Management/managementGroups/XXX"
],
"permissions": [
{
"actions": [
"*"
],
"notActions": [
"notActions": [
...
"Microsoft.Sql/servers/virtualNetworkRules/write",
"Microsoft.Storage/storageAccounts/delete",
"Microsoft.Storage/locations/deleteVirtualNetworkOrSubnets/action",
"Microsoft.Storage/storageAccounts/privateEndpointConnections/delete",
"Microsoft.Storage/storageAccounts/privateEndpointConnections/write",
...
],
"dataActions": [],
"notDataActions": []
}
]
}
}
字符串
我没有看到Microsoft.storageAccounts/queueServices/*
的任何不允许的操作。缺少什么?
1条答案
按热度按时间nwo49xxi1#
用户得到此错误的原因是因为从队列阅读是一个数据平面操作,并且在自定义角色的
dataActions
中没有定义权限。解决此问题的最简单方法是将
Storage Queue Data Reader
角色分配给用户,或者在自定义角色的dataActions
中添加"Microsoft.Storage/storageAccounts/queueServices/queues/messages/read"
权限。