From 79bf80e6bf4fdb658d7ec7192ba0295669f1f388 Mon Sep 17 00:00:00 2001 From: William Vu Date: Sat, 21 Jun 2014 15:35:03 -0500 Subject: [PATCH] Add generic error handling Just in case a factory reset happens to fail. --- modules/auxiliary/admin/chromecast/chromecast_reset.rb | 2 ++ 1 file changed, 2 insertions(+) diff --git a/modules/auxiliary/admin/chromecast/chromecast_reset.rb b/modules/auxiliary/admin/chromecast/chromecast_reset.rb index 8a181bb512..9f4b700ae3 100644 --- a/modules/auxiliary/admin/chromecast/chromecast_reset.rb +++ b/modules/auxiliary/admin/chromecast/chromecast_reset.rb @@ -32,6 +32,8 @@ class Metasploit4 < Msf::Auxiliary if res && res.code == 200 print_good('Factory reset performed') + elsif res + print_error("An error occurred: #{res.code} #{res.message}") end end