Question: When a program takes an input from users, we can redirect the input device, so the program can take the input from a file. For

When a program takes an input from users, we can redirect the input device, so the program can take the input from a file. For example, we can use prog < myfile to provide the data from myfile as input to the prog program. Now, if prog is a root-owned Set-UID program, can we use the following method to get this privileged program to read from the /etc/shadow file?

$prog < / etc/ shadow

Step by Step Solution

3.36 Rating (149 Votes )

There are 3 Steps involved in it

1 Expert Approved Answer
Step: 1 Unlock

The question is complete In a Unixbased system if you have a program that runs with elevated privileges such as a rootowned SetUID program its importa... View full answer

blur-text-image
Question Has Been Solved by an Expert!

Get step-by-step solutions from verified subject matter experts

Step: 2 Unlock
Step: 3 Unlock

Students Have Also Explored These Related Programming Questions!