Goal:
On my PC, there is a background script (Process A) that runs on startup with Administrator Level Permissions on the Standard Level Account (Account X). I would like to use this script, with it's elevated permissions to modify the process-level permissions on a process (Process B) that is run by Account X on startup.
The goal is to make Process B interminable by Account X, whilst still being initiated by Account X.
Background:
This is easily achievable with Process Explorer, but this is a GUI program. There is some material online regarding changing permissions via command line, but these are for services, not for processes.
Specifically, I need to add Deny Permissions on Terminate Process, and Change Permissions to Account X for Process B.
Summary:
- Process A is started up on login (into Account X) via Task Scheduler running under an Administrator Account
- Process B is started up by Account X
- Account X is a standard level account
- I can use Process Explorer to manually add the Deny Permissions I am describing, but I want Process A to do it itself (perhaps by command line).
taskkill
command.