XML, ngôn ngữ đánh dấu mở rộng, có phần của các nhà phê bình cũng như nhiều người đề xướng nhiệt tình. Tôi đã ở trong nhóm cũ, và chỉ miễn cưỡng kết hợp XML vào NMAP sau khi các tình nguyện viên thực hiện hầu hết các công việc. Kể từ đó, tôi đã học được cách đánh giá cao sức mạnh và tính linh hoạt mà XML cung cấp, và thậm chí đã viết cuốn sách này theo định dạng DOCBOOK XML. Tôi thực sự khuyên bạn nên các lập trình viên tương tác với NMAP thông qua giao diện XML thay vì cố gắng phân tích các đầu ra bình thường, tương tác hoặc có thể thay đổi. Định dạng XML bao gồm nhiều thông tin hơn các thông tin khác và có thể mở rộng đủ để có thể thêm các tính năng mới mà không phá vỡ các chương trình hiện có sử dụng nó. Nó có thể được phân tích cú pháp bởi các trình phân tích cú pháp XML tiêu chuẩn, có sẵn cho tất cả các ngôn ngữ lập trình phổ biến, thường là miễn phí. Biên tập viên, trình xác nhận, hệ thống chuyển đổi và nhiều ứng dụng khác đã biết cách xử lý định dạng. Mặt khác, đầu ra bình thường và tương tác là tùy chỉnh cho NMAP và tùy thuộc vào các thay đổi thường xuyên khi tôi cố gắng trình bày rõ ràng hơn cho người dùng cuối. Sản lượng grepable cũng dành riêng cho NMAP và khó khăn hơn để mở rộng hơn XML. Nó được coi là không dùng nữa và nhiều tính năng NMAP như phát hiện địa chỉ MAC không được trình bày ở định dạng đầu ra này.extensible markup language, has its share of critics as well as plenty of zealous proponents. I was long in the former group, and only grudgingly incorporated XML into Nmap after volunteers performed most of the work. Since then, I have learned to appreciate the power and flexibility that XML offers, and even wrote this book in the DocBook XML
format. I strongly recommend that programmers interact with Nmap through the XML interface rather than trying to parse the normal, interactive, or grepable output. The XML format includes more information than the others and is extensible enough that new features can be added without breaking existing programs that use it. It can be parsed by standard XML parsers, which are available for all popular programming languages, usually for free. Editors, validators, transformation systems, and many
other applications already know how to handle the format. Normal and interactive output, on the other hand, are custom to Nmap and subject to regular changes as I strive for a clearer presentation to end users. Grepable output is also Nmap-specific and tougher to extend than XML. It is considered deprecated, and many Nmap features such as MAC address detection are not presented in this output format.
Một ví dụ về đầu ra NMAP XML được hiển thị trong ví dụ & NBSP; 13.9. Whitespace đã được điều chỉnh cho khả năng đọc. Trong trường hợp này, XML đã được gửi đến stdout nhờ cấu trúc
# nmap -T4 -A -p 1-1000 -oX - scanme.nmap.org
<?xml version="1.0"?>
<?xml-stylesheet href="file:///usr/local/bin/../share/nmap/nmap.xsl" type="text/xsl"?>
<!-- Nmap 5.59BETA3 scan initiated Fri Sep 9 18:33:41 2011 as:
nmap -T4 -A -p 1-1000 -oX - scanme.nmap.org -->
<nmaprun scanner="nmap" args="nmap -T4 -A -p 1-1000 -oX - scanme.nmap.org" start="1315618421"
startstr="Fri Sep 9 18:33:41 2011" version="5.59BETA3" xmloutputversion="1.03">
<scaninfo type="syn" protocol="tcp" numservices="1000" services="1-1000"/>
<verbose level="0"/>
<debugging level="0"/>
<host starttime="1315618421" endtime="1315618434">
<status state="up" reason="echo-reply"/>
<address addr="74.207.244.221" addrtype="ipv4"/>
<hostnames>
<hostname name="scanme.nmap.org" type="user"/>
<hostname name="li86-221.members.linode.com" type="PTR"/>
</hostnames>
<ports>
<extraports state="closed" count="997">
<extrareasons reason="resets" count="997"/>
</extraports>
<port protocol="tcp" portid="22">
<state state="open" reason="syn-ack" reason_ttl="53"/>
<service name="ssh" product="OpenSSH" version="5.3p1 Debian 3ubuntu7"
extrainfo="protocol 2.0" ostype="Linux" method="probed" conf="10">
<cpe>cpe:/a:openbsd:openssh:5.3p1</cpe>
<cpe>cpe:/o:linux:kernel</cpe>
</service>
<script id="ssh-hostkey"
output="1024 8d:60:f1:7c:ca:b7:3d:0a:d6:67:54:9d:69:d9:b9:dd (DSA)

2048 79:f8:09:ac:d4:e2:32:42:10:49:d3:bd:20:82:85:ec (RSA)"/>
</port>
<port protocol="tcp" portid="80">
<state state="open" reason="syn-ack" reason_ttl="53"/>
<service name="http" product="Apache httpd" version="2.2.14"
extrainfo="(Ubuntu)" method="probed" conf="10">
<cpe>cpe:/a:apache:http_server:2.2.14</cpe>
</service>
<script id="http-title" output="Go ahead and ScanMe!"/>
</port>
</ports>
<os>
<portused state="open" proto="tcp" portid="22"/>
<portused state="closed" proto="tcp" portid="1"/>
<portused state="closed" proto="udp" portid="31289"/>
<osclass type="general purpose" vendor="Linux" osfamily="Linux"
osgen="2.6.X" accuracy="100">
<cpe>cpe:/o:linux:linux_kernel:2.6.39</cpe>
</osclass>
<osmatch name="Linux 2.6.39" accuracy="100" line="39278"/>
</os>
<uptime seconds="23450" lastboot="Fri Sep 9 12:03:04 2011"/>
<distance value="11"/>
<tcpsequence index="199" difficulty="Good luck!"
values="49018209,48C3EBED,495A2E7F,493EF30C,48ED43B3,495A9B0C"/>
<ipidsequence class="All zeros" values="0,0,0,0,0,0"/>
<tcptssequence class="1000HZ"
values="165CC09,165CC6E,165CCD2,165CD36,165CD9A,165CE48"/>
<trace port="256" proto="tcp">
<!-- Several hop elements removed for brevity -->
<hop ttl="9" ipaddr="72.52.92.109" rtt="15.69" host="10gigabitethernet1-1.core1.fmt1.he.net"/>
<hop ttl="10" ipaddr="64.62.250.6" rtt="12.06" host="linode-llc.10gigabitethernet2-3.core1.fmt1.he.net"/>
<hop ttl="11" ipaddr="74.207.244.221" rtt="16.55" host="li86-221.members.linode.com"/>
</trace>
<times srtt="26517" rttvar="19989" to="106473"/>
</host>
<runstats>
<finished time="1315618434" timestr="Fri Sep 9 18:33:54 2011" elapsed="13.66"
summary="Nmap done at Fri Sep 9 18:33:54 2011; 1 IP address (1 host up)
scanned in 13.66 seconds" exit="success"/>
<hosts up="1" down="0" total="1"/>
</runstats>
</nmaprun>
2. Một số chương trình thực hiện NMAP chọn đọc đầu ra theo cách đó, trong khi các chương trình khác chỉ định rằng đầu ra được gửi đến tên tệp và sau đó họ đọc tệp đó sau khi NMAP hoàn thành.Ví dụ & NBSP; 13.9. & NBSP; Một ví dụ về đầu ra NMAP XML
# nmap -T4 -A -p 1-1000 -oX - scanme.nmap.org
<?xml version="1.0"?>
<?xml-stylesheet href="file:///usr/local/bin/../share/nmap/nmap.xsl" type="text/xsl"?>
<!-- Nmap 5.59BETA3 scan initiated Fri Sep 9 18:33:41 2011 as:
nmap -T4 -A -p 1-1000 -oX - scanme.nmap.org -->
<nmaprun scanner="nmap" args="nmap -T4 -A -p 1-1000 -oX - scanme.nmap.org" start="1315618421"
startstr="Fri Sep 9 18:33:41 2011" version="5.59BETA3" xmloutputversion="1.03">
<scaninfo type="syn" protocol="tcp" numservices="1000" services="1-1000"/>
<verbose level="0"/>
<debugging level="0"/>
<host starttime="1315618421" endtime="1315618434">
<status state="up" reason="echo-reply"/>
<address addr="74.207.244.221" addrtype="ipv4"/>
<hostnames>
<hostname name="scanme.nmap.org" type="user"/>
<hostname name="li86-221.members.linode.com" type="PTR"/>
</hostnames>
<ports>
<extraports state="closed" count="997">
<extrareasons reason="resets" count="997"/>
</extraports>
<port protocol="tcp" portid="22">
<state state="open" reason="syn-ack" reason_ttl="53"/>
<service name="ssh" product="OpenSSH" version="5.3p1 Debian 3ubuntu7"
extrainfo="protocol 2.0" ostype="Linux" method="probed" conf="10">
<cpe>cpe:/a:openbsd:openssh:5.3p1</cpe>
<cpe>cpe:/o:linux:kernel</cpe>
</service>
<script id="ssh-hostkey"
output="1024 8d:60:f1:7c:ca:b7:3d:0a:d6:67:54:9d:69:d9:b9:dd (DSA)

