Scheduled Maintenance: We are aware of an issue with Google, AOL, and Yahoo services as email providers which are blocking new registrations. We are trying to fix the issue and we have several internal and external support tickets in process to resolve the issue. Please see: viewtopic.php?t=158230

 

 

 

Sudo or not sudo?

Here you can discuss every aspect of Debian. Note: not for support requests!
Message
Author
trinidad
Posts: 297
Joined: 2016-08-04 14:58
Been thanked: 15 times

Re: Sudo or not sudo?

#16 Post by trinidad »

IME in the enterprise sudo is the method of choice; in the last three engagements I've worked you're simply Not Going To Get The Root Password
Yes but there is another layer of security on the system, which is common on large systems, but still problematic. Large systems with multiple sudoers can certainly be a security risk. Administrators are moveing away from the practice, and/or adding a security layer, and/or technically limiting sudoer privileges per application across large networks, and/or running many non-risk administration tasks in user space instead, the security layer being vetted administrators.

TC
You can't believe your eyes if your imagination is out of focus.

zoli62
Posts: 20
Joined: 2019-11-09 04:09

Re: Sudo or not sudo?

#17 Post by zoli62 »

cuckooflew wrote:
http://forums.debian.net/posting.php?mo ... 2#pr710672 ; by zoli62 » 2019-11-10 09:54 > Does this mean that if you set the root password during the installation, the first user created during the installation will not be part of the sudo group?
To be honest , since I do not usually use sudo, nor install it, I might be wrong. But yes, if I remember correctly, when I did some experimenting with that, I had set the root password as I normally do. Then later I installed sudo, and did need to also make the first user (or what ever users I wanted), after sudo is installed, the users that the admin wants to give sudo privileges must be added to the sudoers group.
You should use "visudo" to do this , there are more details about the procedure available if one looks for them. You really should just read some documentation: (a good starting point: https://wiki.debian.org/sudo)
------ if you give root an empty password during installation, sudo will be installed and the first user will be able to use it to gain root access (currently, the user will be added to the sudo group). The system will also configure gksu and aptitude to use sudo. You should still verify group membership after logging in as the installed user.
===========
zoli62>> Assigning a user to this group on a terminal in Debian 10 is not that easy, as the beginner / average user may encounter some error messages during the operation.
It is simple and easy, but if it seems to complicated to you , perhaps you should use the MX :https://mxlinux.org/ distribution. Or any of the numerous others that install and set up sudo for you. As for encountering error messages, that is no big deal , fortunately there are error messages, and they usually help point you in the right direction. (Except when Gnome is involved, they just tell you "oh NO something went wrong")
I started using Debian when sudo didn't even exist. When sudo started, I already found the attitude of Ubuntu strange, because it reminded me of Windows, where UAC is used. I think using sudo gives the average user a false sense of security. In my opinion, we should be operating on an operating system either as an administrator or as a normal user. If we choose the former, we must be aware of all the risks involved. The problem is that in many cases, operating systems can only run useful system-level commands as an administrator. However, this is difficult for a beginner to understand, so he asks a more knowledgeable person to configure his own computer, so he won't learn to use GNU / Linux.

User avatar
wizard10000
Global Moderator
Global Moderator
Posts: 595
Joined: 2019-04-16 23:15
Location: southeastern us
Has thanked: 78 times
Been thanked: 89 times

Re: Sudo or not sudo?

#18 Post by wizard10000 »

trinidad wrote:Yes but there is another layer of security on the system, which is common on large systems, but still problematic. Large systems with multiple sudoers can certainly be a security risk. Administrators are moveing away from the practice, and/or adding a security layer, and/or technically limiting sudoer privileges per application across large networks, and/or running many non-risk administration tasks in user space instead, the security layer being vetted administrators.
True. IMO the whole purpose of sudo isn't to act as a replacement for the root account, but to provide limited access where required.
we see things not as they are, but as we are.
-- anais nin

pendrachken
Posts: 1394
Joined: 2007-03-04 21:10
Location: U.S.A. - WI.

Re: Sudo or not sudo?

#19 Post by pendrachken »

cuckooflew wrote:
zoli62 wrote:Why is it not preferable to use sudo by default in Debian?
Because some users, like me , do not want to use "sudo" , those that do want to use it can install it and set it up if they so desire.
Just playing devils advocate here:

What makes YOUR use case more important than the person who wants to use sudo? It's easier to re-enable the root account than it is for a user to properly set up sudo. All you have to do is:

Code: Select all

$: sudo su -
#: passwd
Input a password 2X when prompted and done
fortune -o
Your love life will be... interesting.
:twisted: How did it know?

The U.S. uses the metric system too, we have tenths, hundredths and thousandths of inches :-P

Deb-fan
Posts: 1047
Joined: 2012-08-14 12:27
Been thanked: 4 times

Re: Sudo or not sudo?

#20 Post by Deb-fan »

Of course + 1 Wiz10k and somewhat the other guy. As realistically on a multiuser system what semi-competent admin is going to give out sudo access to very many people anyway. Certainly not jane/joe avg user. Of course think sudo is cool though. Actually going to have to research it's history now, believe it originated with Canonical Inc/Ubuntu or thereabouts. Now there are these flatpak, snaps etc things for users who wish to install whatever (is allowed) and only affects their user acct. Like many am resistant to it, like the trusted and managed repositories setup as it is, don't so much like these new deal thingys but do see some potential. Also occurred to me I've been doing much the same thing forever in gnu/Nix, Firefox from Mozilla, not installed nor managed by the OS's packaging tools. Have also used stand-alone or portable apps forever and a day as well. On whichever OS and/or on a thumb-drive, shrugs.

In my view the whole root or sudo, one or other is kind of tarded. Mentioned I have/use both cause that's my preference but enabling/disabling (locking root acct) is a matter of secs or adding user with visudo/sudoers ... same. Each their own preference. One a MANY great things about gnu/Linux and Debian. You want it ? You can very likely have it really quickly. GOOGLE ! :D
Most powerful FREE tech-support tool on the planet * HERE. *

Deb-fan
Posts: 1047
Joined: 2012-08-14 12:27
Been thanked: 4 times

Re: Sudo or not sudo?

#21 Post by Deb-fan »

LMFAO !!! Well was just a wee bit wrong on origins of sudo, per Wikipedia.
Robert Coggeshall and Cliff Spencer wrote the original subsystem around 1980 at the Department of Computer Science at SUNY/Buffalo.[10] Robert Coggeshall brought sudo with him to the University of Colorado Boulder. Between 1986 and 1993, the code and features were substantially modified by the IT staff of the University of Colorado Boulder Computer Science Department and the College of Engineering and Applied Science, including Todd C. Miller.[10] The current version has been publicly maintained by OpenBSD developer Todd C. Miller since 1994,[10] and has been distributed under a ISC-style license since 1999.[10]
Should've known originating something like sudo is wayyyy out of Canonical's league. They just likely popularized it, as they naturally assume a good chunk of their userbase are complete tektards and shouldn't have root access, LOL .. without imposing safe guards (training wheels etc) !!! Sad thing is they're right ! :D
Most powerful FREE tech-support tool on the planet * HERE. *

Deb-fan
Posts: 1047
Joined: 2012-08-14 12:27
Been thanked: 4 times

Re: Sudo or not sudo?

#22 Post by Deb-fan »

WARNING POST CONTAINS ADULT HUMOR: If you can't handle such or your widdle feelers are easily hurt. Turn away from this post now !!!
HEY MAN, I've been using Ubuntu for 12yrs !!!

So that means you can turn your computer off now, without having to unplug it from the wall socket ? :D
Most powerful FREE tech-support tool on the planet * HERE. *

zoli62
Posts: 20
Joined: 2019-11-09 04:09

Re: Sudo or not sudo?

#23 Post by zoli62 »

There are different Linux distros and there is Debian for everything. :)

