Nmap XML parsing with Powershell
- by Craig620
I am trying to parse the XML output from NMAP and isolate just the hostadddress and the vendor from the osmatch. I've actually done that with the following:
select-xml -path nmap.xml -xpath "nmaprun/host/address/@addr|nmaprun/host/os/osmatch/osclass/@vendor" | select -expandproperty node
Which produces:
#text
-----
10.20.30.1
HP
10.20.30.2…