2048 79:f8:09:ac:d4:e2:32:42:10:49:d3:bd:20:82:85:ec (RSA)"/>
</port>
<port protocol="tcp" portid="80">
<state state="open" reason="syn-ack" reason_ttl="53"/>
<service name="http" product="Apache httpd" version="2.2.14"
extrainfo="(Ubuntu)" method="probed" conf="10">
<cpe>cpe:/a:apache:http_server:2.2.14</cpe>
</service>
<script id="http-title" output="Go ahead and ScanMe!"/>
</port>
</ports>
<os>
<portused state="open" proto="tcp" portid="22"/>
<portused state="closed" proto="tcp" portid="1"/>
<portused state="closed" proto="udp" portid="31289"/>
<osclass type="general purpose" vendor="Linux" osfamily="Linux"
osgen="2.6.X" accuracy="100">
<cpe>cpe:/o:linux:linux_kernel:2.6.39</cpe>
</osclass>
<osmatch name="Linux 2.6.39" accuracy="100" line="39278"/>
</os>
<uptime seconds="23450" lastboot="Fri Sep 9 12:03:04 2011"/>
<distance value="11"/>
<tcpsequence index="199" difficulty="Good luck!"
values="49018209,48C3EBED,495A2E7F,493EF30C,48ED43B3,495A9B0C"/>
<ipidsequence class="All zeros" values="0,0,0,0,0,0"/>
<tcptssequence class="1000HZ"
values="165CC09,165CC6E,165CCD2,165CD36,165CD9A,165CE48"/>
<trace port="256" proto="tcp">
<!-- Several hop elements removed for brevity -->
<hop ttl="9" ipaddr="72.52.92.109" rtt="15.69" host="10gigabitethernet1-1.core1.fmt1.he.net"/>
<hop ttl="10" ipaddr="64.62.250.6" rtt="12.06" host="linode-llc.10gigabitethernet2-3.core1.fmt1.he.net"/>
<hop ttl="11" ipaddr="74.207.244.221" rtt="16.55" host="li86-221.members.linode.com"/>
</trace>
<times srtt="26517" rttvar="19989" to="106473"/>
</host>
<runstats>
<finished time="1315618434" timestr="Fri Sep 9 18:33:54 2011" elapsed="13.66"
summary="Nmap done at Fri Sep 9 18:33:54 2011; 1 IP address (1 host up)
scanned in 13.66 seconds" exit="success"/>
<hosts up="1" down="0" total="1"/>
</runstats>
</nmaprun>
Một lợi thế khác của XML là bản chất dài dòng của nó giúp đọc và hiểu dễ dàng hơn các định dạng khác. Người đọc quen thuộc với NMAP nói chung có thể hiểu hầu hết đầu ra XML trong ví dụ & NBSP; 13.9, Một ví dụ về đầu ra NMAP XML mà không cần thêm tài liệu. Mặt khác, định dạng đầu ra có thể sử dụng được là khó khăn để giải mã mà không cần hướng dẫn tham khảo riêng.
Có một vài khía cạnh của đầu ra XML ví dụ có thể không tự giải thích. Ví dụ, hãy xem hai yếu tố
# nmap -T4 -A -p 1-1000 -oX - scanme.nmap.org
<?xml version="1.0"?>
<?xml-stylesheet href="file:///usr/local/bin/../share/nmap/nmap.xsl" type="text/xsl"?>
<!-- Nmap 5.59BETA3 scan initiated Fri Sep 9 18:33:41 2011 as:
nmap -T4 -A -p 1-1000 -oX - scanme.nmap.org -->
<nmaprun scanner="nmap" args="nmap -T4 -A -p 1-1000 -oX - scanme.nmap.org" start="1315618421"
startstr="Fri Sep 9 18:33:41 2011" version="5.59BETA3" xmloutputversion="1.03">
<scaninfo type="syn" protocol="tcp" numservices="1000" services="1-1000"/>
<verbose level="0"/>
<debugging level="0"/>
<host starttime="1315618421" endtime="1315618434">
<status state="up" reason="echo-reply"/>
<address addr="74.207.244.221" addrtype="ipv4"/>
<hostnames>
<hostname name="scanme.nmap.org" type="user"/>
<hostname name="li86-221.members.linode.com" type="PTR"/>
</hostnames>
<ports>
<extraports state="closed" count="997">
<extrareasons reason="resets" count="997"/>
</extraports>
<port protocol="tcp" portid="22">
<state state="open" reason="syn-ack" reason_ttl="53"/>
<service name="ssh" product="OpenSSH" version="5.3p1 Debian 3ubuntu7"
extrainfo="protocol 2.0" ostype="Linux" method="probed" conf="10">
<cpe>cpe:/a:openbsd:openssh:5.3p1</cpe>
<cpe>cpe:/o:linux:kernel</cpe>
</service>
<script id="ssh-hostkey"
output="1024 8d:60:f1:7c:ca:b7:3d:0a:d6:67:54:9d:69:d9:b9:dd (DSA)

