This section shows which subnets are associated with this NACL, and as mentioned when discussing subnets, you can have multiple subnets associated with a single NACL, but only a single NACL can be associated with a subnet:
Figure 10.20: The NACL Subnet associations screen
If you fail to associate your NACL with the correct subnets, then your subnet might not have the appropriate security safeguards in place and could allow unwanted network traffic to be processed. Additionally, your NACLs could be created and configured but not associated with any subnet, providing no security measures.
The Tags tab, as previously discussed, helps you create key-value pairs that can be associated with your NACL.
Now that you know how to control security at the subnet/network level, you are ready to move on to a layer that operates at the instance level: security groups.
Security groups are much like NACLs in that they provide a virtual firewall level of protection but at the instance level rather than the network level. Security groups are associated with instances rather than subnets and control the traffic to and from your instances within your VPC. Again, only a single security group can be applied to an instance, but the same security group can be associated with multiple instances.
Security groups allow for stateful traffic, meaning that if the traffic is allowed in via the rules, then it is returned, notwithstanding any rules in place. You can specify inbound traffic rules based on a combination of port, IP range, or another security group. There are also other subtle differences between NACLs and security groups within the rule base. The following subsections will take you through the security group tabs.
The Details tab provides an overview of the security group, showing the security group ID, the name of the security group, its VPC association, and the rule counts—both inbound and outbound:
Figure 10.21: The security group Details screen
To review the security setup of a security group, examine the inbound and outbound rulesets.
The following screenshot shows the inbound traffic rules associated with this security group:
Figure 10.22: Security group inbound rules screen
Figure 10.21 contains six fields of pertinent information:
Notice that there is no field for Allow or Deny as with NACLs. This is because security groups only provide Allow rules by default. Therefore, if a rule is in a security group, it is considered allowed. If a match for traffic is not found within the security group, then the traffic is simply dropped. Also, there is no Rule number field. This is because all rules are evaluated by the security group before a decision is made about whether access should or should not be allowed.