Print Spooler is a Windows service that manages print jobs sent to a printer. It queues print requests and sends them to the printer when ready.
PrintNightmare (CVE-2021-1675/CVE-2021-34527) is a vulnerability in the RpcAddPrinterDriver function of Print Spooler, which is used for adding printer drivers. Normally, only users with SeLoadDriverPrivilege should be able to do this.
The flaw allows an attacker to exploit this function to run arbitrary code with elevated privileges, even if they don't have SeLoadDriverPrivilege.
1 - Check Spooler Service
First we make sure the Spooler is running:
PS C:\hacker> ls \\localhost\pipe\spoolss
Directory: \\localhost\pipe
Mode LastWriteTime Length Name
---- ------------- ------ ----
spoolss
If the service isn't running we get a "path does not exist" error.