2048 79:f8:09:ac:d4:e2:32:42:10:49:d3:bd:20:82:85:ec (RSA)"/>
</port>
<port protocol="tcp" portid="80">
<state state="open" reason="syn-ack" reason_ttl="53"/>
<service name="http" product="Apache httpd" version="2.2.14"
extrainfo="(Ubuntu)" method="probed" conf="10">
<cpe>cpe:/a:apache:http_server:2.2.14</cpe>
</service>
<script id="http-title" output="Go ahead and ScanMe!"/>
</port>
</ports>
<os>
<portused state="open" proto="tcp" portid="22"/>
<portused state="closed" proto="tcp" portid="1"/>
<portused state="closed" proto="udp" portid="31289"/>
<osclass type="general purpose" vendor="Linux" osfamily="Linux"
osgen="2.6.X" accuracy="100">
<cpe>cpe:/o:linux:linux_kernel:2.6.39</cpe>
</osclass>
<osmatch name="Linux 2.6.39" accuracy="100" line="39278"/>
</os>
<uptime seconds="23450" lastboot="Fri Sep 9 12:03:04 2011"/>
<distance value="11"/>
<tcpsequence index="199" difficulty="Good luck!"
values="49018209,48C3EBED,495A2E7F,493EF30C,48ED43B3,495A9B0C"/>
<ipidsequence class="All zeros" values="0,0,0,0,0,0"/>
<tcptssequence class="1000HZ"
values="165CC09,165CC6E,165CCD2,165CD36,165CD9A,165CE48"/>
<trace port="256" proto="tcp">
<!-- Several hop elements removed for brevity -->
<hop ttl="9" ipaddr="72.52.92.109" rtt="15.69" host="10gigabitethernet1-1.core1.fmt1.he.net"/>
<hop ttl="10" ipaddr="64.62.250.6" rtt="12.06" host="linode-llc.10gigabitethernet2-3.core1.fmt1.he.net"/>
<hop ttl="11" ipaddr="74.207.244.221" rtt="16.55" host="li86-221.members.linode.com"/>
</trace>
<times srtt="26517" rttvar="19989" to="106473"/>
</host>
<runstats>
<finished time="1315618434" timestr="Fri Sep 9 18:33:54 2011" elapsed="13.66"
summary="Nmap done at Fri Sep 9 18:33:54 2011; 1 IP address (1 host up)
scanned in 13.66 seconds" exit="success"/>
<hosts up="1" down="0" total="1"/>
</runstats>
</nmaprun>
3 trong ví dụ & nbsp; 13.10Ví dụ & NBSP; 13.10. & NBSP; NMAP XML Port Elements
<port protocol="tcp" portid="22">
<state state="open" reason="syn-ack" reason_ttl="56"/>
<service name="ssh" product="OpenSSH" version="4.3" extrainfo="protocol 2.0"
method="probed" conf="10"/>
<script id="ssh-hostkey"
output="1024 60:ac:4d:51:b1:cd:85:09:12:16:92:76:1d:5d:27:6e (DSA)

2048 2c:22:75:60:4b:c3:3b:18:a2:97:2c:96:7e:28:dc:dd (RSA)"/>
</port>
<port protocol="tcp" portid="113">
<state state="closed" reason="reset" reason_ttl="56"/>
<service name="auth" method="table" conf="3"/>
</port>
Giao thức cổng, ID (số cổng), trạng thái và tên dịch vụ giống như sẽ được hiển thị trong bảng cổng đầu ra tương tác. Dịch vụ
# nmap -T4 -A -p 1-1000 -oX - scanme.nmap.org
<?xml version="1.0"?>
<?xml-stylesheet href="file:///usr/local/bin/../share/nmap/nmap.xsl" type="text/xsl"?>
<!-- Nmap 5.59BETA3 scan initiated Fri Sep 9 18:33:41 2011 as:
nmap -T4 -A -p 1-1000 -oX - scanme.nmap.org -->
<nmaprun scanner="nmap" args="nmap -T4 -A -p 1-1000 -oX - scanme.nmap.org" start="1315618421"
startstr="Fri Sep 9 18:33:41 2011" version="5.59BETA3" xmloutputversion="1.03">
<scaninfo type="syn" protocol="tcp" numservices="1000" services="1-1000"/>
<verbose level="0"/>
<debugging level="0"/>
<host starttime="1315618421" endtime="1315618434">
<status state="up" reason="echo-reply"/>
<address addr="74.207.244.221" addrtype="ipv4"/>
<hostnames>
<hostname name="scanme.nmap.org" type="user"/>
<hostname name="li86-221.members.linode.com" type="PTR"/>
</hostnames>
<ports>
<extraports state="closed" count="997">
<extrareasons reason="resets" count="997"/>
</extraports>
<port protocol="tcp" portid="22">
<state state="open" reason="syn-ack" reason_ttl="53"/>
<service name="ssh" product="OpenSSH" version="5.3p1 Debian 3ubuntu7"
extrainfo="protocol 2.0" ostype="Linux" method="probed" conf="10">
<cpe>cpe:/a:openbsd:openssh:5.3p1</cpe>
<cpe>cpe:/o:linux:kernel</cpe>
</service>
<script id="ssh-hostkey"
output="1024 8d:60:f1:7c:ca:b7:3d:0a:d6:67:54:9d:69:d9:b9:dd (DSA)

2048 79:f8:09:ac:d4:e2:32:42:10:49:d3:bd:20:82:85:ec (RSA)"/>
</port>
<port protocol="tcp" portid="80">
<state state="open" reason="syn-ack" reason_ttl="53"/>
<service name="http" product="Apache httpd" version="2.2.14"
extrainfo="(Ubuntu)" method="probed" conf="10">
<cpe>cpe:/a:apache:http_server:2.2.14</cpe>
</service>
<script id="http-title" output="Go ahead and ScanMe!"/>
</port>
</ports>
<os>
<portused state="open" proto="tcp" portid="22"/>
<portused state="closed" proto="tcp" portid="1"/>
<portused state="closed" proto="udp" portid="31289"/>
<osclass type="general purpose" vendor="Linux" osfamily="Linux"
osgen="2.6.X" accuracy="100">
<cpe>cpe:/o:linux:linux_kernel:2.6.39</cpe>
</osclass>
<osmatch name="Linux 2.6.39" accuracy="100" line="39278"/>
</os>
<uptime seconds="23450" lastboot="Fri Sep 9 12:03:04 2011"/>
<distance value="11"/>
<tcpsequence index="199" difficulty="Good luck!"
values="49018209,48C3EBED,495A2E7F,493EF30C,48ED43B3,495A9B0C"/>
<ipidsequence class="All zeros" values="0,0,0,0,0,0"/>
<tcptssequence class="1000HZ"
values="165CC09,165CC6E,165CCD2,165CD36,165CD9A,165CE48"/>
<trace port="256" proto="tcp">
<!-- Several hop elements removed for brevity -->
<hop ttl="9" ipaddr="72.52.92.109" rtt="15.69" host="10gigabitethernet1-1.core1.fmt1.he.net"/>
<hop ttl="10" ipaddr="64.62.250.6" rtt="12.06" host="linode-llc.10gigabitethernet2-3.core1.fmt1.he.net"/>
<hop ttl="11" ipaddr="74.207.244.221" rtt="16.55" host="li86-221.members.linode.com"/>
</trace>
<times srtt="26517" rttvar="19989" to="106473"/>
</host>
<runstats>
<finished time="1315618434" timestr="Fri Sep 9 18:33:54 2011" elapsed="13.66"
summary="Nmap done at Fri Sep 9 18:33:54 2011; 1 IP address (1 host up)
scanned in 13.66 seconds" exit="success"/>
<hosts up="1" down="0" total="1"/>
</runstats>
</nmaprun>
4, # nmap -T4 -A -p 1-1000 -oX - scanme.nmap.org
<?xml version="1.0"?>
<?xml-stylesheet href="file:///usr/local/bin/../share/nmap/nmap.xsl" type="text/xsl"?>
<!-- Nmap 5.59BETA3 scan initiated Fri Sep 9 18:33:41 2011 as:
nmap -T4 -A -p 1-1000 -oX - scanme.nmap.org -->
<nmaprun scanner="nmap" args="nmap -T4 -A -p 1-1000 -oX - scanme.nmap.org" start="1315618421"
startstr="Fri Sep 9 18:33:41 2011" version="5.59BETA3" xmloutputversion="1.03">
<scaninfo type="syn" protocol="tcp" numservices="1000" services="1-1000"/>
<verbose level="0"/>
<debugging level="0"/>
<host starttime="1315618421" endtime="1315618434">
<status state="up" reason="echo-reply"/>
<address addr="74.207.244.221" addrtype="ipv4"/>
<hostnames>
<hostname name="scanme.nmap.org" type="user"/>
<hostname name="li86-221.members.linode.com" type="PTR"/>
</hostnames>
<ports>
<extraports state="closed" count="997">
<extrareasons reason="resets" count="997"/>
</extraports>
<port protocol="tcp" portid="22">
<state state="open" reason="syn-ack" reason_ttl="53"/>
<service name="ssh" product="OpenSSH" version="5.3p1 Debian 3ubuntu7"
extrainfo="protocol 2.0" ostype="Linux" method="probed" conf="10">
<cpe>cpe:/a:openbsd:openssh:5.3p1</cpe>
<cpe>cpe:/o:linux:kernel</cpe>
</service>
<script id="ssh-hostkey"
output="1024 8d:60:f1:7c:ca:b7:3d:0a:d6:67:54:9d:69:d9:b9:dd (DSA)

