繁体   English   中英

资源上的权限“cloudkms.cryptoKeyVersions.viewPublicKey”被拒绝,或者它可能不存在

[英]Permission 'cloudkms.cryptoKeyVersions.viewPublicKey' denied on resource or it may not exist

我正在使用 Google Cloud Functions 构建一个 http 端点,以授权使用 Google Cloud Key 的 Flow Blockchain 交易。 我有我的资源名称。 每当我编译代码或启动交易时,我都会遇到此错误。

使用 KMS 的代码如下所示:

 Permission 'cloudkms.cryptoKeyVersions.viewPublicKey' denied on resource 'projects/nftiket500/locations/us-east1/keyRings/nftiket50050/cryptoKeys/nftiket50050/cryptoKeyVersions/2' (or it may not exist)

该错误消息意味着您尝试访问的密钥不存在 - 或者更有可能 - 您没有授予 Cloud Function 正在运行的角色访问密钥的权限。 查看https://cloud.google.com/kms/docs/iam ,其中包含有关如何添加权限的说明。 https://cloud.google.com/kms/docs/reference/permissions-and-roles描述了所有可用的角色和权限。

暂无
暂无

声明:本站的技术帖子网页,遵循CC BY-SA 4.0协议,如果您需要转载,请注明本站网址或者原文地址。任何问题请咨询:yoyou2525@163.com.

 
粤ICP备18138465号  © 2020-2024 STACKOOM.COM