Bug#918754: [Pkg-shadow-devel] Bug#918754: bash: $PATH in bash does not include /sbin and /usr/sbin

2019-11-11 Thread Bálint Réczey
Control: reassign -1 util-linux 2.32-0.2

Stefan Tauner  ezt írta (időpont: 2019. szept.
23., H, 15:30):
>
> On Wed, 11 Sep 2019 14:18:32 + "Jakubith, Boris"
>  wrote:
>
> > I think this no _not_ a good idea. The semantics of 'su' is correct. The
> > only error is that many users up to day count on the wrong behaviour.
> > […]
> >
> > You can set 'ALWAYS_SET_PATH yes' for your installation, but generally - in
> > a default install - this would be sooo wrong, especially because there many
> > alternatives.
>
> I can't argue with that, however I want to point out that the root
> terminal (at least on Mate) as described in the Debian wiki[1] is
> executed via "gksu /usr/bin/x-terminal-emulator"
> that lacks the correct (PATH) environment too (I did an upgrade so maybe
> this is a relic).
> Changing the command to use gksudo instead sets up the right
> directories AFAICT. This definitely looks like a bug to me. Can anybody
> confirm the behavior (of launching a root terminal in a desktop
> environment and not having the sbin directories in PATH) on a fresh
> Gnome and/or Mate install? If this is deemed a bug shall we repurpose
> this one or create a new one?
>
> Sidenote: It is also no longer possible to launch X applications from
> such a (root) terminal which used to work (can't remember if I had to
> persuade it to do so with some configuration files though).
>
> 1: https://wiki.debian.org/Root

It was a decision of util-linux maintainers to change the behaviour
and /etc/default/su would be a better place to revert to the old
behaviour which should be shipped by su.

Cheers,
Balint

> --
> Kind regards/Mit freundlichen Grüßen, Stefan Tauner
>
> ___
> Pkg-shadow-devel mailing list
> pkg-shadow-de...@alioth-lists.debian.net
> https://alioth-lists.debian.net/cgi-bin/mailman/listinfo/pkg-shadow-devel



Bug#918754: bash: $PATH in bash does not include /sbin and /usr/sbin

2019-09-23 Thread Stefan Tauner
On Wed, 11 Sep 2019 14:18:32 + "Jakubith, Boris"
 wrote:

> I think this no _not_ a good idea. The semantics of 'su' is correct. The
> only error is that many users up to day count on the wrong behaviour. 
> […]
> 
> You can set 'ALWAYS_SET_PATH yes' for your installation, but generally - in
> a default install - this would be sooo wrong, especially because there many
> alternatives.

I can't argue with that, however I want to point out that the root
terminal (at least on Mate) as described in the Debian wiki[1] is
executed via "gksu /usr/bin/x-terminal-emulator"
that lacks the correct (PATH) environment too (I did an upgrade so maybe
this is a relic).
Changing the command to use gksudo instead sets up the right
directories AFAICT. This definitely looks like a bug to me. Can anybody
confirm the behavior (of launching a root terminal in a desktop
environment and not having the sbin directories in PATH) on a fresh
Gnome and/or Mate install? If this is deemed a bug shall we repurpose
this one or create a new one?

Sidenote: It is also no longer possible to launch X applications from
such a (root) terminal which used to work (can't remember if I had to
persuade it to do so with some configuration files though).

1: https://wiki.debian.org/Root
-- 
Kind regards/Mit freundlichen Grüßen, Stefan Tauner



Bug#918754: bash: $PATH in bash does not include /sbin and /usr/sbin

2019-09-11 Thread Jakubith, Boris
On Sun, 8 Sep 2019 03:57:58 +0200 Karsten  wrote:
> Am 06.09.19 um 00:41 schrieb Markus Koschany:
> > This is a new behavior because the util-linux implementation of su is
> > used now. See also /usr/share/doc/util-linux/NEWS.Debian.gz for more
> > information.
> >
> > "If you want to restore behaviour more similar to
> >   the previous one you can add 'ALWAYS_SET_PATH yes'
> > in /etc/login.defs."
> >
> > Markus
>
> Thanks.
> My /etc/login.defs is now
>
> #
> # *REQUIRED*  The default PATH settings, for superuser and normal users.
> #
> # (they are minimal, add the rest in the shell startup files)
> ENV_SUPATH
> PATH=/usr/local/sbin:/usr/local/bin:/usr/sbin:/usr/bin:/sbin:/bin
> ENV_PATH
> PATH=/usr/local/bin:/usr/bin:/bin:/usr/local/games:/usr/games
>
>
>
> This seems to work.
> But to solve the problem this should be added by default.
> Then this bug can be closed.
>
> Cheers
> karsten


I think this no _not_ a good idea. The semantics of 'su' is correct. The
only error is that many users up to day count on the wrong behaviour. If
you want the PATH being changed, use the 'login' variant of 'su':

$ su - -c 'command'

or simply:

$ su -

for a login. Alternatively, you can use

  1)$ su -c 'PATH=/usr/sbin:/sbin:/usr/local/sbin:$PATH command'

  2)$ sudo command

You can set 'ALWAYS_SET_PATH yes' for your installation, but generally - in
a default install - this would be sooo wrong, especially because there many
alternatives.

Greetings
Boris

