init command question
Hi team,
I have a question,I found that the permission of "/sbin/init "is 755,but why can not I run this command with the general user? |
well you can literally run it, but the code will check your uid and only permit any consequences to be taken by root.
|
The permissions for the command is indeed rwxr-xr-x (755). But, though the command can be initiated by user, it will be executed as root. That is a limitation of that command, but an intentional limitation so that the user will not accidentally harm the system.
|
Acid_kewpie/matrix13 Thanks a lot!
So you mean the running mechanism or verification rules has been written in the program.Because I found that the file "/sbin/init" is a compiled executable program.Is that right? Best regards. |
All times are GMT -5. The time now is 05:41 AM. |