Why linux doesn't have a "wheel" group
administratosphere.wordpress.com
administratosphere.wordpress.com
In any case, if you really care, just enable pam_wheel.so in your pam configuration for su (usually /etc/pam.d/su) and be sure to add yourself to the appropriate group.
Years ago a friend of mine asked my help in securing a Unix system with sudo. I bascially told him it was nearly impossible because there were (and still are) too many ways to escape back to a root shell with sudo, so, in my humble opinion, gives a false sense of security.
If you need a longer session with uid 0, use sudo -i. Having a separate root login is pretty much pointless. I doubt having separate passwords helps security either, since local privilege escalation vulnerabilities are common anyway.
I've used sudo to restrict root access to specific command line invocations for certain users. With due care (ie. no access to software with shell escapes) it is secure.
In any case, distributions seem to be moving towards eliminating the superuser altogether in common use cases. I think advocating sudo was just the beginning.
I also color code the hostname so that I can tell at a glance what machine I'm on.
For example,
export PS1='[\[\033[1;34m\]\u\[\033[0m\]@\[\033[1;30m\]\h\[\033[0m\] $newPWD]\$ '
where $newPWD is a friendly, shortened $PWD.On that same machine, the root prompt is identical except that the color is set to 1;31m instead of 1;34m, which makes it bright red.
alias ssu='sudo /bin/bash -login'Also -i does more stuff to simulate a login like setting $HOME and cd'ing there.
Usually you might want to use sudo -i or 'su -' which both simulate a login. But sudo su - really isn't needed any more since -i has been added
My recollection is that when OSX came on the scene without a root password and administration through sudo, Linux distributions were still tied to root and su and many Linux users were both disapproving and condescending about it.
Though certainly it's safer to do some tasks as non-root as well, such as compiling software, then switch to root/sudo to install it. Just remember to double/triple check each command you type in a root shell or after the sudo command. Particularly when using commands such as rm with arguments such as -rf!
Sudo also does provide some extra flexibility when you are delegating tasks to someone who doesn't necessarily need full root access.
Application to the swing back to "cloud computing", multiuser computing's latest moniker, left as an exercise for the reader.
At this time security requirements where completely different than today and it was not unusual for everyone in a lab to have root access to the machines.
---
"The hackers who wrote the Incompatible Timesharing System decided that file protection was usually used by a self-styled system manager to get power over everyone else," Stallman would later explain. "They didn't want anyone to be able to get power over them that way, so they didn't implement that kind of a feature. The result was, that whenever something in the system was broken, you could always fix it."
Through such vigilance, hackers managed to keep the AI Lab's machines security-free. Over at the nearby MIT Laboratory for Computer Sciences, however, security-minded faculty members won the day. The LCS installed its first password-based system in 1977. Once again, Stallman took it upon himself to correct what he saw as ethical laxity. Gaining access to the software code that controlled the password system, Stallman implanted a software command that sent out a message to any LCS user who attempted to choose a unique password. If a user entered "starfish," for example, the message came back something like:
I see you chose the password "starfish." I suggest that you switch to the password "carriage return." It's much easier to type, and also it stands up to the principle that there should be no passwords.
The fear that someone would take control and abuse power in that way was not an unfounded one.
I know in our computer lab in high school, which was a series of x86 PCs donated by Novell and sharing files from a Netware file server (this was 1989-1990), we used to try to get superuser privileges on the Netware server. Once or twice, the 20 year old kid they hired as a sysadmin would walk away from his desk and forget to logout of his workstation, and we would give ourselves superuser privileges on the network. We would use this privilege to play "Snipes," one of the first network based multiplayer text shooter games. http://en.wikipedia.org/wiki/Snipes
This fun lasted for a few hours until the 20 year old sysadmin determined we had superuser privs that we shouldn't have and promptly revoked our rights.
But the admins had installed "NetWork Eye" - sort of like a VNC for text monitors. So one guy in the class wrote an assembler (in TP) then got a NetBios book and wrote some low-level NetBios stuff in assembler. That allowed us to NetWork-Eye the servers to get some other funky stuff done.
One thing we did was to login on all 50 workstations (except one), and run the network eye in a cascaded chain. Then sit back and watch the first person come in. They're log in (on all 50 monitors simultaneously) and everything they did would come up on all 50. Usually took a few minutes before they noticed...
Ahh - good times.... <g>
Those system did not have network access at first and when they finally did most of the people on the net at the time were know (small community) and peer pressure kept people in line. ITS had a easy command that would kill and shutdown the machine. This took all the fun out of hacking the machine and killing it. There was always a loser that would try it and he would forever be forsaken by the Hackers.
Read Hackers by Steven Levy. I read that book every year almost.
So everything was great until the dumbass showed up and ruined everything? This makes a great argument for account privileges and security.
Because it's human nature to push that big, red button...
This obviously wouldn't work today but back then the culture of the users was very different.
Many people's passwords were known. I trusted nobody to rm everything, and nobody ever did.
The internet changed that.
I'm the mid-90s I worked at a UK university computer science department. At the time there were no firewalls around the departmental network and pretty much every machine, from the Sun and SGI workstations through to the multi-CPU servers, were directly connected to the Internet. We used NFS, rlogin and co. to transfer files and connect to different machines. I can remember logging into machines remotely from home using a modem, an ISP and passwords-in-the-clear. There was no regime I was aware of to apply software patches to machines.
Looking back, I can't believe how much of a trusting place the internet was back then.
I'd like to work on a totally open system where users could clone one another's blocks of memory and see everything. You could come up with a more collaborative environment than we have in unix atm. However, I wouldn't want an arrangement where one person's slip of the fingers could destroy the environment.
Don't forget these machines were in a much safer environment than todays.
Is irrelevant and archaic for many, many servers (99%) of ones I've worked on last 20yrs (web/internet servers vs file/print/lan type servers.
The only accounts who can login and get a shell are the same set of accounts who can su root to almost every server I'm involved with.
When you have DBA access to production databases, lack of root does not stand in the way of doing evil.
It does stand in the way of using message logs to troubleshoot, checking contents of /proc to determine which directory a process is running from, tuning TCP parameters to maximize data transfer rates without nagging the sysadmins, etc.
(For evil-genius-DBA's bonus points for doing that via the database instead of the shell and censoring traces from the db logs too...)
On everything I'm responsible for, it's assumed that if you've got shell or if you've got permission to upload executable code, you've got the ability to get root.
I'm prepared to keep on top of server security enough to protect against remote-root exploits (with reasonably short zero-day exposure times), but there's no way I'm going to be able to keep every little utility shipped with a useable linux distribution up-to-date and secure.
If Tripwire or Snort or the logfiles show unexpected filesystem changes, we reimage the OS and restore the data from backups.
root:ALL EXCEPT GROUP wheel:DENY
But I think this may be due to the "su" program not being GNU su, but the one from the shadow suite. :)
For example, in Fedora 15 we are now using wheel to add users as administrators who are able to sudo to root. This is easily enabled by checking the 'Administrator' box during firstboot's setup of the user account.
It's really about GNU su.
If you accept that there's a use for a secret root password (which, I assume, Stallman has; otherwise why write an `su` at all?), having no wheel group would seem to encourage a /single/ admin with the password, to prevent the leaking of info he mentions. Which is more tyrannous?
I also am not sure that Stallman accepted the need for passwords at all when he wrote that text. http://en.wikipedia.org/wiki/Richard_Stallman:
"When MIT's Laboratory for Computer Science (LCS) installed a password control system in 1977, Stallman found a way to decrypt the passwords and sent users messages containing their decoded password, with a suggestion to change it to the empty string (that is, no password) instead, to re-enable anonymous access to the systems"
"OK", you say "maybe all those are turned off for root". Well, even then there are likely many other accounts with some degree of privilege. Often these can be leveraged to root access. For example: the members of the wheel group.