Skip to content

Commit

Permalink
Land #18799, Fix revision number checks
Browse files Browse the repository at this point in the history
Fix revision number checks for cve_2020_17136.rb
  • Loading branch information
smcintyre-r7 committed Feb 12, 2024
2 parents 88e1e2e + 436efad commit 8eb5aa6
Showing 1 changed file with 6 additions and 6 deletions.
12 changes: 6 additions & 6 deletions modules/exploits/windows/local/cve_2020_17136.rb
Original file line number Diff line number Diff line change
Expand Up @@ -121,17 +121,17 @@ def check
version = get_version_info

# Build numbers taken from https://www.qualys.com/research/security-alerts/2020-03-10/microsoft/
if version.build_number == Msf::WindowsVersion::Win10_20H2 && version.build_number.revision_number.between?(0, 684)
if version.build_number == Msf::WindowsVersion::Win10_20H2 && version.revision_number.between?(0, 684)
return CheckCode::Appears('A vulnerable Windows 10 20H2 build was detected!')
elsif version.build_number == Msf::WindowsVersion::Win10_2004 && version.build_number.revision_number.between?(0, 684)
elsif version.build_number == Msf::WindowsVersion::Win10_2004 && version.revision_number.between?(0, 684)
return CheckCode::Appears('A vulnerable Windows 10 20H1 build was detected!')
elsif version.build_number == Msf::WindowsVersion::Win10_1909 && version.build_number.revision_number.between?(0, 1255)
elsif version.build_number == Msf::WindowsVersion::Win10_1909 && version.revision_number.between?(0, 1255)
return CheckCode::Appears('A vulnerable Windows 10 v1909 build was detected!')
elsif version.build_number == Msf::WindowsVersion::Win10_1903 && version.build_number.revision_number.between?(0, 1255)
elsif version.build_number == Msf::WindowsVersion::Win10_1903 && version.revision_number.between?(0, 1255)
return CheckCode::Appears('A vulnerable Windows 10 v1903 build was detected!')
elsif version.build_number == Msf::WindowsVersion::Win10_1809 && version.build_number.revision_number.between?(0, 1636)
elsif version.build_number == Msf::WindowsVersion::Win10_1809 && version.revision_number.between?(0, 1636)
return CheckCode::Appears('A vulnerable Windows 10 v1809 build was detected!')
elsif version.build_number == Msf::WindowsVersion::Win10_1803 && version.build_number.revision_number.between?(0, 1901)
elsif version.build_number == Msf::WindowsVersion::Win10_1803 && version.revision_number.between?(0, 1901)
return CheckCode::Appears('A vulnerable Windows 10 v1803 build was detected!')
else
return CheckCode::Safe('The build number of the target machine does not appear to be a vulnerable version!')
Expand Down

0 comments on commit 8eb5aa6

Please sign in to comment.