User avatar
wizard10000
Global Moderator
Global Moderator
Posts: 595
Joined: 2019-04-16 23:15
Location: southeastern us
Has thanked: 78 times
Been thanked: 89 times

Re: Sudo or not sudo?

#24 Post by wizard10000 »

Deb-fan wrote:In my view the whole root or sudo, one or other is kind of tarded.
My first wife was a tard. She's a pilot now.

:mrgreen:
Last edited by wizard10000 on 2019-11-10 19:54, edited 1 time in total.
we see things not as they are, but as we are.
-- anais nin

Deb-fan
Posts: 1047
Joined: 2012-08-14 12:27
Been thanked: 4 times

Re: Sudo or not sudo?

#25 Post by Deb-fan »

^ LMAO !! :D Gee thanks, that's a comforting thought. Looks up @ the ceiling. Was that a plane spiraling out of control towards my apartment ? ;)
Most powerful FREE tech-support tool on the planet * HERE. *

User avatar
wizard10000
Global Moderator
Global Moderator
Posts: 595
Joined: 2019-04-16 23:15
Location: southeastern us
Has thanked: 78 times
Been thanked: 89 times

Re: Sudo or not sudo?

#26 Post by wizard10000 »

Deb-fan wrote:^ LMAO !! :D Gee thanks, that's a comforting thought. Looks up @ the ceiling. Was that a plane spiraling out of control towards my apartment ? ;)
Actually that's a movie quote - Idiocracy. If you haven't seen it you're really missing out :)
we see things not as they are, but as we are.
-- anais nin

Deb-fan
Posts: 1047
Joined: 2012-08-14 12:27
Been thanked: 4 times

Re: Sudo or not sudo?

#27 Post by Deb-fan »

