in reply to Firewall Log Analysis - port matrices
use Regexp::Common qw /net/; my %bad = (3128 => 1, 31337 => 1); my %win = (138 => 1, 139 => 1); while (<>) { /$RE{net}{IPv4}\/(\d{1,5})/ && ($bad{$1} || $win{$1}) && print; } [download]