I'm looking at writing my own script for auditing a few different boxes with a number of services. I'm having trouble with something as simple as greping for IP addresses. In short, I'm looking to ensure that particular Apache servers are being accessed only from inside our classB. Given that:
Assume the ClassB is "abc.def.X.X" Assume the ClassC is "123.456.789.Y", What would be the easiest way to grep out all allowed classB and classC addresses (from our remote sites) from the logs before parsing further? Seems this can be done on one, maybe two statements --------------------------------------------------------------------------- ----------------------------------------------------------------------------