Bird
0
0

You want to restrict SSH access to your EC2 instance so only your office IP 198.51.100.25 can connect. Which security group ingress rule should you configure?

hard📝 Application Q15 of 15
AWS - Security Groups and Network ACLs
You want to restrict SSH access to your EC2 instance so only your office IP 198.51.100.25 can connect. Which security group ingress rule should you configure?
AProtocol: TCP, Port Range: 22, Source: 0.0.0.0/0
BProtocol: UDP, Port Range: 22, Source: 198.51.100.25/32
CProtocol: TCP, Port Range: 22, Source: 198.51.100.25/32
DProtocol: TCP, Port Range: 80, Source: 198.51.100.25/32
Step-by-Step Solution
Solution:
  1. Step 1: Identify correct protocol and port for SSH

    SSH uses TCP protocol on port 22.
  2. Step 2: Restrict source IP to single address

    Use CIDR /32 to specify exactly one IP address (198.51.100.25/32).
  3. Final Answer:

    Protocol: TCP, Port Range: 22, Source: 198.51.100.25/32 -> Option C
  4. Quick Check:

    SSH restricted to one IP with /32 [OK]
Quick Trick: Use /32 CIDR to allow single IP only [OK]
Common Mistakes:
  • Allowing all IPs with 0.0.0.0/0
  • Using UDP instead of TCP for SSH
  • Using wrong port like 80 for SSH

Want More Practice?

15+ quiz questions · All difficulty levels · Free

Free Signup - Practice All Questions
More AWS Quizzes