Hello everyone. So in this video we are
going to see how you can save your XML output
to CSV for Recon.
Remember this feature is
not been added to nmap. But we
are going to use a third party python
tool to perform this type of
output scan wherein we will
save the XML output to CSV output.
So the syntax of doing this is nmap the
target IP address hyphen o x and file.txt
which will generate a XML
file then we are going to take this XML
file and then we are going to run our parser which
will convert the XML file to a
CSV comma separated file.
So, let's see the Practical that how we can
do this.
So as you can see on my terminal first, I'm going
to scan this particular Target and I'm
going to save the output in XML format first.
As you can see the scanning has been successfully started and
I'm going to save my XML output in the
file name and map XML output dot
XML.
I will just skip the scanning part.
So as you can see the scan has been completed successfully.
And a file has been created.
over here
Now what I'm going to do is I'm going
to take this XML.
Input and I'm going to give it to the
parser of the Python.
So the format of doing this is python.
The script name which is nmap XML to CSV dot
pi and the input file.
And the output should be saved in
this file name. That is Rohit CSV dot
CSV.
After I will hit enter you can see a CSV file
has been created. Let me open up for you.
As you can see over here a comma separated value file
has been created.
And I can identify the status of
the ports of the target IP
address.
this this is useful for
Keeping a record of your target for better Recon. For
example, if after certain amount of
time if there is any exploit for any
particular server or service version, you
can just come back to the CSV file and check with
servers are vulnerable and you can exploit them.
I hope you guys understood. Thank you.