VPC Flashcards
What does CIDR stand for?
Classless Inter-Domain Routing
What is CIDR used for?
It is used in Security Group Rules to allocate IP addresses
What 2 components make up a CIDR?
- A Base IP like 12.34.56.78
- A Subnet Mask like /0, /24 or /32
What does a Subnet Mask do?
It defines how many bits can change in the IP
What does /8 Subnet Mask equal in IP?
255.0.0.0
What does /16 Subnet Mask equal in IP?
255.255.0.0
What does /24 Subnet Mask equal in IP?
255.255.255.0
What does /32 Subnet Mask equal in IP?
255.255.255.255
What is an IP made up of?
Its made up of 4 octets: 0.0.0.0
What does /32 mean regarding octets?
That no octet can change
What does /24 mean regarding octets?
That the last octet can change
What does /16 mean regarding octets?
That the last 2 octets can change
What does /8 mean regarding octets?
That the last 3 octets can change
What does /0 mean regarding octets?
That all octets can change
What values can a private network have?
They can have 10.0.0.0/8
What does the AWS default VPC IP usually look like?
172.16.0.0/12
What doe home network IPs look like?
192.168.0.0/16
What IP addresses does AWS reserve in a subnet?
The first 4 and the last 1
What does AWS use the reserved IPs for?
- 10.0.0.0 for Network Access
- 10.0.0.1 for the VPC Router
- 10.0.0.2 for mapping to Amazon provided DNS
- 10.0.0.3 for future use
- 10.0.0.255 for Network Broadcast Address
How do you calculate how many IP addresses a CIDR block represents?
2^32-prefix, where prefix is the number after the slash
What is an Internet Gateway used for?
It allows AWS resources in a VPC to access the internet
What is required for an Internet Gateway to allow Internet access?
A Route Table
What is a Bastion Host used for?
It is used to ssh into an EC2 instance in a private subnet
What are 3 important points about Bastion Hosts?
- The bastion host is in a public subnet, which allows access to resources in a private subnet
- The Bastion Host only requires SSH access on port 22
- The Bastion Host should only have access to the IP address you need, not a security group etc
In NAT Instance, what does NAT stand for?
Network Address Translation
What does a Nat Instance do?
Allows EC2 instances in private subnets to connect to the internet