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 d7887b5 commit 13afbc4Copy full SHA for 13afbc4
modules/post/android/manage/remove_lock_root.rb
@@ -4,11 +4,12 @@
4
##
5
6
require 'msf/core'
7
-require 'rex'
+require 'msf/core/post/android'
8
9
class Metasploit4 < Msf::Post
10
11
include Msf::Post::Common
12
+ include Msf::Post::Android::Priv
13
14
def initialize(info={})
15
super( update_info( info, {
@@ -28,10 +29,9 @@ def initialize(info={})
28
29
end
30
31
def run
- id = cmd_exec('id')
32
- unless id =~ /root/
33
- #print_error("This module requires root permissions")
34
- #return
+ unless is_root?
+ print_error("This module requires root permissions.")
+ return
35
36
37
%W{
0 commit comments