Make superuser be authenticated in DSL (Damn Small Linux) 4.4.10
Linux - SoftwareThis forum is for Software issues.
Having a problem installing a new program? Want to know which application is best for the job? Post your question in this forum.
Notices
Welcome to LinuxQuestions.org, a friendly and active Linux Community.
You are currently viewing LQ as a guest. By joining our community you will have the ability to post topics, receive our newsletter, use the advanced search, subscribe to threads and access many other special features. Registration is quick, simple and absolutely free. Join our community today!
Note that registered members see fewer ads, and ContentLink is completely disabled once you log in.
Make superuser be authenticated in DSL (Damn Small Linux) 4.4.10
Hi Guys,
I am currently running a multiuser ssh server, and everytime I login with a limited account and I want to run a command, "rm -rf /" (I wouldn't do that of course, but hypothetically say I did), it requires me to be a superuser -- obviously. So, then I do, "sudo rm -rf /" (quotes omitted). However, DSL 4.4.10 doesn't prompt me for the superuser password but instead simply logs me in. For me, this is dangerous because I don't want other users to mess up the OS. I have set the root password, but now how do I set it to prompt a user for the password everytime s/he wants to do something that requires admin privileges (does it have something to do with pam_authenticate?)?
What happens when you log in locally, not ssh, and try a regular user?
Verify by creating a wholley new user called "test", with defaults, log in as test and check the sudo behaviour.
The use of sudo in controlled by the sudoers file.
Check that - people who are not sudoers cannot use sudo at all. People who are sudoers need authentication, unless otherwise specified in sudoers.
What happens when you log in locally, not ssh, and try a regular user?
Verify by creating a wholley new user called "test", with defaults, log in as test and check the sudo behaviour.
The use of sudo in controlled by the sudoers file.
Check that - people who are not sudoers cannot use sudo at all. People who are sudoers need authentication, unless otherwise specified in sudoers.
If I run "sudo su" or "sudo -s" then I must authenticate. But if I run, "sudo rm -rf /" I don't need to authenticate. Maybe something is wrong with pam_authenticate, I'm guessing?
By the way, how do I install packages in DSL? I tried "apt-get install <packagename?" (quotes omitted) under the root user because supposedly it is based off of Debian; however, it seems as though there is no apt-get.
If I run "sudo su" or "sudo -s" then I must authenticate. But if I run, "sudo rm -rf /" I don't need to authenticate. Maybe something is wrong with pam_authenticate, I'm guessing?
No, I fixed it. It has nothing to do with pam_authenticate. I just had to edit the /etc/sudoers file.
LinuxQuestions.org is looking for people interested in writing
Editorials, Articles, Reviews, and more. If you'd like to contribute
content, let us know.