While this has application in protecting a system from rogue or trojan apps, supposedly a shutdown privilege would be something granted manually by a SYSTEM level process that is trusted, so that if the system
is not recoverable a graceful shutdown can be attempted with minimal process switching; which might make things worse. If that can be bypassed so a virus could exploit it, that's the API I'd look to change, not so much at the point of this diff. Also, the
code is double calling the ShutdownPrivelege check where only the first appears necessary, unless there's a significant chance of a task switch.
------ Original message------
From: Alex Ionescu
Date: Sun, Apr 1, 2018 10:22 PM
To: ReactOS Development List;Hermès Bélusca-Maïto;
Cc: Linda Wang;
Subject:Re: [ros-dev] [ros-diffs] 02/08: [NTOSKRNL] Forbid processes without the Tcb prvilege to perform a user-mode hard-error BSOD.