PDA

View Full Version : Common UNIX Security problem.... how to fix?




iDavidLeeRoth
Feb 6, 2007, 01:17 AM
Last login: Tue Feb 6 02:11:49 on ttyp1
Welcome to Darwin!
austin-mangels-computer:~ diamonddavidleeroth$ sudo vi
Password:***************
(vi pops up)

:sh


austin-mangels-computer:~ root#



Now, the person has root access. How in the world is this fixed? I've seen this on a HUGE number of nix systems.


On a side note:


How can I globally set all folders to align to a grid. I want all folders across my system to be arranged by date modified in a grid.



iMeowbot
Feb 6, 2007, 01:26 AM
Now, the person has root access. How in the world is this fixed?
Take the user out of sudoers. If you give a user sudo, you give a user root privileges, that's that.

eluk
Feb 6, 2007, 01:36 AM
By default I'm not on the sudoers list. How can I add a user to it?

iMeowbot
Feb 6, 2007, 01:46 AM
By default I'm not on the sudoers list. How can I add a user to it?

The easiest way on the Mac is to enable the user as an admin in System Preferences, since members of the admin group normally get access.

If you really want to give it to a non-admin user, man sudoers for the details and look at existing entries in /private/etc/sudoers for examples.

iDavidLeeRoth
Feb 6, 2007, 01:50 AM
$sudo -s -H gives a root shell, BTW.


Also, does anybody know how to fix my folder "problem"?

iMeowbot
Feb 6, 2007, 02:00 AM
$sudo -s -H gives a root shell, BTW.
Right, that's what it's supposed to do :D
Also, does anybody know how to fix my folder "problem"?
Open a Finder window and switch it to icon view. Pick View->Show View Options, and click the All Windows bubble near the top. Halfway down, check Keep Arranged By, and pick Date Modified.

iDavidLeeRoth
Feb 6, 2007, 02:03 AM
I know, I was just trying to inform.


Another thing....


I've been a Windows user for... well, forever. I bought the Mac around Christmas time. I'm used to my Desktop icons being on the left side of the screen. Is there anyway to move them?

semaja2
Feb 6, 2007, 02:46 AM
on a side note...

how does one add a user to the sudoers, i have a user that is a restricted account but i need them to be able to use sudo (sudoing into a admin account)

iDavidLeeRoth
Feb 6, 2007, 02:57 AM
on a side note...

how does one add a user to the sudoers, i have a user that is a restricted account but i need them to be able to use sudo (sudoing into a admin account)

Not sure, but it might be in Netinfo manager. :apple: :apple:

eluk
Feb 6, 2007, 08:49 AM
The easiest way on the Mac is to enable the user as an admin in System Preferences, since members of the admin group normally get access.

If you really want to give it to a non-admin user, man sudoers for the details and look at existing entries in /private/etc/sudoers for examples.

Cheers for that.

ElectricSheep
Feb 6, 2007, 10:30 AM
on a side note...

how does one add a user to the sudoers, i have a user that is a restricted account but i need them to be able to use sudo (sudoing into a admin account)

You need to explicitly add them to the sudoers file with visudo. See man visudo and man sudoers for all of the options you can assign a user in the sudoers file.