Other tools
There are other network security tools that we can use and automate with Python. Let's take a look at two of the most commonly used ones.
Private VLANs
A virtual local area networks (VLANs) have been around for a long time. They are essentially a broadcast domain where all hosts can be connected to a single switch, but are partitioned out to different domains, so we can separate the hosts out according to which host can see others via broadcasts. Let's consider a map based on IP subnets. For example, in an enterprise building, I would likely see one IP subnet per physical floor: 192.168.1.0/24
for the first floor, 192.168.2.0/24
for the second floor, and so on. In this pattern, we use a /24 block for each floor. This gives a clear delineation of my physical network as well as my logical network. A host wanting to communicate beyond its own subnet will need to traverse through its layer 3 gateway, where I can use an access list to enforce security.