Here’s how the blue team wards off red teamers and a few open-source tools it may leverage to identify chinks in the corporate armor