Dave van Leeuwen wrote:
Basically you want to test the return value from grep ( man grep )
if ( iptables -L traffic_in -vn | grep -q "192.168.3.136" ) then
"192.168.3.136" was found in iptables -L traffic_in -vn
else
it wasn't
Thanks Dave, I think that will get me half way there :)
My problem was 'how' to code the test. The -q is a good tip, I didn't
know about that.
Now I just need to know how to stuff the results in to the database.
Cheers Don
--
Don Gould
www.thinkdesignprint.co.nz - www.tcn.bowenvale.co.nz -
www.bowenvale.co.nz - www.hearingbooks.co.nz - www.buxtonsquare.co.nz -
SkypeMe: ThinkDesignPrint - Good ideas: www.solarking.co.nz