Secure networking Flashcards
By default, do all resources in a virtual network can communicate outbound with the internet?
Yes
What are the 3 ways resources in Azure can communicate with each other?
- Virtual Network/subnet
- Virtual Network Service Endpoint
- Virtual Network Peering
What are the 3 ways resources in Azure can communicate with on-prem resources?
- Point-to-site VPN
- Site-to-site VPN
- Azure ExpressRoute
Describe the purpose ‘Virtual network service endpoint’
Extend your virtual network’s private address space and allow connections into a separate network.
What are the 2 ways virtual traffic between subnets can be filtered?
- Network security groups (NSGs)
- Network virtual appliances (NVAs)
Describe a ‘Network virtual appliance (NVA)’
A VM that performs a network function, such as a firewall or WAN optimization found in the Azure Marketplace or custom ISO.
Describe a ‘Network/Application security group’
Filter traffic to and from resources by source and destination IP address, port, and protocol.
What does a Network/Application security group contain?
A 5-tuple hash rule specifying how traffic should be filtered.
Are Network/Application security groups stateless or stateful?
Stateful.
Does a Network/Application security group affect new connections?
Existing connections may not be interrupted; Modifying network security group rules will only affect new connections.
For inbound traffic, in what direction does Azure process rules in a network security group?
Azure processes the rules associated to a subnet first and then the rules in a network security group associated to the network interface.
For outbound traffic, in what direction does Azure process rules in a network security group?
Azure processes the rules associated to a network interface first and then the rules in a network security group associated to the subnet.
By default, can resources in a virtual subnet communicate with each other?
Yes.
Describe the purpose of the ‘IP Flow Verify’ function
Determine whether a communication is allowed or denied and verify to surface the identity of the network security rule responsible for allowing or denying the traffic.
Is it best practice to assign a NSG to the interface of a resource and another NSG to the subnet/network that resource belongs in?
No; Recommended to associate a NSG to a subnet, or a network interface, but not both.
Describe the purpose of an ‘Application Security Group (ASG)’
Group identical/similar virtual machines and define security rules based on those groups.
What should be considered when assigning network interfaces to an application security group with respect to each interfaces original network?
All network interfaces assigned to an ASG have to exist in the same virtual network that the first network interface assigned to the application security group is in.
What must be considered if placing an ASG as the source and destination in a security rule?
The network interfaces in both application security groups must exist in the same virtual network.
How many route tables can a subnet be associated with?
0 or 1.
How many subnets can a route table be associated with?
0 or more.
Describe ‘User-Defined Routes (UDRs)’
Static routes in Azure to override Azure’s default system routes that list the next hop IP in the route.
What are the 3 options for defining the next hop in a user-defined route?
- Virtual network appliance
- The private IP address of a network interface attached to a virtual machine
- The private IP address of an Azure internal load balancer
What is the outcome of defining a user-defined route with 0.0.0.0/0 as the address prefix and a next hop type of virtual appliance?
This configuration allows the appliance to inspect the traffic and determine whether to forward or drop the traffic.
What protocol must be used when defining a user-defined route to a virtual network gateway?
BGP not ExpressRoute.
When defining a user-defined route, what should be specified to drop the traffic to a destination?
By selecting ‘none’ as the destination.
What controls/mechanisms can be specified as the next hop in a user-defined route?
Virtual network peering or VirtualNetworkServiceEndpoint.
Can a service tag be specified as the address prefix of a user-defined route?
Yes.
By default, is traffic routed between two virtual networks?
No; Each virtual network is isolated.
Describe ‘Virtual network peering’
Connects two Azure virtual networks allowing the resources in each network to communicate as if they are in the same network.
How is traffic routed between VMs in a virtual network peering?
Routed through the Microsoft backbone infrastructure, through private IP addresses only.
Describe the purpose of a ‘VPN gateway’
A specific type of virtual network gateway used to send traffic between an Azure virtual network and an on-prem over the public internet.
Can a VPN gateway be used to connect two Azure virtual networks?
Yes.
What is the best use case for virtual network peering?
Cross-region data replication and database failover as well as for strict data policies and want to avoiding traffic over the internet.
What is the best use case for VPN Gateways?
Useful for necessary encryption and scenarios where latency is not important.
Describe a ‘Gateway transit’
Allows you to share an ExpressRoute or VPN gateway with all peered virtual networks.
What is the purpose of a gateway transit?
To create a transit virtual network that contains your VPN gateway, Network Virtual Appliance, and other shared services and connect virtual peerings.
What is the max VPN gateways per virtual network?
1
How many virtual peerings can a virtual network support?
Up to 500
How should encryption be implemented with virtual network peering?
Software-level encryption is recommended as it is not natively provided.
How should encryption be implemented with a VPN gateway?
Custom IPsec/IKE policy can be applied to new or existing connections.
Describe the purpose of implementing a ‘Virtual WAN’
Connects on-prem to your resources in Azure over an IPsec/IKE (IKEv1 and IKEv2) VPN connection.
What on-prem device should be considered when implementing a virtual WAN?
A VPN device located on-premises that has an externally facing public IP address assigned to it.
What is the PowerShell cmdlet to create a virtual WAN in Azure Virtual Networks?
New-AzVirtualWan.
What is the function of a hub in a virtual network?
A virtual network that can contain gateways for site-to-site, ExpressRoute, or point-to-site functionality.
What is the PowerShell cmdlet to create a virtual WAN hub in Azure Virtual Networks?
New-AzVirtualHub.
What is the PowerShell cmdlet to create a VPN gateway in Azure Virtual Networks?
New-AzVpnGateway.
What is the purpose of creating a VPN site?
Sites contain your on-premises VPN device endpoints and define the connection.
How many site are allowed per virtual hub in a virtual WAN?
Up to 1000 per hub.
What is the PowerShell cmdlet to create a VPN site in Azure Virtual Networks?
New-AzVpnSite.
What 3 parameters must be declared before connecting a VPN site to a hub?
- virtualWan
- vpnGateway
- vpnSite
What is the PowerShell cmdlet to connect a VPN site to a hub in Azure Virtual Networks?
New-AzVpnConnection
What is required after connecting a VPN site to a hub?
Connect a virtual network to the virtual hub.
Describe the connection of a ‘Site-to-site VPN’ in Azure virtual networks
IPsec/IKE (IKEv1 or IKEv2) VPN tunnel connecting an on-prem site to Azure or another on-prem site.
What is the best use case for a Site-to-site VPN?
For cross-premises and hybrid configurations.
What physical on-prem requirement should be considered when implementing a Site-to-site VPN?
Requires a VPN device located on-premises that has a public IP address assigned to it.
Describe the connection of a ‘Point-to-site VPN’
A secure connection established from the client PC to a virtual network.
What is the best use case for a Point-to-site VPN?
useful for telecommuters who want to connect to Azure VNets from a remote location or small VPN deployments.
Do Point-to-site VPNs require an on-prem public IP?
No.
Can a Point-to-site VPN share the same gateway as a Site-to-site VPN?
Yes; As long as all the configurations for both connections are compatible.
What two modes can a VPN gateway be configured in?
- active-standby mode using one public IP
- active-active mode using two public IPs
What must be considered when creating multiple VPN connections from a virtual network gateway?
Must use a RouteBased VPN type because each virtual network can only have one VPN gateway.
What is required to use site-to-site VPNs and ExpressRoute in the same configuration?
Two virtual network gateways for the same virtual network, one using the gateway type ‘Vpn’, and the other using the gateway type ExpressRoute.