AWS Certified Developer – Associate — Question 54
A developer is storing JSON files in an Amazon S3 bucket. The developer wants to securely share an object with a specific group of people.
How can the developer securely provide temporary access to the objects that are stored in the S3 bucket?
Answer options
- A. Set object retention on the files. Use the AWS software development kit (SDK) to restore the object before subsequent requests. Provide the bucket's S3 URL.
- B. Use the AWS software development kit (SDK) to generate a presigned URL. Provide the presigned URL.
- C. Set a bucket policy that restricts access after a period of time. Provide the bucket's S3 URL.
- D. Configure static web hosting on the S3 bucket. Provide the bucket's web URL.
Correct answer: B
Explanation
The correct answer is B because generating a presigned URL allows users to access the S3 object temporarily without changing the object permissions. Option A is incorrect as object retention does not allow for temporary access sharing. Option C's approach of limiting access through a bucket policy does not provide immediate temporary access to specific users. Option D does not secure the object sharing as it exposes the entire bucket to public access.