Advanced Permissions and Accounts Flashcards

1
Q

STS generates these when the sts:AssumeRole API call is made

A

Temporary credentials

How well did you know this?
1
Not at all
2
3
4
5
Perfectly
2
Q

STS credentials are similar to secret/access keys except for these 2 thigns

A

Don’t below to the identity that assumes the role (unlike IAM user)

Temporay (they expire)

How well did you know this?
1
Not at all
2
3
4
5
Perfectly
3
Q

The trust policy on a role defines this

A

Who is allowed to assume the role

How well did you know this?
1
Not at all
2
3
4
5
Perfectly
4
Q

The permissions policy on a role defines this

A

The AWS services and actions the role gives access to

How well did you know this?
1
Not at all
2
3
4
5
Perfectly
5
Q

STS creds includ these 4 items

A

AccessKeyId -unique identifier

Expiration

SecretAccessKey - Used to sign requests

Session Token - unique token that must come along with all requests.

How well did you know this?
1
Not at all
2
3
4
5
Perfectly
6
Q

sts:AssumeRole* calls are made by existing identities of either one of these two types

A

AWS Identity

External(Federation) Identity

How well did you know this?
1
Not at all
2
3
4
5
Perfectly
7
Q

Are roles meant to have complex logic determining who gets what set of permissions?

A

No, a role gives a set of permissions to anyone who is enabled to assume in the trust policy. Different set of permissions implies a different role is needed.

How well did you know this?
1
Not at all
2
3
4
5
Perfectly
8
Q

If you knew of a crediential leak for a role, why wouldn’t you remove all permissions of that role or just delete the role outright?

A

There may be other users who assume the role that still need the access.

How well did you know this?
1
Not at all
2
3
4
5
Perfectly
9
Q

If you knew of a credential leak for a role, why would you not change the trust policy for the role to limit the access?

A

The malicous user already has valid credentials (Access key, secret key, token) to assume the role. In essence, the cat is already out of the bag.

How well did you know this?
1
Not at all
2
3
4
5
Perfectly
10
Q

Can you manually invalidate temporary credentials like roles?

A

No, but you can update the role permissions policy with an inline DENY of AWSRevokeOlderSessions for any sessions older than now. Valid users will be forced to re authenticate, bad actor will be SOL.

How well did you know this?
1
Not at all
2
3
4
5
Perfectly
11
Q

When does the session token come into play for AWS creds?

A

Any temporary credentials

How well did you know this?
1
Not at all
2
3
4
5
Perfectly
12
Q

First step in interpreting a policy doc?

A

Identify the number of Statement block {Effect:…..}

How well did you know this?
1
Not at all
2
3
4
5
Perfectly
13
Q

What implicit permissions exist if nothing is defined?

A

Nothing. Said another way, implicit deny

How well did you know this?
1
Not at all
2
3
4
5
Perfectly
14
Q

What always takes precident in AWS?

A

Deny permission

How well did you know this?
1
Not at all
2
3
4
5
Perfectly
15
Q

