我想使用Python腳本來使用nmap。我意識到有一個用於python-nmap的軟件包。但是我想創建一個簡單的腳本來解釋nmap命令的輸出,然後根據它的輸出做更多的事情。 嘗試使用check_output( 「NMAP」)像這個鏈接: Running shell command from Python and capturing the output 通過運行這個: sp.check_outpu
我有一個運行在EMR中的YARN羣集。當SSH到主節點,並運行nmap 10.0.0.254我得到以下結果 Starting Nmap 5.51 (http://nmap.org) at 2015-06-10 00:17 UTC
Nmap scan report for ip-10-0-0-254.ec2.internal (10.0.0.254)
Host is up (0.00045s l