Include Msf::Post::Windows::Error

bug/bundler_fix
jvazquez-r7 2014-01-02 13:41:37 -06:00
parent ec8d24c376
commit d5e196707d
1 changed files with 4 additions and 3 deletions

View File

@ -8,6 +8,7 @@ class Metasploit3 < Msf::Post
include Msf::Post::File
include Msf::Post::Windows::Priv
include Msf::Post::Windows::Services
include Msf::Post::Windows::Error
START_TYPE = {
"demand" => "SERVICE_DEMAND_START",
@ -81,11 +82,11 @@ class Metasploit3 < Msf::Post
if inst
ss = service_start(name)
case ss
when Windows::Error::SUCCESS;
when Windows::Error::SUCCESS
print_good("Driver loaded successfully.")
when Windows::Error::SERVICE_ALREADY_RUNNING;
when Windows::Error::SERVICE_ALREADY_RUNNING
print_error("Service already started.")
when Windows::Error::SERVICE_DISABLED;
when Windows::Error::SERVICE_DISABLED
print_error("Service disabled.")
else
print_error("There was an error starting the service.")