Windows SeriousSAM HiveNightmare Registry Read Vulnerability - Nessus

High   Plugin ID: 152100

This page contains detailed information about the Windows SeriousSAM HiveNightmare Registry Read Vulnerability Nessus plugin including available exploits and PoCs found on GitHub, in Metasploit or Exploit-DB for verifying of this vulnerability.

Plugin Overview


ID: 152100
Name: Windows SeriousSAM HiveNightmare Registry Read Vulnerability
Filename: smb_nt_serious_sam_check.nbin
Vulnerability Published: 2021-07-20
This Plugin Published: 2021-07-27
Last Modification Time: 2022-05-03
Plugin Version: 1.30
Plugin Type: local
Plugin Family: Windows
Dependencies: smb_enum_services.nasl, smb_hotfixes.nasl
Required KB Items [?]: SMB/login, SMB/password, SMB/Services/Enumerated

Vulnerability Information


Severity: High
Vulnerability Published: 2021-07-20
Patch Published: 2021-07-20
CVE [?]: CVE-2021-36934
CPE [?]: cpe:/o:microsoft:windows
Exploited by Malware: True

Synopsis

The remote Windows host is affected by an elevation of privilege vulnerability.

Description

An elevation of privilege vulnerability exists because of overly permissive Access Control Lists (ACLs) on multiple system files, including the Security Accounts Manager (SAM) database. An attacker who successfully exploited this vulnerability could run arbitrary code with SYSTEM privileges. An attacker could then install programs; view, change, or delete data; or create new accounts with full user rights.

Solution

Per the vendor advisory, restrict access to the contents of %windir%\system32\config and Delete Volume Shadow Copy Service (VSS) shadow copies.

Public Exploits


Target Network Port(s): 139, 445
Target Asset(s): N/A
Exploit Available: True (GitHub)
Exploit Ease: Exploits are available