2048 79:f8:09:ac:d4:e2:32:42:10:49:d3:bd:20:82:85:ec (RSA)"/>
</port>
<port protocol="tcp" portid="80">
<state state="open" reason="syn-ack" reason_ttl="53"/>
<service name="http" product="Apache httpd" version="2.2.14"
extrainfo="(Ubuntu)" method="probed" conf="10">
<cpe>cpe:/a:apache:http_server:2.2.14</cpe>
</service>
<script id="http-title" output="Go ahead and ScanMe!"/>
</port>
</ports>
<os>
<portused state="open" proto="tcp" portid="22"/>
<portused state="closed" proto="tcp" portid="1"/>
<portused state="closed" proto="udp" portid="31289"/>
<osclass type="general purpose" vendor="Linux" osfamily="Linux"
osgen="2.6.X" accuracy="100">
<cpe>cpe:/o:linux:linux_kernel:2.6.39</cpe>
</osclass>
<osmatch name="Linux 2.6.39" accuracy="100" line="39278"/>
</os>
<uptime seconds="23450" lastboot="Fri Sep 9 12:03:04 2011"/>
<distance value="11"/>
<tcpsequence index="199" difficulty="Good luck!"
values="49018209,48C3EBED,495A2E7F,493EF30C,48ED43B3,495A9B0C"/>
<ipidsequence class="All zeros" values="0,0,0,0,0,0"/>
<tcptssequence class="1000HZ"
values="165CC09,165CC6E,165CCD2,165CD36,165CD9A,165CE48"/>
<trace port="256" proto="tcp">
<!-- Several hop elements removed for brevity -->
<hop ttl="9" ipaddr="72.52.92.109" rtt="15.69" host="10gigabitethernet1-1.core1.fmt1.he.net"/>
<hop ttl="10" ipaddr="64.62.250.6" rtt="12.06" host="linode-llc.10gigabitethernet2-3.core1.fmt1.he.net"/>
<hop ttl="11" ipaddr="74.207.244.221" rtt="16.55" host="li86-221.members.linode.com"/>
</trace>
<times srtt="26517" rttvar="19989" to="106473"/>
</host>
<runstats>
<finished time="1315618434" timestr="Fri Sep 9 18:33:54 2011" elapsed="13.66"
summary="Nmap done at Fri Sep 9 18:33:54 2011; 1 IP address (1 host up)
scanned in 13.66 seconds" exit="success"/>
<hosts up="1" down="0" total="1"/>
</runstats>
</nmaprun>
5 và # nmap -T4 -A -p 1-1000 -oX - scanme.nmap.org
<?xml version="1.0"?>
<?xml-stylesheet href="file:///usr/local/bin/../share/nmap/nmap.xsl" type="text/xsl"?>
<!-- Nmap 5.59BETA3 scan initiated Fri Sep 9 18:33:41 2011 as:
nmap -T4 -A -p 1-1000 -oX - scanme.nmap.org -->
<nmaprun scanner="nmap" args="nmap -T4 -A -p 1-1000 -oX - scanme.nmap.org" start="1315618421"
startstr="Fri Sep 9 18:33:41 2011" version="5.59BETA3" xmloutputversion="1.03">
<scaninfo type="syn" protocol="tcp" numservices="1000" services="1-1000"/>
<verbose level="0"/>
<debugging level="0"/>
<host starttime="1315618421" endtime="1315618434">
<status state="up" reason="echo-reply"/>
<address addr="74.207.244.221" addrtype="ipv4"/>
<hostnames>
<hostname name="scanme.nmap.org" type="user"/>
<hostname name="li86-221.members.linode.com" type="PTR"/>
</hostnames>
<ports>
<extraports state="closed" count="997">
<extrareasons reason="resets" count="997"/>
</extraports>
<port protocol="tcp" portid="22">
<state state="open" reason="syn-ack" reason_ttl="53"/>
<service name="ssh" product="OpenSSH" version="5.3p1 Debian 3ubuntu7"
extrainfo="protocol 2.0" ostype="Linux" method="probed" conf="10">
<cpe>cpe:/a:openbsd:openssh:5.3p1</cpe>
<cpe>cpe:/o:linux:kernel</cpe>
</service>
<script id="ssh-hostkey"
output="1024 8d:60:f1:7c:ca:b7:3d:0a:d6:67:54:9d:69:d9:b9:dd (DSA)