^ Hey will check it out. Hopefully available on YT. I must now take a break as I'm getting weird due to caffeine and sleep deprivation. I'd better sign off ! :D See ya later Wiz10k and fellow nixers. Tis movie time.
Most powerful FREE tech-support tool on the planet * HERE. *

User avatar
hrsetrdr
Posts: 181
Joined: 2007-03-17 15:14
Has thanked: 1 time

Re: Sudo or not sudo?

#28 Post by hrsetrdr »

Sorry for posting up such an old thread, but this issue keeps nagging me for an answer. Since using Debian 10 I've noticed that using "sudo" has become the default now...apparently(?). I've been using Debian since Sarge was Stable, so this is unexpected...but maybe not, as Debian Wiki is saying:
Using sudo is better (safer) than opening a session as root for a number of reasons, including:

Nobody needs to know the root password (sudo prompts for the current user's password). Extra privileges can be granted to individual users temporarily, and then taken away without the need for a password change.

It's easy to run only the commands that require special privileges via sudo; the rest of the time, you work as an unprivileged user, which reduces the damage that mistakes can cause.
Auditing/logging: when a sudo command is executed, the original username and the command are logged.

For the reasons above, switching to root using sudo -i (or sudo su) is usually deprecated because it cancels the above features. https://wiki.debian.org/sudo/
No big deal, just curious.
If you can't explain it simply, you don't understand it well enough.
(Albert Einstein).

User avatar
Onsemeliot
Posts: 333
Joined: 2010-12-15 14:43
Has thanked: 20 times
Been thanked: 5 times

Re: Sudo or not sudo?

#29 Post by Onsemeliot »

I'm using Debian 10 (Buster) on different systems. And to my knowledge nothing has changed regarding the "sudo" command. You still can get it by not creating a root user. I think the installer is very clear about this. But as ever: you can only make an informed decision if you mindfully read what options the system offers you ...

And in general: I don't think distributions like Ubuntu are making much of a difference by using "sudo". Most users I know (and occasionally assist) don't want to use the terminal if they can somehow avoid it. The need to use the terminal is usually enough complication to shy away most people not interested in the inner workings of a system. Heck, most people just buy a new device if their system gets slow – without even asking if this could be overcome by some administration or other software. The question if their system could become more responsive by quicker storage or more memory isn't something most people would consider. Of course I am talking mostly about people who have always been limited by their proprietary systems where there actually often wasn't much you could do. At least in terms of optimisation on the system level.
People around me are obviously wealthy enough that buying new hardware isn't such a big deal. It is much more annoying for them to invest time than money.

User avatar
Head_on_a_Stick
Posts: 14114
Joined: 2014-06-01 17:46
Location: London, England
Has thanked: 81 times
Been thanked: 133 times

Re: Sudo or not sudo?

#30 Post by Head_on_a_Stick »

doas ftw!
deadbang

User avatar
hrsetrdr
Posts: 181
Joined: 2007-03-17 15:14
Has thanked: 1 time

Re: Sudo or not sudo?

#31 Post by hrsetrdr »

Onsemeliot wrote:. You still can get it by not creating a root user
I must have been distracted and used the Graphical Install instead of the normal installer.
If you can't explain it simply, you don't understand it well enough.
(Albert Einstein).

MALsPa
Posts: 678
Joined: 2007-12-07 19:20
Location: albuquerque
Been thanked: 2 times

Re: Sudo or not sudo?

#32 Post by MALsPa »

hrsetrdr wrote:
Onsemeliot wrote:. You still can get it by not creating a root user
I must have been distracted and used the Graphical Install instead of the normal installer.
That part wouldn't matter -- when the user goes with the Graphical install option and the Root password is left blank, you get sudo.

User avatar
kalle123
Posts: 352
Joined: 2015-03-21 11:17
Location: Rhineland - Germany
Has thanked: 4 times
Been thanked: 12 times

Re: Sudo or not sudo?

#33 Post by kalle123 »

Maybe this text should be revised then ...
'You need to set'
Image

br KH

milomak
Posts: 2168
Joined: 2009-06-09 22:20
Been thanked: 2 times

Re: Sudo or not sudo?

#34 Post by milomak »

it is quite clear about what happens when you don't set the password

there is no need to prescriptive

i install sudo and have it use the root password. becomes sometimes i just want to run one command as root.
Desktop: A320M-A PRO MAX, AMD Ryzen 5 3600, GALAX GeForce RTX™ 2060 Super EX (1-Click OC) - Sid, Win10, Arch Linux, Gentoo, Solus
Laptop: hp 250 G8 i3 11th Gen - Sid
Kodi: AMD Athlon 5150 APU w/Radeon HD 8400 - Sid

BradleyGuerr
Posts: 2
Joined: 2020-10-24 17:34

Re: Sudo or not sudo?

#35 Post by BradleyGuerr »

zocsli62 wrote:Why is it not preferable to use sudo by default in Debian?
it is preferable to use sudo by default in Debian. :D

Post Reply