How do you de-elevate privileges for a child process

The solution for you is to use EXPLORER.exe process. The idea is to run the process in UN-ELEVATED mode, using windows’s file explorer process explorer.exe (info). Lets say the process that we want to launch is on $TEMP\MyUnElevatedProcess.exe. So, for NSIS code, I will just write: (but can be run in ANY language) Exec ‘”$WINDIR\explorer.exe” … Read more

How Linux handles threads and process scheduling

The Linux kernel scheduler is actually scheduling tasks, and these are either threads or (single-threaded) processes. So a task (a task_struct inside the kernel), in the context of the scheduler, is the thing being scheduled, and can be some kernel thread like kworker or kswapd, some user thread of a multi-threaded process (like firefox), or … Read more

C# process.start, how do I know if the process ended?

MSDN System.Diagnostics.Process If you want to know right now, you can check the HasExited property. var isRunning = !process.HasExited; If it’s a quick process, just wait for it. process.WaitForExit(); If you’re starting one up in the background, subscribe to the Exited event after setting EnableRaisingEvents to true. process.EnableRaisingEvents = true; process.Exited += (sender, e) => … Read more

Hata!: SQLSTATE[HY000] [1045] Access denied for user 'divattrend_liink'@'localhost' (using password: YES)