2048 79:f8:09:ac:d4:e2:32:42:10:49:d3:bd:20:82:85:ec (RSA)"/>
</port>
<port protocol="tcp" portid="80">
<state state="open" reason="syn-ack" reason_ttl="53"/>
<service name="http" product="Apache httpd" version="2.2.14"
extrainfo="(Ubuntu)" method="probed" conf="10">
<cpe>cpe:/a:apache:http_server:2.2.14</cpe>
</service>
<script id="http-title" output="Go ahead and ScanMe!"/>
</port>
</ports>
<os>
<portused state="open" proto="tcp" portid="22"/>
<portused state="closed" proto="tcp" portid="1"/>
<portused state="closed" proto="udp" portid="31289"/>
<osclass type="general purpose" vendor="Linux" osfamily="Linux"
osgen="2.6.X" accuracy="100">
<cpe>cpe:/o:linux:linux_kernel:2.6.39</cpe>
</osclass>
<osmatch name="Linux 2.6.39" accuracy="100" line="39278"/>
</os>
<uptime seconds="23450" lastboot="Fri Sep 9 12:03:04 2011"/>
<distance value="11"/>
<tcpsequence index="199" difficulty="Good luck!"
values="49018209,48C3EBED,495A2E7F,493EF30C,48ED43B3,495A9B0C"/>
<ipidsequence class="All zeros" values="0,0,0,0,0,0"/>
<tcptssequence class="1000HZ"
values="165CC09,165CC6E,165CCD2,165CD36,165CD9A,165CE48"/>
<trace port="256" proto="tcp">
<!-- Several hop elements removed for brevity -->
<hop ttl="9" ipaddr="72.52.92.109" rtt="15.69" host="10gigabitethernet1-1.core1.fmt1.he.net"/>
<hop ttl="10" ipaddr="64.62.250.6" rtt="12.06" host="linode-llc.10gigabitethernet2-3.core1.fmt1.he.net"/>
<hop ttl="11" ipaddr="74.207.244.221" rtt="16.55" host="li86-221.members.linode.com"/>
</trace>
<times srtt="26517" rttvar="19989" to="106473"/>
</host>
<runstats>
<finished time="1315618434" timestr="Fri Sep 9 18:33:54 2011" elapsed="13.66"
summary="Nmap done at Fri Sep 9 18:33:54 2011; 1 IP address (1 host up)
scanned in 13.66 seconds" exit="success"/>
<hosts up="1" down="0" total="1"/>
</runstats>
</nmaprun>
6 đến từ phát hiện phiên bản và được kết hợp với nhau thành một trường của bảng cổng đầu ra tương tác. Các thuộc tính # nmap -T4 -A -p 1-1000 -oX - scanme.nmap.org
<?xml version="1.0"?>
<?xml-stylesheet href="file:///usr/local/bin/../share/nmap/nmap.xsl" type="text/xsl"?>
<!-- Nmap 5.59BETA3 scan initiated Fri Sep 9 18:33:41 2011 as:
nmap -T4 -A -p 1-1000 -oX - scanme.nmap.org -->
<nmaprun scanner="nmap" args="nmap -T4 -A -p 1-1000 -oX - scanme.nmap.org" start="1315618421"
startstr="Fri Sep 9 18:33:41 2011" version="5.59BETA3" xmloutputversion="1.03">
<scaninfo type="syn" protocol="tcp" numservices="1000" services="1-1000"/>
<verbose level="0"/>
<debugging level="0"/>
<host starttime="1315618421" endtime="1315618434">
<status state="up" reason="echo-reply"/>
<address addr="74.207.244.221" addrtype="ipv4"/>
<hostnames>
<hostname name="scanme.nmap.org" type="user"/>
<hostname name="li86-221.members.linode.com" type="PTR"/>
</hostnames>
<ports>
<extraports state="closed" count="997">
<extrareasons reason="resets" count="997"/>
</extraports>
<port protocol="tcp" portid="22">
<state state="open" reason="syn-ack" reason_ttl="53"/>
<service name="ssh" product="OpenSSH" version="5.3p1 Debian 3ubuntu7"
extrainfo="protocol 2.0" ostype="Linux" method="probed" conf="10">
<cpe>cpe:/a:openbsd:openssh:5.3p1</cpe>
<cpe>cpe:/o:linux:kernel</cpe>
</service>
<script id="ssh-hostkey"
output="1024 8d:60:f1:7c:ca:b7:3d:0a:d6:67:54:9d:69:d9:b9:dd (DSA)

2048 79:f8:09:ac:d4:e2:32:42:10:49:d3:bd:20:82:85:ec (RSA)"/>
</port>
<port protocol="tcp" portid="80">
<state state="open" reason="syn-ack" reason_ttl="53"/>
<service name="http" product="Apache httpd" version="2.2.14"
extrainfo="(Ubuntu)" method="probed" conf="10">
<cpe>cpe:/a:apache:http_server:2.2.14</cpe>
</service>
<script id="http-title" output="Go ahead and ScanMe!"/>
</port>
</ports>
<os>
<portused state="open" proto="tcp" portid="22"/>
<portused state="closed" proto="tcp" portid="1"/>
<portused state="closed" proto="udp" portid="31289"/>
<osclass type="general purpose" vendor="Linux" osfamily="Linux"
osgen="2.6.X" accuracy="100">
<cpe>cpe:/o:linux:linux_kernel:2.6.39</cpe>
</osclass>
<osmatch name="Linux 2.6.39" accuracy="100" line="39278"/>
</os>
<uptime seconds="23450" lastboot="Fri Sep 9 12:03:04 2011"/>
<distance value="11"/>
<tcpsequence index="199" difficulty="Good luck!"
values="49018209,48C3EBED,495A2E7F,493EF30C,48ED43B3,495A9B0C"/>
<ipidsequence class="All zeros" values="0,0,0,0,0,0"/>
<tcptssequence class="1000HZ"
values="165CC09,165CC6E,165CCD2,165CD36,165CD9A,165CE48"/>
<trace port="256" proto="tcp">
<!-- Several hop elements removed for brevity -->
<hop ttl="9" ipaddr="72.52.92.109" rtt="15.69" host="10gigabitethernet1-1.core1.fmt1.he.net"/>
<hop ttl="10" ipaddr="64.62.250.6" rtt="12.06" host="linode-llc.10gigabitethernet2-3.core1.fmt1.he.net"/>
<hop ttl="11" ipaddr="74.207.244.221" rtt="16.55" host="li86-221.members.linode.com"/>
</trace>
<times srtt="26517" rttvar="19989" to="106473"/>
</host>
<runstats>
<finished time="1315618434" timestr="Fri Sep 9 18:33:54 2011" elapsed="13.66"
summary="Nmap done at Fri Sep 9 18:33:54 2011; 1 IP address (1 host up)
scanned in 13.66 seconds" exit="success"/>
<hosts up="1" down="0" total="1"/>
</runstats>
</nmaprun>
7 và # nmap -T4 -A -p 1-1000 -oX - scanme.nmap.org
<?xml version="1.0"?>
<?xml-stylesheet href="file:///usr/local/bin/../share/nmap/nmap.xsl" type="text/xsl"?>
<!-- Nmap 5.59BETA3 scan initiated Fri Sep 9 18:33:41 2011 as:
nmap -T4 -A -p 1-1000 -oX - scanme.nmap.org -->
<nmaprun scanner="nmap" args="nmap -T4 -A -p 1-1000 -oX - scanme.nmap.org" start="1315618421"
startstr="Fri Sep 9 18:33:41 2011" version="5.59BETA3" xmloutputversion="1.03">
<scaninfo type="syn" protocol="tcp" numservices="1000" services="1-1000"/>
<verbose level="0"/>
<debugging level="0"/>
<host starttime="1315618421" endtime="1315618434">
<status state="up" reason="echo-reply"/>
<address addr="74.207.244.221" addrtype="ipv4"/>
<hostnames>
<hostname name="scanme.nmap.org" type="user"/>
<hostname name="li86-221.members.linode.com" type="PTR"/>
</hostnames>
<ports>
<extraports state="closed" count="997">
<extrareasons reason="resets" count="997"/>
</extraports>
<port protocol="tcp" portid="22">
<state state="open" reason="syn-ack" reason_ttl="53"/>
<service name="ssh" product="OpenSSH" version="5.3p1 Debian 3ubuntu7"
extrainfo="protocol 2.0" ostype="Linux" method="probed" conf="10">
<cpe>cpe:/a:openbsd:openssh:5.3p1</cpe>
<cpe>cpe:/o:linux:kernel</cpe>
</service>
<script id="ssh-hostkey"
output="1024 8d:60:f1:7c:ca:b7:3d:0a:d6:67:54:9d:69:d9:b9:dd (DSA)

