Unit 6: The Security Pillar - Practice Quiz

CSC301 — Introduction To Cloud Computing 60 Questions
0 Correct 0 Wrong 60 Left
0/60

1 What does AWS IAM primarily help you manage?

Introduction to Identity and Access management Easy
A. The physical servers in a data center
B. Who can access resources and what they can do
C. The speed of your network connection
D. The billing cycle of your account

2 Which of the following is an IAM identity used to group users and assign common permissions?

Introduction to Identity and Access management Easy
A. IAM Group
B. IAM Gateway
C. IAM Region
D. IAM Zone

3 What is the best practice regarding the AWS account root user?

Protecting AWS credentials Easy
A. Share it with all team members
B. Disable all logging for it
C. Use it for all daily operations
D. Avoid using it for everyday tasks and enable MFA

4 What does MFA stand for in the context of securing AWS credentials?

Protecting AWS credentials Easy
A. Multiple File Access
B. Managed Firewall Access
C. Multi-Factor Authentication
D. Monitored Function Audit

5 Fine-grained authorization in AWS is primarily achieved using which element?

Fine-grained Authorization Easy
A. S3 buckets
B. IAM policies
C. VPC subnets
D. EC2 instances

6 In an IAM policy, what does the Effect element typically specify?

Fine-grained Authorization Easy
A. The cost of the action
B. The region of the request
C. Whether to Allow or Deny access
D. The size of the resource

7 What is the purpose of an IAM permission boundary?

Permission Boundaries Easy
A. To grant unlimited access to a user
B. To store encryption keys
C. To delete unused IAM roles
D. To set the maximum permissions an identity can have

8 A permission boundary is attached to which type of IAM entity?

Permission Boundaries Easy
A. S3 objects
B. IAM users and roles
C. CloudWatch alarms
D. VPC gateways

9 What is a key characteristic of an IAM role?

Roles Easy
A. It stores billing information
B. It uses a permanent password only
C. It can only be used by the root user
D. It provides temporary credentials and can be assumed

10 Which scenario is a common use of an IAM role?

Roles Easy
A. Allowing an EC2 instance to access an S3 bucket
B. Increasing the CPU of a server
C. Changing the AWS region
D. Paying the monthly AWS bill

11 Which policy type is used to centrally manage permissions across accounts in an AWS Organization?

Enforcing Service-Level Protection Easy
A. Route tables
B. Launch templates
C. Service Control Policies (SCPs)
D. Security Group rules

12 What is the main goal of detective controls in cloud security?

Detective Controls Easy
A. To physically build data centers
B. To identify and log security events
C. To write application code
D. To design website layouts

13 What does AWS CloudTrail primarily record?

CloudTrail Easy
A. The color of the console
B. Website visitor demographics
C. API calls and account activity
D. The temperature of servers

14 Amazon CloudWatch Logs is mainly used to:

CloudWatch Logs Easy
A. Launch EC2 instances
B. Create IAM users
C. Collect and store log data from resources
D. Encrypt S3 buckets automatically

15 Amazon Athena allows you to query data stored in Amazon S3 using which language?

searching Logs with Athena Easy
A. YAML
B. Python only
C. Standard SQL
D. HTML

16 Which AWS service is used to assess, audit, and track resource configurations over time?

Auditing Resource Configuration Easy
A. Amazon Route 53
B. AWS Config
C. Amazon SNS
D. AWS Lambda

17 What is Amazon GuardDuty?

Amazon GaurdDuty Easy
A. A threat detection service
B. A content delivery network
C. A database engine
D. A code editor

18 Amazon Inspector is primarily used to:

Amazon Inspector Easy
A. Store large files
B. Manage DNS records
C. Send email notifications
D. Scan workloads for software vulnerabilities

19 What is the main purpose of Amazon Detective?

Amazon Detective Easy
A. To provision virtual networks
B. To analyze and investigate security findings
C. To compress data
D. To host static websites

20 AWS Security Hub provides which of the following?

Security Hub Easy
A. A central view of security alerts and compliance status
B. A managed relational database
C. A tool to design user interfaces
D. A video streaming platform

21 A developer needs to grant an application running on an EC2 instance temporary access to an S3 bucket without embedding long-term credentials. Which IAM feature best fits this requirement?

Introduction to Identity and Access management Medium
A. Add the instance to an IAM group with S3 permissions
B. Attach an IAM role to the EC2 instance
C. Create an IAM user and store its access keys on the instance
D. Enable MFA on the root account

22 An organization wants to reduce the risk associated with the AWS account root user. Which combination of actions is the most appropriate best practice?

