add arch check
parent
2914ebf631
commit
e53de896e7
|
@ -137,6 +137,13 @@ class MetasploitModule < Msf::Exploit::Local
|
|||
end
|
||||
vprint_good 'smap not present'
|
||||
|
||||
arch = kernel_hardware
|
||||
unless arch.include? 'x86_64'
|
||||
vprint_error "System architecture #{arch} is not supported"
|
||||
return CheckCode::Safe
|
||||
end
|
||||
vprint_good "System architecture #{arch} is supported"
|
||||
|
||||
distro = cmd_exec('grep DISTRIB_CODENAME /etc/lsb-release').split('=')[1].to_s.downcase
|
||||
unless kernels.include? "\"#{distro}\", \"#{kernel_release}\""
|
||||
vprint_error "Kernel #{kernel_release} on #{distro} not supported"
|
||||
|
|
Loading…
Reference in New Issue