2048 79:f8:09:ac:d4:e2:32:42:10:49:d3:bd:20:82:85:ec (RSA)"/>
</port>
<port protocol="tcp" portid="80">
<state state="open" reason="syn-ack" reason_ttl="53"/>
<service name="http" product="Apache httpd" version="2.2.14"
extrainfo="(Ubuntu)" method="probed" conf="10">
<cpe>cpe:/a:apache:http_server:2.2.14</cpe>
</service>
<script id="http-title" output="Go ahead and ScanMe!"/>
</port>
</ports>
<os>
<portused state="open" proto="tcp" portid="22"/>
<portused state="closed" proto="tcp" portid="1"/>
<portused state="closed" proto="udp" portid="31289"/>
<osclass type="general purpose" vendor="Linux" osfamily="Linux"
osgen="2.6.X" accuracy="100">
<cpe>cpe:/o:linux:linux_kernel:2.6.39</cpe>
</osclass>
<osmatch name="Linux 2.6.39" accuracy="100" line="39278"/>
</os>
<uptime seconds="23450" lastboot="Fri Sep 9 12:03:04 2011"/>
<distance value="11"/>
<tcpsequence index="199" difficulty="Good luck!"
values="49018209,48C3EBED,495A2E7F,493EF30C,48ED43B3,495A9B0C"/>
<ipidsequence class="All zeros" values="0,0,0,0,0,0"/>
<tcptssequence class="1000HZ"
values="165CC09,165CC6E,165CCD2,165CD36,165CD9A,165CE48"/>
<trace port="256" proto="tcp">
<!-- Several hop elements removed for brevity -->
<hop ttl="9" ipaddr="72.52.92.109" rtt="15.69" host="10gigabitethernet1-1.core1.fmt1.he.net"/>
<hop ttl="10" ipaddr="64.62.250.6" rtt="12.06" host="linode-llc.10gigabitethernet2-3.core1.fmt1.he.net"/>
<hop ttl="11" ipaddr="74.207.244.221" rtt="16.55" host="li86-221.members.linode.com"/>
</trace>
<times srtt="26517" rttvar="19989" to="106473"/>
</host>
<runstats>
<finished time="1315618434" timestr="Fri Sep 9 18:33:54 2011" elapsed="13.66"
summary="Nmap done at Fri Sep 9 18:33:54 2011; 1 IP address (1 host up)
scanned in 13.66 seconds" exit="success"/>
<hosts up="1" down="0" total="1"/>
</runstats>
</nmaprun>
8 không có trong bất kỳ loại đầu ra nào khác. Phương pháp này có thể là # nmap -T4 -A -p 1-1000 -oX - scanme.nmap.org
<?xml version="1.0"?>
<?xml-stylesheet href="file:///usr/local/bin/../share/nmap/nmap.xsl" type="text/xsl"?>
<!-- Nmap 5.59BETA3 scan initiated Fri Sep 9 18:33:41 2011 as:
nmap -T4 -A -p 1-1000 -oX - scanme.nmap.org -->
<nmaprun scanner="nmap" args="nmap -T4 -A -p 1-1000 -oX - scanme.nmap.org" start="1315618421"
startstr="Fri Sep 9 18:33:41 2011" version="5.59BETA3" xmloutputversion="1.03">
<scaninfo type="syn" protocol="tcp" numservices="1000" services="1-1000"/>
<verbose level="0"/>
<debugging level="0"/>
<host starttime="1315618421" endtime="1315618434">
<status state="up" reason="echo-reply"/>
<address addr="74.207.244.221" addrtype="ipv4"/>
<hostnames>
<hostname name="scanme.nmap.org" type="user"/>
<hostname name="li86-221.members.linode.com" type="PTR"/>
</hostnames>
<ports>
<extraports state="closed" count="997">
<extrareasons reason="resets" count="997"/>
</extraports>
<port protocol="tcp" portid="22">
<state state="open" reason="syn-ack" reason_ttl="53"/>
<service name="ssh" product="OpenSSH" version="5.3p1 Debian 3ubuntu7"
extrainfo="protocol 2.0" ostype="Linux" method="probed" conf="10">
<cpe>cpe:/a:openbsd:openssh:5.3p1</cpe>
<cpe>cpe:/o:linux:kernel</cpe>
</service>
<script id="ssh-hostkey"
output="1024 8d:60:f1:7c:ca:b7:3d:0a:d6:67:54:9d:69:d9:b9:dd (DSA)

2048 79:f8:09:ac:d4:e2:32:42:10:49:d3:bd:20:82:85:ec (RSA)"/>
</port>
<port protocol="tcp" portid="80">
<state state="open" reason="syn-ack" reason_ttl="53"/>
<service name="http" product="Apache httpd" version="2.2.14"
extrainfo="(Ubuntu)" method="probed" conf="10">
<cpe>cpe:/a:apache:http_server:2.2.14</cpe>
</service>
<script id="http-title" output="Go ahead and ScanMe!"/>
</port>
</ports>
<os>
<portused state="open" proto="tcp" portid="22"/>
<portused state="closed" proto="tcp" portid="1"/>
<portused state="closed" proto="udp" portid="31289"/>
<osclass type="general purpose" vendor="Linux" osfamily="Linux"
osgen="2.6.X" accuracy="100">
<cpe>cpe:/o:linux:linux_kernel:2.6.39</cpe>
</osclass>
<osmatch name="Linux 2.6.39" accuracy="100" line="39278"/>
</os>
<uptime seconds="23450" lastboot="Fri Sep 9 12:03:04 2011"/>
<distance value="11"/>
<tcpsequence index="199" difficulty="Good luck!"
values="49018209,48C3EBED,495A2E7F,493EF30C,48ED43B3,495A9B0C"/>
<ipidsequence class="All zeros" values="0,0,0,0,0,0"/>
<tcptssequence class="1000HZ"
values="165CC09,165CC6E,165CCD2,165CD36,165CD9A,165CE48"/>
<trace port="256" proto="tcp">
<!-- Several hop elements removed for brevity -->
<hop ttl="9" ipaddr="72.52.92.109" rtt="15.69" host="10gigabitethernet1-1.core1.fmt1.he.net"/>
<hop ttl="10" ipaddr="64.62.250.6" rtt="12.06" host="linode-llc.10gigabitethernet2-3.core1.fmt1.he.net"/>
<hop ttl="11" ipaddr="74.207.244.221" rtt="16.55" host="li86-221.members.linode.com"/>
</trace>
<times srtt="26517" rttvar="19989" to="106473"/>
</host>
<runstats>
<finished time="1315618434" timestr="Fri Sep 9 18:33:54 2011" elapsed="13.66"
summary="Nmap done at Fri Sep 9 18:33:54 2011; 1 IP address (1 host up)
scanned in 13.66 seconds" exit="success"/>
<hosts up="1" down="0" total="1"/>
</runstats>
</nmaprun>
9, có nghĩa là tên dịch vụ chỉ đơn giản là được tra cứu trong <port protocol="tcp" portid="22">
<state state="open" reason="syn-ack" reason_ttl="56"/>
<service name="ssh" product="OpenSSH" version="4.3" extrainfo="protocol 2.0"
method="probed" conf="10"/>
<script id="ssh-hostkey"
output="1024 60:ac:4d:51:b1:cd:85:09:12:16:92:76:1d:5d:27:6e (DSA)

