S3 Flashcards
You have several S3 buckets in your application. Some data is stored in Parquet format while another bucket contains you VPC flow logs. What can you use to analyse this directly?
AWS Athena
Can S3 be considered as a database as well as storage?
Yes. S3 data can be queried directly with Athena so can be thought of as a database.
What AWS service can be used to mine S3 access logs?
Athena
Can you delete a file from an S3 bucket with MFA via the S3 console?
No. It must be deleted via the CLI
What are the 3 things that must be done to enable cross region replication in S3
- Versioning must be enabled at source
- Buckets must be in different regions
- IAM Permissions must be set for R.W
Why would you use a signed URL to access an S3 bucket?
So you can generate a URL which is valid for a limited time. This is used for ensuring that only authorised users have access to the bucket - i.e. for a premium video or content service for logged in users.
Can an S3 Bucket be accessed from instances within a VPC private subnet - i.e a subnet with no internet access
Yes. S3 supports VPC endpoints so buckets can be accessed from a private subnet with no internet access.
In S3, who is principal * ?
- is anyone
When setting up a static website in S3, what do you need to do?
You need to enable static hosting and you need to grant public access for getObject requests.
What is the function of Origin Access Identity?
OAI limits access to an S3 bucket to cloudfront only. This means that someone can’t access your S3 content from the open web.
For what requests in S3 do we get read after write consistency - what are the exceptions?
Read after write is for puts of new objects in S3. The exception is if we did a GET, and received a 404 before doing a PUT. This PUT will be eventually consistent.
What events result in eventual consistency?
PUTS and DELETES on existing objects.
What is the naming convention on S3 buckets?
Lowercase, no underscore, 3-63 chars, not an IP, must start with a lowercase letter or a number.
Where do you enable MFA delete for S3? In the bucket console, the IAM console or the CLI?
In the CLI - as the root user.
You need to upload a 5.7GB file to S3. What needs to be enabled?
Multipart upload must be enabled for file sizes > 5GB
Which policy takes precedent over the other - IAM or Bucket?
IAM policies will take precedent over bucket policies. If the IAM policy has a DENY for writing an object to a bucket - this will override an ALLOW on the bucket policy.
In S3 Glacier, what is each item referred to as, where are these stored and what is the max size?
Objects are referenced to as Archives. They are stored in vaults and each archive can be 40TB
Can you change the ownership of replicated objects or the storage class for replicated objects for the target in cross region replication?
Yes to both
If you looked at an IAM policy for a cross region replication rule, what might you see for source and destination actions?
For a source bucket expect to see list actions. For the target expect to see replication actions.
Where are pre-signed URLs generated for S3 and what is the default validity period?
pre-signed URLs are generated via the CLI or SDK. The validity period is 3600 seconds
What permissions does a user of a pre-signed URL inherit for PUTs and GETs in an S3 bucket?
the user who uses the pre-signed URL inherits the permissions of the user who created it.
Are delete markers replicated in cross region replication?
No
Can cross region replication replicate to a bucket in another account?
Yes.
There are 3 options that can be applied for replication in cross region replication to determine what gets replicated. What are they?
- Replicate the whole bucket
- Replicate objects with specific tags
- Replicate objects with specific user defined prefix in their name
Do all encryption types for S3 support interactions via HTTP AND HTTPS?
No. SSE-C must use HTTPS
When uploading to an S3 bucket usig SSE-C, how is the client key transmitted? What about for other requests to this bucket?
The encryption key is in the header of the request. All requests to S3 SSE-C buckets must contain this key
When uploading data to S3 using SSE-C, which protocol must you use?
HTTPS. The upload must be encrypted in transit
With respect to S3 encryption, what does KMS-CMK refer to?
KMS Customer master key. this is what S3 encrypts data with under SSE-KMS
what are the 4 methods of S3 encryption?
SSE-S3: Server side encyption with keys managed by KMS
SSE-KMS: Server side encryption using AWS KMS
SSE-C: Server Side encryption using a customer key
Client Side: Client encrypts data on their side and uploads