Here's the list of publicly known exploits and PoCs for verifying the Windows SeriousSAM HiveNightmare Registry Read Vulnerability vulnerability:

  1. GitHub: https://github.com/0x0D1n/CVE-2021-36934
    [CVE-2021-36934]
  2. GitHub: https://github.com/0xsyk0/GoHiveShadow
    [CVE-2021-36934]
  3. GitHub: https://github.com/0xsyr0/OSCP
    [CVE-2021-36934]
  4. GitHub: https://github.com/AlAIAL90/CVE-2021-36934
    [CVE-2021-36934: PoC for exploiting CVE-2021-36934 : Windows Elevation of Privilege Vulnerability]
  5. GitHub: https://github.com/Ascotbe/Kernelhub
    [CVE-2021-36934]
  6. GitHub: https://github.com/AttackTeamFamily/HiveNightmare
    [CVE-2021-36934: HiveNightmare/SeriousSAM(CVE_2021_36934)]
  7. GitHub: https://github.com/CrackerCat/HiveNightmare
    [CVE-2021-36934]
  8. GitHub: https://github.com/FireFart/hivenightmare
    [CVE-2021-36934]
  9. GitHub: https://github.com/GossiTheDog/HiveNightmare
    [CVE-2021-36934]
  10. GitHub: https://github.com/Mikasazero/Cobalt-Strike
    [CVE-2021-36934]
  11. GitHub: https://github.com/Mr-xn/Penetration_Testing_POC
    [CVE-2021-36934]
  12. GitHub: https://github.com/OlivierLaflamme/CVE-2021-36934-export-shadow-volume-POC
    [CVE-2021-36934]
  13. GitHub: https://github.com/OlivierLaflamme/CVE-2021-36934_export_shadow_volume
    [CVE-2021-36934]
  14. GitHub: https://github.com/Operational-Sciences-Group/Project-Beewolf
    [CVE-2021-36934]
  15. GitHub: https://github.com/S1ckB0y1337/Active-Directory-Exploitation-Cheat-Sheet
    [CVE-2021-36934]
  16. GitHub: https://github.com/SexyBeast233/SecBooks
    [CVE-2021-36934]
  17. GitHub: https://github.com/YangSirrr/YangsirStudyPlan
    [CVE-2021-36934]
  18. GitHub: https://github.com/b4rtik/SharpKatz
    [CVE-2021-36934]
  19. GitHub: https://github.com/cfalta/MicrosoftWontFixList
    [CVE-2021-36934]
  20. GitHub: https://github.com/creeper-exe/creeper-exe
    [CVE-2021-36934]
  21. GitHub: https://github.com/geeksniper/windows-privilege-escalation
    [CVE-2021-36934]
  22. GitHub: https://github.com/guervild/BOFs
    [CVE-2021-36934]
  23. GitHub: https://github.com/izj007/wechat
    [CVE-2021-36934]
  24. GitHub: https://github.com/kas0n/RedTeam-Articles
    [CVE-2021-36934]
  25. GitHub: https://github.com/mr-r3b00t/HiveNigtmare
    [CVE-2021-36934]
  26. GitHub: https://github.com/mwarnerblu/GoHN
    [CVE-2021-36934]
  27. GitHub: https://github.com/pyonghe/HiveNightmareChecker
    [CVE-2021-36934]
  28. GitHub: https://github.com/rnbochsr/atlas
    [CVE-2021-36934]
  29. GitHub: https://github.com/wolf0x/HiveNightmare
    [CVE-2021-36934]
  30. GitHub: https://github.com/wolf0x/PSHiveNightmare
    [CVE-2021-36934]
  31. GitHub: https://github.com/wsummerhill/CobaltStrike_RedTeam_CheatSheet
    [CVE-2021-36934]
  32. GitHub: https://github.com/ycdxsb/WindowsPrivilegeEscalation
    [CVE-2021-36934]
  33. GitHub: https://github.com/bytesizedalex/CVE-2021-36934
    [CVE-2021-36934: CVE-2021-36934 PowerShell scripts]
  34. GitHub: https://github.com/chron1k/oxide_hive
    [CVE-2021-36934: Exploit for CVE-2021-36934]
  35. GitHub: https://github.com/cube0x0/CVE-2021-36934
    [CVE-2021-36934: C# PoC for CVE-2021-36934/HiveNightmare/SeriousSAM]
  36. GitHub: https://github.com/exploitblizzard/CVE-2021-36934
    [CVE-2021-36934: HiveNightmare aka SeriousSAM]
  37. GitHub: https://github.com/grishinpv/poc_CVE-2021-36934
    [CVE-2021-36934: POC experiments with Volume Shadow copy Service (VSS)]
  38. GitHub: https://github.com/HuskyHacks/ShadowSteal
    [CVE-2021-36934: Pure Nim implementation for exploiting CVE-2021-36934, the SeriousSAM local ...]
  39. GitHub: https://github.com/irissentinel/CVE-2021-36934
    [CVE-2021-36934: CVE-2021-36934 HiveNightmare vulnerability checker and workaround]
  40. GitHub: https://github.com/jmaddington/Serious-Sam---CVE-2021-36934-Mitigation-for-Datto-RMM
    [CVE-2021-36934: This PowerShell script will take the mitigation measures for CVE-2021-36934 ...]
  41. GitHub: https://github.com/JoranSlingerland/CVE-2021-36934
    [CVE-2021-36934: Fix for the CVE-2021-36934]
  42. GitHub: https://github.com/n3tsurge/CVE-2021-36934
    [CVE-2021-36934: Detection and Mitigation script for CVE-2021-36934 (HiveNightmare aka. SeriousSam) ...]
  43. GitHub: https://github.com/romarroca/SeriousSam
    [CVE-2021-36934: HiveNightmare a.k.a. SeriousSam Local Privilege Escalation in Windows – ...]
  44. GitHub: https://github.com/shaktavist/SeriousSam
    [CVE-2021-36934: Windows Elevation of Privilege Vulnerability CVE-2021-36934]
  45. GitHub: https://github.com/Sp00p64/PyNightmare
    [CVE-2021-36934: PoC for CVE-2021-36934 Aka HiveNightmare/SeriousSAM fully written in python3]
  46. GitHub: https://github.com/tda90/CVE-2021-36934
    [CVE-2021-36934: CVE-2021-36934 PowerShell Fix]
  47. GitHub: https://github.com/VertigoRay/CVE-2021-36934
    [CVE-2021-36934: Windows Elevation of Privilege Vulnerability (SeriousSAM)]
  48. GitHub: https://github.com/websecnl/CVE-2021-36934
    [CVE-2021-36934: SeriousSAM Auto Exploiter]
  49. GitHub: https://github.com/Wh04m1001/VSSCopy
    [CVE-2021-36934: Small and dirty PoC for CVE-2021-36934]
  50. GitHub: https://github.com/WiredPulse/Invoke-HiveDreams
    [CVE-2021-36934: A capability to identify and remediate CVE-2021-36934 (HiveNightmare)]
  51. GitHub: https://github.com/WiredPulse/Invoke-HiveNightmare
    [CVE-2021-36934: PoC for CVE-2021-36934, which enables a standard user to be able to retrieve the ...]

Before running any exploit against any system, make sure you are authorized by the owner of the target system(s) to perform such activity. In any other case, this would be considered as an illegal activity.

WARNING: Beware of using unverified exploits from sources such as GitHub or Exploit-DB. These exploits and PoCs could contain malware. For more information, see how to use exploits safely.

Risk Information


CVSS Score Source [?]: CVE-2021-36934
CVSS V2 Vector: AV:L/AC:L/Au:N/C:P/I:P/A:P/E:H/RL:OF/RC:C
CVSS Base Score:4.6 (Medium)
Impact Subscore:6.4
Exploitability Subscore:3.9
CVSS Temporal Score:4.0 (Medium)
CVSS Environmental Score:NA (None)
Modified Impact Subscore:NA
Overall CVSS Score:4.0 (Medium)
CVSS V3 Vector: CVSS:3.0/AV:L/AC:L/PR:L/UI:N/S:U/C:H/I:H/A:H/E:H/RL:O/RC:C
CVSS Base Score:7.8 (High)
Impact Subscore:5.9
Exploitability Subscore:1.8
CVSS Temporal Score:7.5 (High)
CVSS Environmental Score:NA (None)
Modified Impact Subscore:NA
Overall CVSS Score:7.5 (High)
STIG Severity [?]: I
STIG Risk Rating: High

Go back to menu.

Plugin Source


The smb_nt_serious_sam_check.nbin Nessus plugin is distributed in a propriatory binary format and its source code is protected. This script is Copyright (C) 2021-2022 and is owned by Tenable, Inc. or an Affiliate thereof.

The latest version of this script can be found in these locations depending on your platform:

  • Linux / Unix:
    /opt/nessus/lib/nessus/plugins/smb_nt_serious_sam_check.nbin
  • Windows:
    C:\ProgramData\Tenable\Nessus\nessus\plugins\smb_nt_serious_sam_check.nbin
  • Mac OS X:
    /Library/Nessus/run/lib/nessus/plugins/smb_nt_serious_sam_check.nbin

Go back to menu.

How to Run


Here is how to run the Windows SeriousSAM HiveNightmare Registry Read Vulnerability as a standalone plugin via the Nessus web user interface (https://localhost:8834/):

  1. Click to start a New Scan.
  2. Select Advanced Scan.
  3. Navigate to the Plugins tab.
  4. On the top right corner click to Disable All plugins.
  5. On the left side table select Windows plugin family.
  6. On the right side table select Windows SeriousSAM HiveNightmare Registry Read Vulnerability plugin ID 152100.
  7. Specify the target on the Settings tab and click to Save the scan.
  8. Run the scan.

Here are a few examples of how to run the plugin in the command line. Note that the examples below demonstrate the usage on the Linux / Unix platform.

Basic usage:

/opt/nessus/bin/nasl smb_nt_serious_sam_check.nbin -t <IP/HOST>

Run the plugin with audit trail message on the console:

/opt/nessus/bin/nasl -a smb_nt_serious_sam_check.nbin -t <IP/HOST>

Run the plugin with trace script execution written to the console (useful for debugging):

/opt/nessus/bin/nasl -T - smb_nt_serious_sam_check.nbin -t <IP/HOST>

Run the plugin with using a state file for the target and updating it (useful for running multiple plugins on the target):

/opt/nessus/bin/nasl -K /tmp/state smb_nt_serious_sam_check.nbin -t <IP/HOST>

Go back to menu.

References


IAVA | Information Assurance Vulnerability Alert:
  • 2021-A-0374-S
See also: Similar and related Nessus plugins:
  • 122927 - Windows Deployment Services TFTP Server Remote Code Execution Vulnerability
  • 132101 - Windows Speculative Execution Configuration Check
  • 139239 - Windows Security Feature Bypass in Secure Boot (BootHole)
  • 108811 - Windows Server 2008 Critical RCE Vulnerabilities (uncredentialed) (PCI/DSS)
  • 152435 - KB5005030: Windows 10 Version 1809 and Windows Server 2019 Security Update (August 2021)
  • 152430 - KB5005031: Windows 10 Version 1909 Security Update (August 2021)
  • 152431 - KB5005033: Windows 10 Version 2004 / Windows 10 Version 20H2 / Windows 10 Version 21H1 Security Update (August 2021)
  • 152422 - KB5005040: Windows 10 version 1507 LTS Security Update (August 2021)
  • 152434 - KB5005043: Windows 10 Version 1607 and Windows Server 2016 Security Update (August 2021)
  • 152436 - KB5005089: Windows Server 2008 R2 Security Update (August 2021)
  • 152421 - KB5005094: Windows Server 2012 Security Update (August 2021)
  • 152425 - KB5005095: Windows Server 2008 Security Update (August 2021)
  • 152433 - KB5005106: Windows Server 2012 R2 Security Update (August 2021)
  • 152102 - Microsoft Windows EFSRPC NTLM Reflection Elevation of Privilege (PetitPotam) (Remote)

Version


This page has been produced using Nessus Professional 10.1.2 (#68) LINUX, Plugin set 202205072148.
Plugin file smb_nt_serious_sam_check.nbin version 1.30. For more plugins, visit the Nessus Plugin Library.

Go back to menu.