Land #6908, Fix importing of a zipped workspace

bug/bundler_fix
Brent Cook 2016-05-24 01:10:24 -05:00
commit e382b2e468
No known key found for this signature in database
GPG Key ID: 1FFAA0B24B708F96
3 changed files with 3 additions and 3 deletions

View File

@ -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

View File

@ -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

View File

@ -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|