Click to See Complete Forum and Search --> : Using root-login


Hena
10-10-2001, 04:46 AM
How big security hole comes from using root to do daily work, instead of doing re-login for everytime something is needed to change? I need to install or change something that requires root login almost daily so its would be more convinient to use root. Although using su helps.

Saptech
10-10-2001, 05:18 AM
Thats a big security risk. But if you are the only person to use that computer and you do not get online using the Root password then I would say its okay to use it.

But then you can also trash your system using it on a daily/all day basis also.

I would just log in as normal user and su to do stuff and get out when done to really be on the safe side.

Joeri Sebrechts
10-10-2001, 07:16 AM
Take a look at sudo, it's a command that allows you to execute root tasks as a regular user (if you've set it up to allow that).

It all depends on what the specific thing is you need to do as root.
If you need to mount a filesystem for example, place "user" in the options field in /etc/fstab of the filesystem you want to mount (add the fs if it's not there yet), and then add yourself to the group the device that contains the filesystem in /dev has. If it's group is root, maybe you can change it to a newly made group, and add yourself to that group. Then make sure that group has rw rights to that device, and only you'd be able to mount it, while all the other regular users (and services!) wouldn't.

Apart from that, the only other often recurring task I can think of is updating the system, and for obvious reasons you want only root to be able to do that.

Most of the things you would think only root can do can be solved by making the file or directory involved in the operation readable and writeable to it's own special group, and then adding yourself to that group. Most linuces are actually pre-designed that way. Everything is already a member of it's own group, and all you need to do is add yourself.