Creating Firewall Rules for a Virtual Private Cloud
Firewall rules are defined at the network level and used to control the flow of network traffic to VMs.
Firewall rules allow or deny a kind of traffic on a port; for example, a rule may allow TCP traffic to port 22. They also are applied to traffic in one direction, either incoming (ingress) or outgoing (egress) traffic. It is important to note that the firewall is stateful which means if traffic is allowed in one direction and a connection established, it is allowed in the other direction. Firewalls rulesets are stateful so if a connection is allowed, like establishing a SSH connection on port 22, then all later traffic matching this rule is permitted as long as the connection is active. An active connection is one with at least one packet exchanged every ten minutes.
Structure of Firewall Rules
Firewall rules consist of several components:
- Direction: Either ingress or egress.
- Priority: Highest-priority rules are applied; any rule...





















































