在 Snowball Edge Amazon Security Token Service 上使用 - Amazon Snowball Edge 开发者指南
Amazon Web Services 文档中描述的 Amazon Web Services 服务或功能可能因区域而异。要查看适用于中国区域的差异,请参阅 中国的 Amazon Web Services 服务入门 (PDF)

本文属于机器翻译版本。若本译文内容与英语原文存在差异,则一律以英文原文为准。

在 Snowball Edge Amazon Security Token Service 上使用

Amazon Security Token Service (Amazon STS) 可帮助您为 IAM 用户申请临时的有限权限证书。

重要

要使 Amazon 服务在 Snowball Edge 上正常运行,必须允许服务使用端口。有关更多信息,请参阅 Snowball Edge 上 Amazon 服务的端口要求

在 Snowball Edge 上使用 Amazon CLI 和 API 操作

使用 Amazon CLI 或 API 操作在 Snowball Edge 设备上发出 IAM Amazon STS、、Amazon S3 和 Amazon EC2 命令时,必须将指定region为 “。” snow 您可以使用命令本身Amazon configure或在命令本身内执行此操作,如以下示例所示。

aws configure --profile snowballEdge Amazon Access Key ID [None]: defgh Amazon Secret Access Key [None]: 1234567 Default region name [None]: snow Default output format [None]: json

aws iam list-users --endpoint http://192.0.2.0:6078 --region snow --profile snowballEdge
注意

本地使用的访问密钥 ID 和访问机密密钥 Amazon Snowball Edge 不能与中的密钥互换。 Amazon Web Services 云

Snowball Edge 上支持的 Amazon STSAmazon CLI 命令

在本地仅支持 assume-role 命令。

对于 assume-role,支持以下参数:

  • role-arn

  • role-session-name

  • duration-seconds

在 Snowball Edge 上扮演角色的命令示例

要代入角色,请使用以下命令。

aws sts assume-role --role-arn "arn:aws:iam::123456789012:role/example-role" --role-session-name AWSCLI-Session --endpoint http://snow-device-IP-address:7078

有关使用 assume-role 命令的更多信息,请参阅如何使用 Amazon CLI代入 IAM 角色?

有关使用的更多信息 Amazon STS,请参阅 IAM 用户指南中的使用临时安全证书

Snowball Edge 上支持的 Amazon STS API 操作

本地仅支持 AssumeRoleAPI。

对于 AssumeRole,支持以下参数:

  • RoleArn

  • RoleSessionName

  • DurationSeconds

例 代入角色
https://sts.amazonaws.com/ ?Version=2011-06-15 &Action=AssumeRole &RoleSessionName=session-example &RoleArn=arn:aws:iam::123456789012:role/demo &DurationSeconds=3600