Protecting AWS credentials Medium
A. Delete the root user after creating admin IAM users
B. Create long-term root access keys for automation scripts
C. Share the root password among senior admins and disable MFA
D. Enable MFA on the root user and use IAM users/roles for daily tasks

23 You want an IAM policy to allow a user to access only objects within an S3 prefix matching their username. Which IAM feature enables this dynamic condition?

Fine-grained Authorization Medium
A. Policy variables such as ${aws:username}
B. Resource-based bucket ACLs
C. An IAM group hierarchy
D. A permissions boundary

24 A team lead attaches a permissions boundary allowing only S3 and DynamoDB actions to an IAM user. The user also has an identity policy granting full EC2 access. What can the user actually do?

Permission Boundaries Medium
A. All S3, DynamoDB, and EC2 actions combined
B. Full EC2 access, because identity policies override boundaries
C. Only S3 and DynamoDB actions, since effective permissions are the intersection
D. Nothing, because the two policies conflict

25 An application in Account A needs to read data from an S3 bucket in Account B. What is the standard AWS mechanism to achieve this cross-account access?

Roles Medium
A. Account B creates a role that Account A's principal can assume via STS
B. Both accounts enable the root user access keys
C. Account A shares its IAM user credentials with Account B
D. Account B copies its IAM users into Account A

26 Which AWS Organizations feature lets you centrally restrict the maximum permissions available to all IAM users and roles across member accounts?

Enforcing Service-Level Protection Medium
A. Service Control Policies (SCPs)
B. IAM identity policies
C. Resource-based policies
D. Access control lists (ACLs)

27 A security team wants to detect suspicious activity after it occurs, rather than preventing it. Which category of controls are they implementing?

Detective Controls Medium
A. Corrective controls
B. Preventive controls
C. Deterrent controls
D. Detective controls

28 An auditor needs to determine which API call deleted a specific EC2 instance and who made it. Which service provides this information?

CloudTrail Medium
A. AWS Config rules
B. AWS CloudTrail
C. Amazon Inspector
D. Amazon CloudWatch metrics

29 You want to trigger an alarm when the word ERROR appears more than 5 times per minute in your application logs. Which CloudWatch Logs feature should you use?

CloudWatch Logs Medium
A. An Athena saved query
B. An S3 lifecycle policy
C. A metric filter that converts log events into a CloudWatch metric
D. A CloudTrail trail with log file validation

30 A company stores large volumes of CloudTrail logs in S3 and wants to run ad-hoc SQL queries over them without provisioning servers. Which service is most appropriate?

searching Logs with Athena Medium
A. Amazon Athena
B. AWS Glue DataBrew
C. Amazon RDS
D. Amazon Redshift Spectrum clusters

31 A compliance officer wants to be notified whenever an S3 bucket is changed to allow public access, and to see how its configuration evolved over time. Which service best meets this need?

Auditing Resource Configuration Medium
A. Amazon Macie
B. AWS Config
C. Amazon GuardDuty
D. AWS CloudTrail

32 Which data sources does Amazon GuardDuty analyze to detect threats such as crypto-mining or communication with malicious IPs?

Amazon GaurdDuty Medium
A. Only CloudWatch custom metrics
B. EC2 instance memory dumps
C. VPC Flow Logs, DNS logs, and CloudTrail events
D. S3 object contents directly

33 A DevOps team wants automated scanning of EC2 instances and container images for software vulnerabilities (CVEs) and unintended network exposure. Which service should they enable?

Amazon Inspector Medium
A. Amazon GuardDuty
B. Amazon Detective
C. Amazon Inspector
D. AWS Config

34 After GuardDuty raises a finding, an analyst needs to visualize linked events and understand the root cause across resources. Which service is purpose-built for this investigation?

Amazon Detective Medium
A. Amazon Inspector
B. Amazon Detective
C. AWS Trusted Advisor
D. AWS Config

35 An organization uses GuardDuty, Inspector, and Macie and wants a single dashboard that aggregates findings and checks against standards like CIS AWS Foundations. Which service provides this?

Security Hub Medium
A. AWS Security Hub
B. AWS Config
C. Amazon Detective
D. Amazon CloudWatch

36 A web server in a public subnet must accept HTTPS traffic but should not initiate outbound connections except for OS updates. Which statement about security groups is correct for this design?

Protecting Network Boundaries Medium
A. Security groups filter traffic at the subnet level
B. Security groups are stateless and require explicit outbound rules for responses
C. Security groups can block traffic using explicit deny rules
D. Security groups are stateful, so allowing inbound HTTPS automatically permits the response traffic