2048 2c:22:75:60:4b:c3:3b:18:a2:97:2c:96:7e:28:dc:dd (RSA)"/>
</port>
<port protocol="tcp" portid="113">
<state state="closed" reason="reset" reason_ttl="56"/>
<service name="auth" method="table" conf="3"/>
</port>
0 dựa trên số cổng và giao thức, hoặc nó có thể là <port protocol="tcp" portid="22">
<state state="open" reason="syn-ack" reason_ttl="56"/>
<service name="ssh" product="OpenSSH" version="4.3" extrainfo="protocol 2.0"
method="probed" conf="10"/>
<script id="ssh-hostkey"
output="1024 60:ac:4d:51:b1:cd:85:09:12:16:92:76:1d:5d:27:6e (DSA)

2048 2c:22:75:60:4b:c3:3b:18:a2:97:2c:96:7e:28:dc:dd (RSA)"/>
</port>
<port protocol="tcp" portid="113">
<state state="closed" reason="reset" reason_ttl="56"/>
<service name="auth" method="table" conf="3"/>
</port>
1, có nghĩa là nó được xác định thông qua hệ thống phát hiện phiên bản. Thuộc tính # nmap -T4 -A -p 1-1000 -oX - scanme.nmap.org
<?xml version="1.0"?>
<?xml-stylesheet href="file:///usr/local/bin/../share/nmap/nmap.xsl" type="text/xsl"?>
<!-- Nmap 5.59BETA3 scan initiated Fri Sep 9 18:33:41 2011 as:
nmap -T4 -A -p 1-1000 -oX - scanme.nmap.org -->
<nmaprun scanner="nmap" args="nmap -T4 -A -p 1-1000 -oX - scanme.nmap.org" start="1315618421"
startstr="Fri Sep 9 18:33:41 2011" version="5.59BETA3" xmloutputversion="1.03">
<scaninfo type="syn" protocol="tcp" numservices="1000" services="1-1000"/>
<verbose level="0"/>
<debugging level="0"/>
<host starttime="1315618421" endtime="1315618434">
<status state="up" reason="echo-reply"/>
<address addr="74.207.244.221" addrtype="ipv4"/>
<hostnames>
<hostname name="scanme.nmap.org" type="user"/>
<hostname name="li86-221.members.linode.com" type="PTR"/>
</hostnames>
<ports>
<extraports state="closed" count="997">
<extrareasons reason="resets" count="997"/>
</extraports>
<port protocol="tcp" portid="22">
<state state="open" reason="syn-ack" reason_ttl="53"/>
<service name="ssh" product="OpenSSH" version="5.3p1 Debian 3ubuntu7"
extrainfo="protocol 2.0" ostype="Linux" method="probed" conf="10">
<cpe>cpe:/a:openbsd:openssh:5.3p1</cpe>
<cpe>cpe:/o:linux:kernel</cpe>
</service>
<script id="ssh-hostkey"
output="1024 8d:60:f1:7c:ca:b7:3d:0a:d6:67:54:9d:69:d9:b9:dd (DSA)

2048 79:f8:09:ac:d4:e2:32:42:10:49:d3:bd:20:82:85:ec (RSA)"/>
</port>
<port protocol="tcp" portid="80">
<state state="open" reason="syn-ack" reason_ttl="53"/>
<service name="http" product="Apache httpd" version="2.2.14"
extrainfo="(Ubuntu)" method="probed" conf="10">
<cpe>cpe:/a:apache:http_server:2.2.14</cpe>
</service>
<script id="http-title" output="Go ahead and ScanMe!"/>
</port>
</ports>
<os>
<portused state="open" proto="tcp" portid="22"/>
<portused state="closed" proto="tcp" portid="1"/>
<portused state="closed" proto="udp" portid="31289"/>
<osclass type="general purpose" vendor="Linux" osfamily="Linux"
osgen="2.6.X" accuracy="100">
<cpe>cpe:/o:linux:linux_kernel:2.6.39</cpe>
</osclass>
<osmatch name="Linux 2.6.39" accuracy="100" line="39278"/>
</os>
<uptime seconds="23450" lastboot="Fri Sep 9 12:03:04 2011"/>
<distance value="11"/>
<tcpsequence index="199" difficulty="Good luck!"
values="49018209,48C3EBED,495A2E7F,493EF30C,48ED43B3,495A9B0C"/>
<ipidsequence class="All zeros" values="0,0,0,0,0,0"/>
<tcptssequence class="1000HZ"
values="165CC09,165CC6E,165CCD2,165CD36,165CD9A,165CE48"/>
<trace port="256" proto="tcp">
<!-- Several hop elements removed for brevity -->
<hop ttl="9" ipaddr="72.52.92.109" rtt="15.69" host="10gigabitethernet1-1.core1.fmt1.he.net"/>
<hop ttl="10" ipaddr="64.62.250.6" rtt="12.06" host="linode-llc.10gigabitethernet2-3.core1.fmt1.he.net"/>
<hop ttl="11" ipaddr="74.207.244.221" rtt="16.55" host="li86-221.members.linode.com"/>
</trace>
<times srtt="26517" rttvar="19989" to="106473"/>
</host>
<runstats>
<finished time="1315618434" timestr="Fri Sep 9 18:33:54 2011" elapsed="13.66"
summary="Nmap done at Fri Sep 9 18:33:54 2011; 1 IP address (1 host up)
scanned in 13.66 seconds" exit="success"/>
<hosts up="1" down="0" total="1"/>
</runstats>
</nmaprun>
8 đo lường sự tin cậy NMAP có tên dịch vụ là chính xác. Các giá trị dao động từ một (ít tự tin nhất) đến mười. NMAP chỉ có mức độ tin cậy là 3 cho các cổng được xác định bằng cách tra cứu bảng, trong khi nó rất tự tin (cấp 10) mà cổng 22 của ví dụ & NBSP; Máy chủ SSH xác định là OpenSsh.Một khía cạnh khác mà một số người dùng thấy khó hiểu là các thuộc tính
<port protocol="tcp" portid="22">
<state state="open" reason="syn-ack" reason_ttl="56"/>
<service name="ssh" product="OpenSSH" version="4.3" extrainfo="protocol 2.0"
method="probed" conf="10"/>
<script id="ssh-hostkey"
output="1024 60:ac:4d:51:b1:cd:85:09:12:16:92:76:1d:5d:27:6e (DSA)

2048 2c:22:75:60:4b:c3:3b:18:a2:97:2c:96:7e:28:dc:dd (RSA)"/>
</port>
<port protocol="tcp" portid="113">
<state state="closed" reason="reset" reason_ttl="56"/>
<service name="auth" method="table" conf="3"/>
</port>
3 và <port protocol="tcp" portid="22">
<state state="open" reason="syn-ack" reason_ttl="56"/>
<service name="ssh" product="OpenSSH" version="4.3" extrainfo="protocol 2.0"
method="probed" conf="10"/>
<script id="ssh-hostkey"
output="1024 60:ac:4d:51:b1:cd:85:09:12:16:92:76:1d:5d:27:6e (DSA)

