Land #6908, Fix importing of a zipped workspace
commit
e382b2e468
|
@ -129,7 +129,7 @@ GEM
|
|||
activemodel (~> 4.2.6)
|
||||
activesupport (~> 4.2.6)
|
||||
railties (~> 4.2.6)
|
||||
metasploit-credential (2.0.1)
|
||||
metasploit-credential (2.0.2)
|
||||
metasploit-concern
|
||||
metasploit-model
|
||||
metasploit_data_models
|
||||
|
|
|
@ -49,7 +49,7 @@ module Msf::DBManager::Import::MetasploitFramework::Zip
|
|||
|
||||
# Parses host Nokogiri::XML::Element
|
||||
def parse_zip_host(host, wspace, bl, allow_yaml, btag, args, basedir, host_info, &block)
|
||||
host_info[host.at("id").text.to_s.strip] = nils_for_nulls(host.at("address").text.to_s.strip)
|
||||
host_info[host.at("id").text.to_s.strip] = nils_for_nulls(host.at("address").text.to_s.strip) unless host.at('address').nil?
|
||||
end
|
||||
|
||||
# Parses loot Nokogiri::XML::Element
|
||||
|
|
|
@ -28,7 +28,7 @@ module Msf::DBManager::Import::Report
|
|||
report_id = report_report(report_info)
|
||||
|
||||
# Handle artifacts
|
||||
report.elements['artifacts'].elements.each do |artifact|
|
||||
report.elements.at('artifacts').elements.each do |artifact|
|
||||
artifact_opts = {}
|
||||
artifact.elements.each do |attr|
|
||||
skip_nodes = %w|id accessed-at|
|
||||
|
|
Loading…
Reference in New Issue