Crates.io | scratchstack-aws-principal |
lib.rs | scratchstack-aws-principal |
version | 0.3.4 |
source | src |
created_at | 2021-04-24 23:05:45.534014 |
updated_at | 2024-07-13 19:16:57.430595 |
description | Principal types for AWS/AWS-like services |
homepage | https://github.com/dacut/scratchstack-aws-principal |
repository | https://github.com/dacut/scratchstack-aws-principal |
max_upload_size | |
id | 389101 |
size | 143,867 |
Principals for AWS and AWS-like services.
Principals come in two "flavors": actors and policies. A policy-based prinicpal can be completely specified via
an ARN in an Identity and Access Management (IAM) Aspen policy, e.g.,
arn:aws:iam::123456789012:user/Sales/Bob
. This is what most people think of when they refer to principals
when talking about AWS. In this example:
aws
(the AWS commercial cloud);123456789012
./Sales/
.Bob
.On the service implementation side, however, there are additional details attached to a principal actor. Groups,
roles, and users have a
universally unique ID.
If the /Sales/Bob
user is deleted and another is created, these users will have the same ARN but different unique
IDs. While not part of the principal itself, this can be referred to in Aspen policies via the
\${aws:username}
policy
variable. Assumed roles carry a token issue time, access via the \${aws:TokenIssueTime}
variable, as well as
an expiration time on or after which the assumed role is no longer valid.