in reply to Re^2: Parsing output from Nmap::Scanner with varying hash address.
in thread Parsing output from Nmap::Scanner with varying hash address.
Something like this should probably work (but is untested):
my %shortlist; for my $key (keys $results->{'ALLHOSTS'}){ for my $key2 (keys $results->{'ALLHOSTS'}{$key}{'ports'}{'tcp'}){ $shortlist{"$results->{'ALLHOSTS'}{$key}{'ports'}{'tcp'}{$key2 +}{'service'}{'name'}"} = $results->{'ALLHOSTS'}{$key}{'ports'}{'tcp'} +{$key2}{'state'}; } }
|
|---|
| Replies are listed 'Best First'. | |
|---|---|
|
Re^4: Parsing output from Nmap::Scanner with varying hash address.
by kcott (Archbishop) on Jul 11, 2015 at 22:15 UTC | |
by Laurent_R (Canon) on Jul 11, 2015 at 22:27 UTC |