37 Which AWS component is stateless, operates at the subnet boundary, and supports explicit deny rules?

Protecting Network Boundaries Medium
A. Security group
B. IAM policy
C. Network ACL
D. Route table

38 A team must ensure that data stored in an S3 bucket is encrypted at rest using keys they can audit and control the rotation of. Which approach fits best?

Data Encryption Medium
A. Server-side encryption with AWS KMS customer managed keys (SSE-KMS)
B. Client-side hashing of objects before upload
C. Disabling encryption and relying on bucket policies
D. Server-side encryption with Amazon S3 managed keys (SSE-S3) only

39 In AWS KMS envelope encryption, how is a large data object typically encrypted efficiently?

Data Encryption Medium
A. Each byte is encrypted separately by KMS over the network
B. The KMS master key directly encrypts the entire object
C. A plaintext data key encrypts the data, and KMS encrypts the data key
D. The data is encrypted with the user's IAM password

40 An IAM policy contains both an Allow for s3:* and an explicit Deny for s3:DeleteObject. What is the net effect when the user tries to delete an object?

Fine-grained Authorization Medium
A. The request is allowed only with MFA
B. The request is denied, because an explicit deny always overrides an allow
C. The request is allowed, because s3:* includes delete
D. The policy is invalid and will be rejected

