Using .NET Core 2.0 on a Linux Ubuntu I want to start a bash shell using the Process class, redirect StandardInput and StandardOutput and want to enter commands and receive the results.
This works great for commands like cd
and dir
.
When I want to execute a command with sudo
, the bash hangs, however,
and waits for the input of a password. I guess the same would happen
for commands that require a confirmation by Yes or No.
Is there any way to enter the password or a confirmation like Yes or No from my application?