Files
metasploit-gs/lib/msf/core/post/android/system.rb
T

Ignoring revisions in .git-blame-ignore-revs. Click here to bypass and see the normal blame view.

27 lines
523 B
Ruby
Raw Normal View History

2015-08-24 18:37:25 -05:00
# -*- coding: binary -*-
module Msf
class Post
module Android
module System
include Msf::Post::Common
include Msf::Post::File
# Returns system information from build.prop.
#
# @return [Hash] System information.
2015-08-25 23:23:26 -05:00
def get_build_prop
2015-08-24 18:37:25 -05:00
sys_data = {}
2015-08-25 23:23:26 -05:00
build_prop = cmd_exec('cat /system/build.prop')
2015-08-24 18:37:25 -05:00
return sys_data if build_prop.blank?
build_prop.scan(/(.+)=(.+)/i).collect {|e| Hash[*e]}.each do |setting|
sys_data.merge!(setting)
end
return sys_data
end
end ; end ; end ; end