41 An IAM policy grants s3:GetObject on arn:aws:s3:::reports/* but includes a condition "StringNotEquals": {"aws:PrincipalTag/dept": "finance"} inside a Deny statement. A user tagged dept=finance attempts to read an object. What is the effective result?

Fine-grained Authorization Hard
A. Access is allowed only if an SCP additionally permits it
B. Access is denied because principal tags cannot be used in S3 conditions
C. Access is denied because any Deny always overrides an Allow
D. Access is allowed because the Deny condition is not met for this user

42 A developer has an identity-based policy allowing ec2:* and a permission boundary allowing only ec2:DescribeInstances and s3:GetObject. What actions can the developer actually perform?

Permission Boundaries Hard
A. ec2:DescribeInstances and s3:GetObject
B. No actions, because the policies conflict
C. Only ec2:DescribeInstances
D. All ec2:* actions

43 An EC2 instance uses an instance profile role. An application on it needs to assume a role in another account. Which configuration is required for the cross-account sts:AssumeRole call to succeed?

Roles Hard
A. The target role's trust policy must trust the instance profile role's ARN, and the instance role must have sts:AssumeRole permission
B. The target account must share its root credentials with the instance
C. The instance profile must be attached in both accounts simultaneously
D. The instance role must be added as an IAM user in the target account

44 Which approach best eliminates long-lived AWS credentials for an on-premises application that must call AWS APIs?

Protecting AWS credentials Hard
A. Rotate the access key manually every 24 hours
B. Embed an IAM user access key in an encrypted config file
C. Use IAM Roles Anywhere with X.509 certificates to obtain temporary credentials
D. Store the secret key in environment variables on the host

45 You need an immutable, tamper-evident record of all management events across every region, including validation that logs were not altered. Which CloudTrail configuration achieves this?

CloudTrail Hard
A. A multi-region trail with log file integrity validation enabled and S3 Object Lock on the bucket
B. A data event trail limited to the primary region
C. A single-region trail with server-side encryption only
D. CloudWatch Logs subscription with a 7-day retention

46 When querying CloudTrail logs stored in S3 with Athena, which practice most reduces query cost and scan time for queries filtered by date?

searching Logs with Athena Hard
A. Convert all logs to a single uncompressed CSV file
B. Run SELECT * and filter results in the client
C. Store logs in a single S3 prefix without partitioning
D. Create a partitioned table (e.g., by region/year/month/day) so Athena prunes partitions

47 GuardDuty raises a finding that an EC2 instance is communicating with a known cryptomining domain. Which data source did GuardDuty most likely analyze to detect this?

Amazon GaurdDuty Hard
A. IAM credential reports
B. VPC Flow Logs and DNS query logs
C. CloudFormation drift reports
D. S3 server access logs

48 Which statement best distinguishes Amazon Inspector from Amazon GuardDuty?

Amazon Inspector Hard
A. Both perform identical continuous threat detection
B. Inspector monitors real-time network traffic, while GuardDuty scans for CVEs
C. Inspector analyzes CloudTrail logs, while GuardDuty scans EC2 for software CVEs
D. Inspector assesses vulnerabilities and unintended network exposure in workloads, while GuardDuty detects active threats via log analysis

49 A security analyst has a GuardDuty finding and needs to understand the root cause and scope by visualizing related entities and behavior over time. Which service is purpose-built for this investigation?

Amazon Detective Hard
A. Amazon Detective
B. Amazon Inspector
C. AWS Config
D. Amazon Macie

50 An organization wants a single pane of glass that aggregates findings from GuardDuty, Inspector, and Macie and measures compliance against CIS benchmarks. Which service provides this?

Security Hub Hard
A. Amazon Detective
B. AWS Config aggregator alone
C. AWS CloudTrail
D. AWS Security Hub

51 You must detect whenever an S3 bucket's public access configuration changes and automatically remediate it. Which combination accomplishes continuous configuration auditing with remediation?

Auditing Resource Configuration Hard
A. CloudTrail trail with manual review
B. AWS Config rule with an automatic remediation action via SSM Automation
C. Athena query run weekly
D. GuardDuty finding with no action

52 An application uses envelope encryption with AWS KMS. Which statement correctly describes how the data key is handled?

Data Encryption Hard
A. The CMK plaintext material is exported to the client for local encryption
B. The plaintext data key is stored permanently alongside the ciphertext
C. KMS generates a plaintext data key and an encrypted copy; the plaintext encrypts data and is then discarded, keeping only the encrypted key
D. KMS encrypts the entire payload directly with the CMK regardless of size

53 A security group allows inbound HTTPS from 0.0.0.0/0, and a network ACL denies inbound from a malicious 203.0.113.0/24. Traffic arrives from that CIDR. What happens?

Protecting Network Boundaries Hard
A. Traffic is blocked because NACLs are evaluated before security groups at the subnet boundary
B. Traffic is allowed because NACLs only filter outbound
C. Traffic is allowed because security groups override NACLs
D. Traffic is blocked only if the security group also denies it

54 Which mechanism enforces that no IAM principal in any account of an AWS Organization can disable CloudTrail, even if they have administrator permissions?

Enforcing Service-Level Protection Hard
A. An IAM permission boundary on each user
B. A resource-based policy on the trail
C. A GuardDuty suppression rule
D. A Service Control Policy denying cloudtrail:StopLogging and cloudtrail:DeleteTrail

55 A request is evaluated with an identity-based Allow, a resource-based Allow, an SCP that does not mention the action, and a permission boundary that does not include the action. What is the result for an IAM user in the same account?

Introduction to Identity and Access management Hard
A. Allowed, because the resource-based policy grants it
B. Denied, because the action is outside the permission boundary
C. Denied, because the SCP is silent
D. Allowed, because the identity policy grants it

56 You want to trigger an alarm when the string UnauthorizedOperation appears more than 3 times in 5 minutes in application logs sent to CloudWatch Logs. Which approach works?

CloudWatch Logs Hard
A. Set the log group retention to 5 minutes
B. Query the logs manually with Athena every 5 minutes
C. Create a metric filter that increments a custom metric, then a CloudWatch alarm on that metric
D. Enable CloudTrail data events on the log group

57 An organization must retain full control over the key lifecycle and be able to prove keys were generated in hardware they manage. Which KMS key option fits best?

Data Encryption Hard
A. A default KMS CMK with automatic rotation
B. An AWS managed key
C. A custom key store backed by AWS CloudHSM
D. An S3-managed key (SSE-S3)

58 Which classification correctly groups these controls: CloudTrail, Config, and GuardDuty?

Detective Controls Hard
A. They are detective controls that identify and record events or deviations after they occur
B. They are corrective controls that automatically fix issues
C. They are directive controls that document policy
D. They are preventive controls that block actions before they happen

59 An S3 bucket policy allows access only when aws:SourceVpce equals a specific VPC endpoint ID. A user with full S3 admin IAM permissions accesses the bucket over the public internet. What happens?

Fine-grained Authorization Hard
A. Access is denied only if an SCP also restricts it
B. Access is allowed because aws:SourceVpce only applies to writes
C. Access is denied because the bucket policy condition is not satisfied
D. Access is allowed because IAM admin permissions override bucket policies

60 A Lambda function assumes an execution role. The role's trust policy specifies lambda.amazonaws.com as principal, but the function fails with an access error when writing to DynamoDB. Where is the problem most likely located?

Roles Hard
A. In the role's permissions (identity) policy, which lacks DynamoDB write actions
B. In the function's reserved concurrency setting
C. In the DynamoDB resource policy, which must trust Lambda service
D. In the trust policy, which must list DynamoDB as a principal