When looking a Resource in a policy statement detailing with S3, what does /* represent?

A

Sub-objects, not the bucket itself

How well did you know this?
1
Not at all
2
3
4
5
Perfectly
16
Q

Why is it unlikely that you will find a policy with only a deny statement?

A

By default, everything is denied anway.

How well did you know this?
1
Not at all
2
3
4
5
Perfectly
17
Q

What S3 actions require a * resource?

A

ListAllMyBuckets

GetBucketLocation

CreateBucket

How well did you know this?
1
Not at all
2
3
4
5
Perfectly
18
Q

Only these types of permissions are impacted by Permissions Boundaries

A

Identity permissions (any resource policies are applied in full)

How well did you know this?
1
Not at all
2
3
4
5
Perfectly
19
Q

Permissions Boundaries can only be applied to these two things

A

IAM Users

IAM Roles

How well did you know this?
1
Not at all
2
3
4
5
Perfectly
20
Q

Do permissions boundaries grant access on their own?

A

No, they define maximum permissions an identity can have.

How well did you know this?
1
Not at all
2
3
4
5
Perfectly
21
Q

Common Variables to use in IAM

A

aws: CurrentTime This can be used for conditions that check the date and time.
aws: EpochTime This is the date in epoch or Unix time, for use with date/time conditions.
aws: TokenIssueTime This is the date and time that temporary security credentials were issued and can be used with date/time conditions. Note: This key is only available in requests that are signed using temporary security credentials. For more information about temporary security credentials, see Temporary security credentials in IAM.
aws: PrincipalType This value indicates whether the principal is an account, user, federated, or assumed role—see the explanation that follows later.
aws: SecureTransport This is a Boolean value that represents whether the request was sent using SSL.
aws: SourceIp This is the requester’s IP address, for use with IP address conditions. Refer to IP address condition operators for information about when SourceIp is valid and when you should use a VPC-specific key instead.
aws: UserAgent This value is a string that contains information about the requester’s client application. This string is generated by the client and can be unreliable. You can only use this context key from the AWS CLI.
aws: userid This value is the unique ID for the current user—see the chart that follows.
aws: username This is a string containing the friendly name of the current user—see the chart that follows.
ec2: SourceInstanceARN This is the Amazon Resource Name (ARN) of the Amazon EC2 instance from which the request is made. This key is present only when the request comes from an Amazon EC2 instance using an IAM role associated with an EC2 instance profile.

How well did you know this?
1
Not at all
2
3
4
5
Perfectly
22
Q

What to things have to happen for an entity in Account A to access something in Account B?

A

Account A has to allow the access out, account B has to allow the access to the resource.

How well did you know this?
1
Not at all
2
3
4
5
Perfectly
23
Q

If an SCP is in place, what happens if an incoming action is not allowed?

A

Implicitly denied

How well did you know this?
1
Not at all
2
3
4
5
Perfectly
24
Q

Six checkpoints of resource access

A

Explict Deny

SCPs

Resource Policies (if access granted here, stop processing)

Permission Boundaries

Session Policies (for IAM Roles)

Identity Policies

How well did you know this?
1
Not at all
2
3
4
5
Perfectly
25
Q

What is the S3 Canonical ID?

A

Legacy ID used in ACLs

How well did you know this?
1
Not at all
2
3
4
5
Perfectly
26
Q

What level do you define in the trust relationship of a role?

A

The account level that you will permit to use the role.

How well did you know this?
1
Not at all
2
3
4
5
Perfectly
27
Q

There levels of an AWS Org that SCPs can be attached to

A

Root level of the org (entire)

1 to many OUs

Individual account level

How well did you know this?
1
Not at all
2
3
4
5
Perfectly
28
Q

IN an AWS organization, how to you apply an SCP so it impacts the root AWS account/management account?

A

You cannot. It is special.

How well did you know this?
1
Not at all
2
3
4
5
Perfectly
29
Q

Do SCPs grant permissions?

A

No, they are account level permissions boundaries. They limit what can be done in an AWS account, not grant access.

How well did you know this?
1
Not at all
2
3
4
5
Perfectly
30
Q

Can you limit what the root account in an AWS account can do?

A

Not exactly, but you can use SCP’s to limit what can be done in an AWS account, inherintly limiting what the root account can do.

How well did you know this?
1
Not at all
2
3
4
5
Perfectly
31
Q

What is the default SCP setting when enabled?

A

Allow *. If you didn’t do this, the default implicit deny would apply at the SCP level, and there would be no access.

How well did you know this?
1
Not at all
2
3
4
5
Perfectly
32
Q

From an SCP perspective, how do you 1) implement a deny list approach 2)implement an allow list approach and 3) why

A

1) Keep the default allow *, use deny statements for services you want to block
2) Remove the default allow, add allow statements for services you want
3) 1 is easier admin overhead

How well did you know this?
1
Not at all
2
3
4
5
Perfectly
33
Q

Can you apply an S3 ACL to multiple objects?

A

No, each object needs an ACL (no inheritance)

How well did you know this?
1
Not at all
2
3
4
5
Perfectly
34
Q

In S3, who becomes the object owner of an S3 object?

A

The source account of the thing uploading the object

How well did you know this?
1
Not at all
2
3
4
5
Perfectly
35
Q

Using ACLs and S3 in a cross account scenario does the destination account get access by default to the object uploaded by the souce?

A

No, this is a limitation of ACLs. Destination bucket account will only have access if the source entity granted access.

How well did you know this?
1
Not at all
2
3
4
5
Perfectly
36
Q

Why might you choose to use Cross Account Roles when granting an external party access to store objects in S3?

A

That way the object owner of the S3 objects will be your account.

How well did you know this?
1
Not at all
2
3
4
5
Perfectly
37
Q

Regarding a trust policy in an IAM Role, do you put in a user or the root AWS account user of who will be assuming?

A

Root:

{
“Version”: “2012-10-17”,
“Statement”: [
{
“Effect”: “Allow”,
“Principal”: {
“AWS”: “arn:aws:iam::639767416172:root”
},
“Action”: “sts:AssumeRole”
}
]
}

38
Q

RAM, or Resource Access Manager, allows for sharing of AWS assets between other AWS Principles. What three types of things fall into the principles definition?

A

Accounts, OUs, and Orgs.

39
Q

What is the per hour charge for RAM?

A

Nothing, it is free, aside from the cost of the service you are using.

40
Q

While availability zone names are not consistent across different accounts, what identified is?

A

AZ IDs (use1-az1, use1-az2, etc)

41
Q

Once an asset is shared with RAM, which entities have full control?

A

Only the owner

42
Q

Is RAM bi?

A

No, the owner creates and names the share.

43
Q

If a priniciple is inside an ORG with sharing enabled, this is the default behavior for accesses shared by RAM

A

auto accept

44
Q

For non org account, or for AWS orgs where sharing is not enabled, this is the default behavior for RAM invites

A

Have to be accepted by the priniciple of the destination

45
Q

If a VPC is shared with RAM to another member account (participant), can you refenence security groups and see network assets (subnets, VPCs)?

A

Yes, can’t change network layer tho. And if the owner was to provision EC2 instances in the shared subnet, participant account wouldn’t see EC2 instances.

46
Q

If you provision an EC2 instance into a subnet that is shared with you via RAM, who is the owner of those assets?

A

The provisioning account retains ownership

47
Q

SCP inherit…

A

down the chain

48
Q

Name a service level quota that can’t be changed

A

IAM (5000 users)

49
Q

Each AWS service have this per region

A

quota

50
Q

Service Quota Dashboard

A

sweeet interface in the console giving visibility, can also request quota increases here. Can also create CloudWatch alarms from here! Service Quota console is preferred over legacy support ticket. CLI is also available. Can also set up Org template that will get submitted for new accounts.

51
Q

What is one cavaet to object owernship using S3 ACls?

A

There is a setting on the bucket that can be used to say everything created in the bucket with an ACL is owned by the account, or can allow other accounts to own. If you allow other accounts to own, you can choose between bucket owner owned or Object Writer owned.

52
Q

Do SCPs apply to external accounts?

A

SCPs affect only IAM users and roles that are managed by accounts that are part of the organization. SCPs don’t affect resource-based policies directly. They also don’t affect users or roles from accounts outside the organization.

53
Q

Cognito provides these three things for web/mobile apps

A

Authentication

Authorization

User management

54
Q

Cognito User Pool does two things

A

Allows Sign-In

Creates a JWT for you to use

55
Q

Do Cognito User pools grant access to anything?

A

No, they just manage sign in and creation of JWTs. Most AWS resources can’t use JWTs straight up, you need a translation layer.

56
Q

SOme things Cognito User Pools provides

A

Signup/Sign In

Cusomizable sign in web user interface

MFA and other security features

Can do signin from Facebook and others

57
Q

Primary purpose of identity pool

A

Exchange unauthenticated users or an external identity info for temporary AWS creds. Includes user pool identities, Facebook, SAML, and others.

58
Q

What services can you easily use with a JWT created from a successul Cognito User Pool login?

A

API Gateway can natively use the JWT and pass you through to Lambda

59
Q

Can you use an identity pool with a user pool?

A

Yes, you can create an identity pool config to support external user repositories. The result though is that you now have to have a config for each different kind of token you will get from the external identity provider.

60
Q

Benefit of using user pools integrated with external identitiy providers?

A

You will get a user pool JWT back, and then you can have a standard way to configure your identity pool to swap for creds (role for authenticated users and role for unauthenticated)

61
Q

If you are setting up a real application to use a third party provider like Google to authenticate, what is likely needed?

A

Registering your app with the provider to know about it.

62
Q

Once you complete and Identity Pool, what do you need to do to ensure proper access?

A

Go to IAM, configure the unauthenticated and authenticated access for the roles.

63
Q

Key benefit of Workspaces

A

Access a desktop from anywhere maintaining apps and state

64
Q

Key requirement for using Workspaces?

A

Implementation of a Directory Services product: Simple, Managed AD, or AD Connector

65
Q

How do Workspaces handle networking?

A

ENI in a networking VPC

You can use VPN or DX to get back to on-prem resources

66
Q

Does Workspaces provide encryption at rest?

A

Yes. EBS +KMS. You can encrypt both root and user volumes, one of them, or none of them.

67
Q

What are authentication and streaming gateways in Workspace?

A

The proxy if you will for external people connecting to the Workspaces. Talk to Directory Services to let people in.

68
Q

Do workspaces run in your VPC?

A

No, they run in an AWS hosted VPC. They are injected into your networking VPC as are your directory services. Relize this means SG’s come into play for direct ingress access.

69
Q

Are Workspaces HA?

A

No, they run in one AZ and are susceptable to AZ outages. You can distribute WOrkspaces across AZs, but each Workspace is susceptable to AZ outage.

70
Q

Does the Directoy Services - Managed Microsoft AD suport schema updates/exentions?

A

Yes, means you can install things like Exchange, Sharepoint, etc.

71
Q

What types of trusts does Directory Services - Microsoft AD support?

A

All of them, one way and two way.

72
Q

Is the Directory Services - Microsoft Ad HA?

A

Yes, minimum of two AZ with a DC in each.

73
Q

MFA Directory Service - Microsoft AD supports?

A

RADIUS-based MFA

74
Q

Best choice for > 5000 users, trust relationships between your on prem diretory?

A

Directory Services - Microsoft AD

75
Q

Can Directory Services -Managed AD support AWS services?

A

Yes, things like the Console, Workspaces, Connect, Chime, etc.

76
Q

Does Directory Services - Microsoft AD run in your VPC?

A

No, runs in an AWS VPC, but is injected into your VPC via ENIs for the AD DCs. Becuase of this, there are SGs you need to be awaare of and configure.

77
Q

Do you need to patch AD in Directory Services - Managed AD?

A

No, AWS handles.

78
Q

Can you use multiple Directory Service - AD Connectors for resiliency?

A

Yes

79
Q

What does Directory Services - AD connector need from a networking perspective?

A

2 subnets in a VPC

Networking connectivity via VPN/DX to on prem AD.

Injects ENI’s into your VPC

80
Q

What does Directory Services -AD connector give you for sizing options?

A

Small or larger

81
Q

Where can you attach SCPs

A

ORG root container, ous, individual accounts

82
Q

Do SCPs apply to the root management AWS account?

A

no

83
Q

Role trust policy enabling all users of an account

A

“Version”: “2012-10-17”, “Statement”: [{ “Effect”: “Allow”, “Principal”: { “AWS”: “arn:aws:iam::111122223333:root” }, “Action”: “sts:AssumeRole” }] }

84
Q

Product formerly known as AWS SSO

A

IAM Identity Center

85
Q

The region in which Control Tower Landing Zone is deployed into is called this

A

Home Region

86
Q

Key services Control Tower uses to build an LZ

A

Service Catalog

Cloudformation

AWS Config

IAM Identity Center (AWS SSO)

87
Q

Default Control Tower OUs

A

Security

Sandbox

88
Q

Function of Security OU Sandbox in Control Tower

A

Log Archive and Audit Accounts (CloudTrail and Config Logs)

89
Q

Control Tower Guardrail Types

A

Mandatory

Strongly Recommended

Elective

90
Q

Preventative Guard Rail in CT

A

Stop you from doing things (SCPs). Enforced or not enabled. Used to block regions, disallow bucket changes, etc

91
Q

Detective Guardrail in CT

A

Compliance checks via AWS Config

92
Q

Control Tower Account Factory Benefits

A

Guardrails automatically added

Admins or users can be self serve

User can be automatically given admin to account

Can apply standard network configuration

Accounts can be closed or repurposed