You are not logged in.

#1 2014-04-10 01:14:53

saronno
Member
Registered: 2009-10-02
Posts: 194

AUR, Yaourt, packer and sudo password.

I have an annoying problem after some upgrades.
When yaourt (but it's the same with packer) ask me for root password (sudo)
it doesn't recognize it.
But if I put the password of the user I am logged in for yaourt (and packer) is fine.

How the hell is this possible?

      Thanks.

Last edited by saronno (2014-04-10 01:15:29)

Offline

#2 2014-04-10 01:23:38

jasonwryan
Anarchist
From: .nz
Registered: 2009-05-09
Posts: 30,424
Website

Re: AUR, Yaourt, packer and sudo password.

Moving to AUR issues...


Arch + dwm   •   Mercurial repos  •   Surfraw

Registered Linux User #482438

Offline

#3 2014-04-10 01:40:14

Scimmia
Fellow
Registered: 2012-09-01
Posts: 11,541

Offline

#4 2014-04-10 10:08:13

clfarron4
Member
From: London, UK
Registered: 2013-06-28
Posts: 2,163
Website

Re: AUR, Yaourt, packer and sudo password.

saronno wrote:

I have an annoying problem after some upgrades.
When yaourt (but it's the same with packer) ask me for root password (sudo)
it doesn't recognize it.
But if I put the password of the user I am logged in for yaourt (and packer) is fine.

How the hell is this possible?

      Thanks.

Just installed yaourt to look into this for you (aren't you special). Here's what happens when I am logged in as me and I issue "yaourt -Syu":

claire ~ % yaourt -Syu
[sudo] password for claire: 

It asks me for my passphrase, not root's...


Claire is fine.
Problems? I have dysgraphia, so clear and concise please.
My public GPG key for package signing
My x86_64 package repository

Offline

#5 2014-04-11 11:09:20

saronno
Member
Registered: 2009-10-02
Posts: 194

Re: AUR, Yaourt, packer and sudo password.

clfarron4 wrote:

It asks me for my passphrase, not root's...

In my case ...

[saronno@----- ~]$ yaourt -Syu
[sudo] password for root: 

Anyway I don't understand why it should ask user password for a privileged action.

Last edited by saronno (2014-04-11 11:11:40)

Offline

#6 2014-04-11 11:12:55

Trilby
Inspector Parrot
Registered: 2011-11-29
Posts: 29,520
Website

Re: AUR, Yaourt, packer and sudo password.

saronno wrote:

Anyway I don't understand why it should ask user password for a privileged action.

Because it uses sudo - that's what sudo does.

If the user is in the sudoers file as being able to do such things.

sudo != su.

If everyone authorized to use sudo were to know the root password, then sudo would serve no purpose.

Last edited by Trilby (2014-04-11 11:14:24)


"UNIX is simple and coherent..." - Dennis Ritchie, "GNU's Not UNIX" -  Richard Stallman

Offline

#7 2014-04-11 12:32:31

drcouzelis
Member
From: Connecticut, USA
Registered: 2009-11-09
Posts: 4,092
Website

Re: AUR, Yaourt, packer and sudo password.

saronno wrote:

In my case ...

[saronno@----- ~]$ yaourt -Syu
[sudo] password for root: 

What is the output of "alias yaourt"? And "which yaourt"?

Do you actually have "sudo" installed? Did you configure it? What is in the file "/etc/sudoers"?

Offline

#8 2014-04-11 12:34:04

saronno
Member
Registered: 2009-10-02
Posts: 194

Re: AUR, Yaourt, packer and sudo password.

Trilby wrote:
saronno wrote:

Anyway I don't understand why it should ask user password for a privileged action.

Because it uses sudo - that's what sudo does.

If the user is in the sudoers file as being able to do such things.

sudo != su.

If everyone authorized to use sudo were to know the root password, then sudo would serve no purpose.

You are right .... just a question then ...

If my user is part of sudo group with %sudo ALL=(ALL) ALL
and during surfing my browser was hit by a 0-day attack,
the attacker can easily run privileged command using sudo
.. am I right?

Offline

#9 2014-04-11 12:52:42

Oxyd
Member
From: Czech Republic
Registered: 2008-01-17
Posts: 167

Re: AUR, Yaourt, packer and sudo password.

saronno wrote:

If my user is part of sudo group with %sudo ALL=(ALL) ALL
and during surfing my browser was hit by a 0-day attack,
the attacker can easily run privileged command using sudo
.. am I right?

If the attacker gets access to your shell and the attacker knows your password, then yes.

Offline

#10 2014-04-11 13:24:07

saronno
Member
Registered: 2009-10-02
Posts: 194

Re: AUR, Yaourt, packer and sudo password.

Oxyd wrote:
saronno wrote:

If my user is part of sudo group with %sudo ALL=(ALL) ALL
and during surfing my browser was hit by a 0-day attack,
the attacker can easily run privileged command using sudo
.. am I right?

If the attacker gets access to your shell and the attacker knows your password, then yes.

It seems far more secure to use "su" to me ....

Offline

#11 2014-04-11 13:48:36

The Black Fox
Member
Registered: 2014-04-08
Posts: 6

Re: AUR, Yaourt, packer and sudo password.

Su vs sudo aren't really anymore secure than the other, if he has access into your machine, you're already screwed unless you know how he got in. If you're worried about such a thing you may need to look at a 2-factor PAM, such as the Google Authenticator version: https://aur.archlinux.org/packages/goog … libpam-git

That will ensure even if an attacker knows your password, then he can't do any privileged action for either user and you have way more time to find out how he is getting in and patch the hole.

Offline

#12 2014-04-11 22:14:21

saronno
Member
Registered: 2009-10-02
Posts: 194

Re: AUR, Yaourt, packer and sudo password.

The Black Fox wrote:

Su vs sudo aren't really anymore secure than the other, if he has access into your machine, you're already screwed unless you know how he got in.

If he's still a limited user the damaged will be limited.
I disagree. This is the same idea that make people to surf
the web with administrator account.

If you're worried about such a thing you may need to look at a 2-factor PAM, such as the Google Authenticator version: https://aur.archlinux.org/packages/goog … libpam-git

I am developing a custom tomoyo policy .. so in the end I will use MAC.
am I worried? Aren't you?

That will ensure even if an attacker knows your password, then he can't do any privileged action for either user and you have way more time to find out how he is getting in and patch the hole.

Sincerely I prefer MAC approach. Anyway I disinstalled sudo ...

Offline

#13 2014-04-11 22:16:57

Trilby
Inspector Parrot
Registered: 2011-11-29
Posts: 29,520
Website

Re: AUR, Yaourt, packer and sudo password.

Sudo doesn't allow anyone logged in as the user run any command.  Sudo still requires the user password even when one is already logged in as that user.

So the logic behind your argument rests on the assumption that it is harder for an attacker to get your root user password than it is to get your regular user password.  This assumption does not seem to hold up.


"UNIX is simple and coherent..." - Dennis Ritchie, "GNU's Not UNIX" -  Richard Stallman

Offline

#14 2016-01-26 20:17:51

motozirillo
Member
Registered: 2015-02-17
Posts: 5

Re: AUR, Yaourt, packer and sudo password.

I'm experiencing similar behavior: first packer asks for my user password [sudo]. If I do not enter it in a timely matter (who has the time to watch 20 npm modules build?) packer asks for the root password on the next line.

Could this be an issue with sudo?

Offline

#15 2016-01-26 20:42:33

Trilby
Inspector Parrot
Registered: 2011-11-29
Posts: 29,520
Website

Re: AUR, Yaourt, packer and sudo password.

motozirillo wrote:

Could this be an issue with sudo?

No.

Please do not "necrobump" old threads - I fail to see that your issue is related, or even an issue at all.  It is how packer is likely defined.  If sudo fails, it attempts to use su.

Closed.


"UNIX is simple and coherent..." - Dennis Ritchie, "GNU's Not UNIX" -  Richard Stallman

Offline

Board footer

Powered by FluxBB