[https://ueberbau.igp-ag.com/temp/expowerbung.png]

Metis Systems AG | Friedrichstraße 185 | 10117 Berlin | Deutschland
Tel: +49 (30) 521079-100 | E-Mail: i...@metis-ag.com

Aufsichtsratsvorsitzender: Markus Molnár
Vorstandsvorsitzender: Tobias Dobberphul
Vorstand: Christian Werner
Sitz der Gesellschaft: Amtsgericht Berlin-Charlottenburg HRB 194708 B | 
Finanzamt für Körperschaften IV | Steuer-Nr.: 30/057/75584


Diese E-Mail, einschließlich sämtlicher mit ihr übertragenen Dateien, ist 
vertraulich und für die ausschließliche Verwendung durch die Person oder das 
Unternehmen vorgesehen, an die/das sie adressiert ist. Sollten Sie diese E-Mail 
fälschlicherweise erhalten haben, benachrichtigen Sie bitte den 
Systemverwalter. Diese E-Mail wurde auf die Anwesenheit von Computerviren 
überprüft.


Bug#918754: bash: $PATH in bash does not include /sbin and /usr/sbin

2019-09-07 Thread Karsten
Am 06.09.19 um 00:41 schrieb Markus Koschany:
> This is a new behavior because the util-linux implementation of su is
> used now. See also /usr/share/doc/util-linux/NEWS.Debian.gz for more
> information.
>
> "If you want to restore behaviour more similar to
>   the previous one you can add 'ALWAYS_SET_PATH yes' in /etc/login.defs."
>
> Markus

Thanks.
My /etc/login.defs is now

#
# *REQUIRED*  The default PATH settings, for superuser and normal users.
#
# (they are minimal, add the rest in the shell startup files)
ENV_SUPATH  
PATH=/usr/local/sbin:/usr/local/bin:/usr/sbin:/usr/bin:/sbin:/bin
ENV_PATH    PATH=/usr/local/bin:/usr/bin:/bin:/usr/local/games:/usr/games
ALWAYS_SET_PATH yes


This seems to work.
But to solve the problem this should be added by default.
Then this bug can be closed.

Cheers
karsten



Bug#918754: bash: $PATH in bash does not include /sbin and /usr/sbin

2019-09-05 Thread Markus Koschany
This is a new behavior because the util-linux implementation of su is
used now. See also /usr/share/doc/util-linux/NEWS.Debian.gz for more
information.

"If you want to restore behaviour more similar to
  the previous one you can add 'ALWAYS_SET_PATH yes' in /etc/login.defs."

Markus



signature.asc
Description: OpenPGP digital signature


Bug#918754: bash: $PATH in bash does not include /sbin and /usr/sbin

2019-07-24 Thread OwN-3m-All
This is still a bug in the latest updates for Debian 10.  I just installed
Debian 10, and it's interesting that /usr/sbin isn't in the path unless you
use the following command to switch to the root user:

su -

Switching to the root user using the commands below doesn't produce a $PATH
environment variable with the /sbin and /usr/sbin paths in it.

su root
su

What gives?  This is ridiculous.  Did anyone even test Debian 10 before
releasing?  How embarrassing.  All variants should work and produce the
same $PATH.


Bug#918754: bash: $PATH in bash does not include /sbin and /usr/sbin

2019-03-11 Thread Andrew Latham
I just hit this on a fresh install. I was concerned something changed but
found the usermod tool in /usr/sbin/ when needing to append a group.

-- 
- Andrew "lathama" Latham -


Bug#918754: bash: $PATH in bash does not include /sbin and /usr/sbin

2019-01-08 Thread Raju Devidas
Package: bash
Version: 4.4.18-3.1
Severity: important

Dear Maintainer,

*** Reporter, please consider answering these questions, where appropriate ***

   * What led up to the situation?
   On a fresh installation of Debian testing/buster, used the Debian Testing
net install CD.
   Installed the MATE desktop from the selection menu in the installer to
install MATE desktop
   Was trying to install Wi-Fi drivers for my laptop. After installing the
drivers, I was trying
   reinsert the iwlwifi kernel module using modprobe.

   * What exactly did you do (or not do) that was effective (or
 ineffective)?
   root@sanganak:~# adduser rajudev sudo
   bash: adduser: command not found
   root@sanganak:~# reboot
   bash: reboot: command not found
   root@sanganak:~# modprobe -r iwlwifi
   bash: modprobe: command not found
   root@sanganak:~#

   * What was the outcome of this action?
apparently the above commands were not there in there relative PATH's by
default

root@sanganak:~# echo $PATH
/usr/local/bin:/usr/bin:/bin:/usr/local/games:/usr/games


   * What outcome did you expect instead?
   Since this was a fresh install of Debian Testing/Buster, the PATH should
have contained
   the paths for /sbin or /usr/sbin etc. by default.



-- System Information:
Debian Release: buster/sid
  APT prefers testing
  APT policy: (500, 'testing')
Architecture: amd64 (x86_64)

Kernel: Linux 4.19.0-1-amd64 (SMP w/4 CPU cores)
Locale: LANG=en_IN, LC_CTYPE=en_IN (charmap=UTF-8), LANGUAGE=en_IN:en 
(charmap=UTF-8)
Shell: /bin/sh linked to /usr/bin/dash
Init: systemd (via /run/systemd/system)
LSM: AppArmor: enabled

Versions of packages bash depends on:
ii  base-files   10.1
ii  debianutils  4.8.6
ii  libc62.28-2
ii  libtinfo66.1+20181013-1

Versions of packages bash recommends:
ii  bash-completion  1:2.8-5

Versions of packages bash suggests:
pn  bash-doc  

-- no debconf information