Using netdiscover to perform host discovery (layer 2)

The netdiscover tool is a tool that is used to identify network hosts through both active and passive ARP analysis. It was primarily written to be used on a wireless interface; however, it is functional in a switched environment as well. In this specific recipe, we will discuss how to use netdiscover for both active and passive scanning.