Linux has a lot of security measures in place that are meant to
protect your system from threats and sometimes (admittedly) our own
stupidity. There are three main features that exist to limit and provide
access as needed — file permissions, file ownership, and the root user
account.
Although widely known as the super user account, SU actually refers to substitute user, and instructs the computer to execute commands with the file permissions of another user, by default the root account. This shortcut is a powerful tool that can be very helpful when used correctly or absolutely devastating if used recklessly.
Today, we’re going to go into deeper detail about SU and why you should be responsible when using it.
All of the major operating systems have the concept of an administrator account, offering heightened privileges compared to otherwise “normal” user accounts. Normal users have access to their own files, but not other users’ files and only read-only access to system files so that they can run installed applications.
Administrators, on the other hand, can change system files, which includes installation of new or updated applications, and can (usually) see other users’ files.
Simple enough, right? Sure, the concepts are quite easy to understand, but it has further-reaching implications than just that. Administrators, who assumedly know more about what they’re doing, can make more major changes to a system without it breaking or leaking sensitive data. Normal users without these permissions cannot perform these tasks, so there’s little chance that those users will break the system.
On most systems with just one user, that user is often the administrator and can do whatever they want with their computer. This is a hierarchy of one, so no third party needs to be present as administrator. However, whenever users have access to these system privileges all the time, they tend to use them blindly, simply accepting requests for admin rights without thinking it through.
At least psychologically speaking, this method forces you to realize that you’re doing something more serious to your system as it won’t let you do it without using SU.
To switch, you just need to open up a terminal and type in
It will then ask for the root password to grant you access. If you use sudo, you can also run
The root account is really powerful, so it should feel like a big deal if you need to switch into it. As root, you can delete your entire system in one terminal command.
As a normal user, it wouldn’t let you do that because you don’t have
access to modify any files outside of your home folder. Any damage that
you do as a normal user stays contained within that domain — it doesn’t
affect the system or any other users.
Although widely known as the super user account, SU actually refers to substitute user, and instructs the computer to execute commands with the file permissions of another user, by default the root account. This shortcut is a powerful tool that can be very helpful when used correctly or absolutely devastating if used recklessly.
Today, we’re going to go into deeper detail about SU and why you should be responsible when using it.
Admin Accounts
All of the major operating systems have the concept of an administrator account, offering heightened privileges compared to otherwise “normal” user accounts. Normal users have access to their own files, but not other users’ files and only read-only access to system files so that they can run installed applications.
Administrators, on the other hand, can change system files, which includes installation of new or updated applications, and can (usually) see other users’ files.
Simple enough, right? Sure, the concepts are quite easy to understand, but it has further-reaching implications than just that. Administrators, who assumedly know more about what they’re doing, can make more major changes to a system without it breaking or leaking sensitive data. Normal users without these permissions cannot perform these tasks, so there’s little chance that those users will break the system.
On most systems with just one user, that user is often the administrator and can do whatever they want with their computer. This is a hierarchy of one, so no third party needs to be present as administrator. However, whenever users have access to these system privileges all the time, they tend to use them blindly, simply accepting requests for admin rights without thinking it through.
The Super User Account On Linux
Linux takes a different approach to handling these administrative privileges. Instead of assigning admin rights to user accounts, Linux separates these into two different accounts: the SU account (sometimes called root) and then your normal user account. The idea is that if you need to do something that requires elevated privileges, you can use the SU command and do whatever you need to do.At least psychologically speaking, this method forces you to realize that you’re doing something more serious to your system as it won’t let you do it without using SU.
To switch, you just need to open up a terminal and type in
su
It will then ask for the root password to grant you access. If you use sudo, you can also run
sudo bash
which will open up bash (simply another instance of the terminal) but on behalf of the root.
Comments
Post a Comment