2048 2c:22:75:60:4b:c3:3b:18:a2:97:2c:96:7e:28:dc:dd (RSA)"/>
</port>
<port protocol="tcp" portid="113">
<state state="closed" reason="reset" reason_ttl="56"/>
<service name="auth" method="table" conf="3"/>
</port>
4 giữ dấu thời gian được đưa ra trong thời gian Unix, số giây kể từ ngày 1 tháng 1 năm 1970. Điều này thường dễ dàng hơn cho các chương trình để xử lý. Để thuận tiện cho độc giả của con người, các phiên bản 3.78 trở lên bao gồm thời gian lịch tương đương được viết trong các thuộc tính <port protocol="tcp" portid="22">
<state state="open" reason="syn-ack" reason_ttl="56"/>
<service name="ssh" product="OpenSSH" version="4.3" extrainfo="protocol 2.0"
method="probed" conf="10"/>
<script id="ssh-hostkey"
output="1024 60:ac:4d:51:b1:cd:85:09:12:16:92:76:1d:5d:27:6e (DSA)

2048 2c:22:75:60:4b:c3:3b:18:a2:97:2c:96:7e:28:dc:dd (RSA)"/>
</port>
<port protocol="tcp" portid="113">
<state state="closed" reason="reset" reason_ttl="56"/>
<service name="auth" method="table" conf="3"/>
</port>
5 và <port protocol="tcp" portid="22">
<state state="open" reason="syn-ack" reason_ttl="56"/>
<service name="ssh" product="OpenSSH" version="4.3" extrainfo="protocol 2.0"
method="probed" conf="10"/>
<script id="ssh-hostkey"
output="1024 60:ac:4d:51:b1:cd:85:09:12:16:92:76:1d:5d:27:6e (DSA)

2048 2c:22:75:60:4b:c3:3b:18:a2:97:2c:96:7e:28:dc:dd (RSA)"/>
</port>
<port protocol="tcp" portid="113">
<state state="closed" reason="reset" reason_ttl="56"/>
<service name="auth" method="table" conf="3"/>
</port>
6.Dòng lệnh ban đầu (mảng
<port protocol="tcp" portid="22">
<state state="open" reason="syn-ack" reason_ttl="56"/>
<service name="ssh" product="OpenSSH" version="4.3" extrainfo="protocol 2.0"
method="probed" conf="10"/>
<script id="ssh-hostkey"
output="1024 60:ac:4d:51:b1:cd:85:09:12:16:92:76:1d:5d:27:6e (DSA)

2048 2c:22:75:60:4b:c3:3b:18:a2:97:2c:96:7e:28:dc:dd (RSA)"/>
</port>
<port protocol="tcp" portid="113">
<state state="closed" reason="reset" reason_ttl="56"/>
<service name="auth" method="table" conf="3"/>
</port>
7) được lưu trữ trong thuộc tính <port protocol="tcp" portid="22">
<state state="open" reason="syn-ack" reason_ttl="56"/>
<service name="ssh" product="OpenSSH" version="4.3" extrainfo="protocol 2.0"
method="probed" conf="10"/>
<script id="ssh-hostkey"
output="1024 60:ac:4d:51:b1:cd:85:09:12:16:92:76:1d:5d:27:6e (DSA)

2048 2c:22:75:60:4b:c3:3b:18:a2:97:2c:96:7e:28:dc:dd (RSA)"/>
</port>
<port protocol="tcp" portid="113">
<state state="closed" reason="reset" reason_ttl="56"/>
<service name="auth" method="table" conf="3"/>
</port>
8. Đối số được phân tách bằng khoảng trắng. Các đối số ban đầu chứa khoảng trắng được đặt trong các trích dẫn kép (xuất hiện dưới dạng <port protocol="tcp" portid="22">
<state state="open" reason="syn-ack" reason_ttl="56"/>
<service name="ssh" product="OpenSSH" version="4.3" extrainfo="protocol 2.0"
method="probed" conf="10"/>
<script id="ssh-hostkey"
output="1024 60:ac:4d:51:b1:cd:85:09:12:16:92:76:1d:5d:27:6e (DSA)

2048 2c:22:75:60:4b:c3:3b:18:a2:97:2c:96:7e:28:dc:dd (RSA)"/>
</port>
<port protocol="tcp" portid="113">
<state state="closed" reason="reset" reason_ttl="56"/>
<service name="auth" method="table" conf="3"/>
</port>
9 trong XML). Các nhân vật riêng lẻ cũng có thể được thoát ra với các dấu gạch chéo ngược trong các chuỗi được trích dẫn.NMAP bao gồm định nghĩa loại tài liệu (DTD) cho phép trình phân tích cú pháp XML xác nhận đầu ra NMAP XML. Mặc dù nó chủ yếu nhằm sử dụng theo chương trình, nhưng nó cũng có thể giúp con người diễn giải đầu ra NMAP XML. DTD xác định các yếu tố pháp lý của định dạng và thường liệt kê các thuộc tính và giá trị mà chúng có thể thực hiện. Nó được sao chép trong Phụ lục & NBSP; A, NMAP XML đầu ra DTD.
Sử dụng đầu ra XML
Định dạng NMAP XML có thể được sử dụng theo nhiều cách mạnh mẽ, mặc dù rất ít người dùng thực sự tận dụng bất kỳ lợi thế nào của nó. Tôi tin rằng điều này là do sự thiếu kinh nghiệm của nhiều người dùng với XML, kết hợp với việc thiếu tài liệu thực tế, hướng giải pháp về việc sử dụng định dạng NMAP XML. Chương này cung cấp một số ví dụ thực tế, bao gồm cả phần có tên là thao tác đầu ra XML với Perl, phần gọi là đầu ra của một cơ sở dữ liệu, và phần có tên là Tạo báo cáo HTML.
Một lợi thế chính của XML là bạn không cần phải viết trình phân tích cú pháp của riêng mình như bạn làm cho các loại đầu ra NMAP chuyên dụng như đầu ra tương tác và tương tác. Bất kỳ trình phân tích cú pháp XML chung nào cũng nên làm.
Đầu ra NMAP XML tất nhiên có thể được xem trong bất kỳ trình soạn thảo văn bản hoặc trình soạn thảo XML nào. Một số chương trình bảng tính, bao gồm Microsoft Excel, có thể nhập trực tiếp dữ liệu NMAP XML để xem. Các bộ xử lý XML có mục đích chung này chia sẻ giới hạn rằng họ xử lý NMAP XML một cách chung, giống như bất kỳ tệp XML nào khác. Họ không hiểu tầm quan trọng tương đối của các yếu tố, cũng như cách tổ chức dữ liệu để trình bày hữu ích hơn. Việc sử dụng các bộ xử lý XML chuyên dụng có ý nghĩa về đầu ra NMAP XML là chủ đề của các phần sau.
Ngôn ngữ đánh dấu có thể mở rộng (XML) là một định dạng tệp có cấu trúc cây được biết đến rộng rãi được hỗ trợ bởi NMAP. Kết quả quét có thể được xuất hoặc ghi vào tệp XML và được sử dụng để phân tích hoặc các tác vụ bổ sung khác.a widely known, tree-structured file format supported by Nmap. Scan results can be exported or written into an XML file and used for analysis or other additional tasks.
Định dạng đầu ra linh hoạt NMAP cũng không ngoại lệ-các tham số dòng lệnh mạnh mẽ của nó cho phép bạn điều chỉnh cách bạn muốn chạy công cụ.Ví dụ: bạn có thể chọn định dạng đầu ra ưa thích của mình trong số các định dạng sau: -on (bình thường), -ox (xml), -og (grepable) hoặc -os (scriptkiddie).-oN (normal), -oX (XML), -oG (grepable), or -oS (scriptkiddie).