[Touch-packages] [Bug 1097467] Re: bash does not fulfill --rcfile option properly

2024-04-16 Thread Dave Jones
Attaching new debdiff based on the current noble version.

** Patch added: "1097467-3.debdiff"
   
https://bugs.launchpad.net/ubuntu/+source/bash/+bug/1097467/+attachment/5766422/+files/1097467-3.debdiff

-- 
You received this bug notification because you are a member of Ubuntu
Touch seeded packages, which is subscribed to bash in Ubuntu.
https://bugs.launchpad.net/bugs/1097467

Title:
  bash does not fulfill --rcfile option properly

Status in Gnu Bash:
  New
Status in bash package in Ubuntu:
  Confirmed

Bug description:
  I am starting a bash shell using

  $ bash --noprofile --rcfile my-custom-bash-rc-file

  Due to the --rcflag, the newly started bash should *not* execute
  commands from /etc/bash.bashrc. That is at least how I interpret `man
  bash`:

    --rcfile file
    Execute commands from file instead of the system wide 
initialization file /etc/bash.bashrc and the standard personal initial‐
    ization file ~/.bashrc if the shell is interactive (see 
INVOCATION below).

  However, it seems that the commands in /etc/bash.bashrc are in fact
  executed.

  To see/reproduce/diagnose this, on Ubuntu I believe one can just
  invoke bash like this (as the regular user):

  $ touch testrc
  $ env -i bash --noprofile --rcfile testrc

  The expected result would be that nothing special is printed on the
  terminal. However, there is an error message, which is printed from
  /etc/bash.bashrc. The "env -i" causes $HOME to not be set in the
  invoked shell, which in turn triggers the error. The error message is:

  > To run a command as administrator (user "root"), use "sudo ".
  > See "man sudo_root" for details.

  Another way to see this -- without the "env -i" -- is to add  a
  command to /etc/bash.bashrc, such as

  echo HELLO THERE

  To trigger the bug(?), one can then just do

  $ touch testrc
  $ bash --noprofile --rcfile testrc

  The expected result would be that nothing special is shown in the
  terminal. However, it turns out that the string

  HELLO THERE

  is printed.

To manage notifications about this bug go to:
https://bugs.launchpad.net/gnubash/+bug/1097467/+subscriptions


-- 
Mailing list: https://launchpad.net/~touch-packages
Post to : touch-packages@lists.launchpad.net
Unsubscribe : https://launchpad.net/~touch-packages
More help   : https://help.launchpad.net/ListHelp


[Touch-packages] [Bug 1097467] Re: bash does not fulfill --rcfile option properly

2024-04-11 Thread Dave Jones
Bah, looks like this upload got accidentally dropped by the subsequent
merge for noble. I'll rebase and re-proposed it when I've got some
time...

** Changed in: bash (Ubuntu)
   Status: Fix Committed => Confirmed

** Changed in: bash (Ubuntu)
 Assignee: Dan Bungert (dbungert) => Dave Jones (waveform)

-- 
You received this bug notification because you are a member of Ubuntu
Touch seeded packages, which is subscribed to bash in Ubuntu.
https://bugs.launchpad.net/bugs/1097467

Title:
  bash does not fulfill --rcfile option properly

Status in Gnu Bash:
  New
Status in bash package in Ubuntu:
  Confirmed

Bug description:
  I am starting a bash shell using

  $ bash --noprofile --rcfile my-custom-bash-rc-file

  Due to the --rcflag, the newly started bash should *not* execute
  commands from /etc/bash.bashrc. That is at least how I interpret `man
  bash`:

    --rcfile file
    Execute commands from file instead of the system wide 
initialization file /etc/bash.bashrc and the standard personal initial‐
    ization file ~/.bashrc if the shell is interactive (see 
INVOCATION below).

  However, it seems that the commands in /etc/bash.bashrc are in fact
  executed.

  To see/reproduce/diagnose this, on Ubuntu I believe one can just
  invoke bash like this (as the regular user):

  $ touch testrc
  $ env -i bash --noprofile --rcfile testrc

  The expected result would be that nothing special is printed on the
  terminal. However, there is an error message, which is printed from
  /etc/bash.bashrc. The "env -i" causes $HOME to not be set in the
  invoked shell, which in turn triggers the error. The error message is:

  > To run a command as administrator (user "root"), use "sudo ".
  > See "man sudo_root" for details.

  Another way to see this -- without the "env -i" -- is to add  a
  command to /etc/bash.bashrc, such as

  echo HELLO THERE

  To trigger the bug(?), one can then just do

  $ touch testrc
  $ bash --noprofile --rcfile testrc

  The expected result would be that nothing special is shown in the
  terminal. However, it turns out that the string

  HELLO THERE

  is printed.

To manage notifications about this bug go to:
https://bugs.launchpad.net/gnubash/+bug/1097467/+subscriptions


-- 
Mailing list: https://launchpad.net/~touch-packages
Post to : touch-packages@lists.launchpad.net
Unsubscribe : https://launchpad.net/~touch-packages
More help   : https://help.launchpad.net/ListHelp


[Touch-packages] [Bug 1097467] Re: bash does not fulfill --rcfile option properly

2023-11-14 Thread Dan Bungert
Uploaded

** Changed in: bash (Ubuntu)
 Assignee: (unassigned) => Dan Bungert (dbungert)

** Changed in: bash (Ubuntu)
   Status: Confirmed => Fix Committed

-- 
You received this bug notification because you are a member of Ubuntu
Touch seeded packages, which is subscribed to bash in Ubuntu.
https://bugs.launchpad.net/bugs/1097467

Title:
  bash does not fulfill --rcfile option properly

Status in Gnu Bash:
  New
Status in bash package in Ubuntu:
  Fix Committed

Bug description:
  I am starting a bash shell using

  $ bash --noprofile --rcfile my-custom-bash-rc-file

  Due to the --rcflag, the newly started bash should *not* execute
  commands from /etc/bash.bashrc. That is at least how I interpret `man
  bash`:

    --rcfile file
    Execute commands from file instead of the system wide 
initialization file /etc/bash.bashrc and the standard personal initial‐
    ization file ~/.bashrc if the shell is interactive (see 
INVOCATION below).

  However, it seems that the commands in /etc/bash.bashrc are in fact
  executed.

  To see/reproduce/diagnose this, on Ubuntu I believe one can just
  invoke bash like this (as the regular user):

  $ touch testrc
  $ env -i bash --noprofile --rcfile testrc

  The expected result would be that nothing special is printed on the
  terminal. However, there is an error message, which is printed from
  /etc/bash.bashrc. The "env -i" causes $HOME to not be set in the
  invoked shell, which in turn triggers the error. The error message is:

  > To run a command as administrator (user "root"), use "sudo ".
  > See "man sudo_root" for details.

  Another way to see this -- without the "env -i" -- is to add  a
  command to /etc/bash.bashrc, such as

  echo HELLO THERE

  To trigger the bug(?), one can then just do

  $ touch testrc
  $ bash --noprofile --rcfile testrc

  The expected result would be that nothing special is shown in the
  terminal. However, it turns out that the string

  HELLO THERE

  is printed.

To manage notifications about this bug go to:
https://bugs.launchpad.net/gnubash/+bug/1097467/+subscriptions


-- 
Mailing list: https://launchpad.net/~touch-packages
Post to : touch-packages@lists.launchpad.net
Unsubscribe : https://launchpad.net/~touch-packages
More help   : https://help.launchpad.net/ListHelp


[Touch-packages] [Bug 1097467] Re: bash does not fulfill --rcfile option properly

2023-11-14 Thread Dave Jones
Doh, I always forget something...

** Patch added: "1097467-2.debdiff"
   
https://bugs.launchpad.net/gnubash/+bug/1097467/+attachment/5719318/+files/1097467-2.debdiff

-- 
You received this bug notification because you are a member of Ubuntu
Touch seeded packages, which is subscribed to bash in Ubuntu.
https://bugs.launchpad.net/bugs/1097467

Title:
  bash does not fulfill --rcfile option properly

Status in Gnu Bash:
  New
Status in bash package in Ubuntu:
  Confirmed

Bug description:
  I am starting a bash shell using

  $ bash --noprofile --rcfile my-custom-bash-rc-file

  Due to the --rcflag, the newly started bash should *not* execute
  commands from /etc/bash.bashrc. That is at least how I interpret `man
  bash`:

    --rcfile file
    Execute commands from file instead of the system wide 
initialization file /etc/bash.bashrc and the standard personal initial‐
    ization file ~/.bashrc if the shell is interactive (see 
INVOCATION below).

  However, it seems that the commands in /etc/bash.bashrc are in fact
  executed.

  To see/reproduce/diagnose this, on Ubuntu I believe one can just
  invoke bash like this (as the regular user):

  $ touch testrc
  $ env -i bash --noprofile --rcfile testrc

  The expected result would be that nothing special is printed on the
  terminal. However, there is an error message, which is printed from
  /etc/bash.bashrc. The "env -i" causes $HOME to not be set in the
  invoked shell, which in turn triggers the error. The error message is:

  > To run a command as administrator (user "root"), use "sudo ".
  > See "man sudo_root" for details.

  Another way to see this -- without the "env -i" -- is to add  a
  command to /etc/bash.bashrc, such as

  echo HELLO THERE

  To trigger the bug(?), one can then just do

  $ touch testrc
  $ bash --noprofile --rcfile testrc

  The expected result would be that nothing special is shown in the
  terminal. However, it turns out that the string

  HELLO THERE

  is printed.

To manage notifications about this bug go to:
https://bugs.launchpad.net/gnubash/+bug/1097467/+subscriptions


-- 
Mailing list: https://launchpad.net/~touch-packages
Post to : touch-packages@lists.launchpad.net
Unsubscribe : https://launchpad.net/~touch-packages
More help   : https://help.launchpad.net/ListHelp


[Touch-packages] [Bug 1097467] Re: bash does not fulfill --rcfile option properly

2023-11-14 Thread Paride Legovini
Actually, it would be nice if the new patch had some dep-3 headers (see
[1], `quilt --dep3` and maybe dep3changelog). In particular I think we
miss bug references an a description of the patch. Do you think you
could add the relevant ones? Thanks!

[1] https://dep-team.pages.debian.net/deps/dep3/

-- 
You received this bug notification because you are a member of Ubuntu
Touch seeded packages, which is subscribed to bash in Ubuntu.
https://bugs.launchpad.net/bugs/1097467

Title:
  bash does not fulfill --rcfile option properly

Status in Gnu Bash:
  New
Status in bash package in Ubuntu:
  Confirmed

Bug description:
  I am starting a bash shell using

  $ bash --noprofile --rcfile my-custom-bash-rc-file

  Due to the --rcflag, the newly started bash should *not* execute
  commands from /etc/bash.bashrc. That is at least how I interpret `man
  bash`:

    --rcfile file
    Execute commands from file instead of the system wide 
initialization file /etc/bash.bashrc and the standard personal initial‐
    ization file ~/.bashrc if the shell is interactive (see 
INVOCATION below).

  However, it seems that the commands in /etc/bash.bashrc are in fact
  executed.

  To see/reproduce/diagnose this, on Ubuntu I believe one can just
  invoke bash like this (as the regular user):

  $ touch testrc
  $ env -i bash --noprofile --rcfile testrc

  The expected result would be that nothing special is printed on the
  terminal. However, there is an error message, which is printed from
  /etc/bash.bashrc. The "env -i" causes $HOME to not be set in the
  invoked shell, which in turn triggers the error. The error message is:

  > To run a command as administrator (user "root"), use "sudo ".
  > See "man sudo_root" for details.

  Another way to see this -- without the "env -i" -- is to add  a
  command to /etc/bash.bashrc, such as

  echo HELLO THERE

  To trigger the bug(?), one can then just do

  $ touch testrc
  $ bash --noprofile --rcfile testrc

  The expected result would be that nothing special is shown in the
  terminal. However, it turns out that the string

  HELLO THERE

  is printed.

To manage notifications about this bug go to:
https://bugs.launchpad.net/gnubash/+bug/1097467/+subscriptions


-- 
Mailing list: https://launchpad.net/~touch-packages
Post to : touch-packages@lists.launchpad.net
Unsubscribe : https://launchpad.net/~touch-packages
More help   : https://help.launchpad.net/ListHelp


[Touch-packages] [Bug 1097467] Re: bash does not fulfill --rcfile option properly

2023-11-14 Thread Paride Legovini
Thanks for digging into this issue and updating the relevant Debian bug,
refreshing the debdiff. This LGTM, tested locally, the manpage renders
fine. I am going to sponsor this.

-- 
You received this bug notification because you are a member of Ubuntu
Touch seeded packages, which is subscribed to bash in Ubuntu.
https://bugs.launchpad.net/bugs/1097467

Title:
  bash does not fulfill --rcfile option properly

Status in Gnu Bash:
  New
Status in bash package in Ubuntu:
  Confirmed

Bug description:
  I am starting a bash shell using

  $ bash --noprofile --rcfile my-custom-bash-rc-file

  Due to the --rcflag, the newly started bash should *not* execute
  commands from /etc/bash.bashrc. That is at least how I interpret `man
  bash`:

    --rcfile file
    Execute commands from file instead of the system wide 
initialization file /etc/bash.bashrc and the standard personal initial‐
    ization file ~/.bashrc if the shell is interactive (see 
INVOCATION below).

  However, it seems that the commands in /etc/bash.bashrc are in fact
  executed.

  To see/reproduce/diagnose this, on Ubuntu I believe one can just
  invoke bash like this (as the regular user):

  $ touch testrc
  $ env -i bash --noprofile --rcfile testrc

  The expected result would be that nothing special is printed on the
  terminal. However, there is an error message, which is printed from
  /etc/bash.bashrc. The "env -i" causes $HOME to not be set in the
  invoked shell, which in turn triggers the error. The error message is:

  > To run a command as administrator (user "root"), use "sudo ".
  > See "man sudo_root" for details.

  Another way to see this -- without the "env -i" -- is to add  a
  command to /etc/bash.bashrc, such as

  echo HELLO THERE

  To trigger the bug(?), one can then just do

  $ touch testrc
  $ bash --noprofile --rcfile testrc

  The expected result would be that nothing special is shown in the
  terminal. However, it turns out that the string

  HELLO THERE

  is printed.

To manage notifications about this bug go to:
https://bugs.launchpad.net/gnubash/+bug/1097467/+subscriptions


-- 
Mailing list: https://launchpad.net/~touch-packages
Post to : touch-packages@lists.launchpad.net
Unsubscribe : https://launchpad.net/~touch-packages
More help   : https://help.launchpad.net/ListHelp


[Touch-packages] [Bug 1097467] Re: bash does not fulfill --rcfile option properly

2023-11-14 Thread Bug Watch Updater
** Changed in: gnubash
   Status: Unknown => New

-- 
You received this bug notification because you are a member of Ubuntu
Touch seeded packages, which is subscribed to bash in Ubuntu.
https://bugs.launchpad.net/bugs/1097467

Title:
  bash does not fulfill --rcfile option properly

Status in Gnu Bash:
  New
Status in bash package in Ubuntu:
  Confirmed

Bug description:
  I am starting a bash shell using

  $ bash --noprofile --rcfile my-custom-bash-rc-file

  Due to the --rcflag, the newly started bash should *not* execute
  commands from /etc/bash.bashrc. That is at least how I interpret `man
  bash`:

    --rcfile file
    Execute commands from file instead of the system wide 
initialization file /etc/bash.bashrc and the standard personal initial‐
    ization file ~/.bashrc if the shell is interactive (see 
INVOCATION below).

  However, it seems that the commands in /etc/bash.bashrc are in fact
  executed.

  To see/reproduce/diagnose this, on Ubuntu I believe one can just
  invoke bash like this (as the regular user):

  $ touch testrc
  $ env -i bash --noprofile --rcfile testrc

  The expected result would be that nothing special is printed on the
  terminal. However, there is an error message, which is printed from
  /etc/bash.bashrc. The "env -i" causes $HOME to not be set in the
  invoked shell, which in turn triggers the error. The error message is:

  > To run a command as administrator (user "root"), use "sudo ".
  > See "man sudo_root" for details.

  Another way to see this -- without the "env -i" -- is to add  a
  command to /etc/bash.bashrc, such as

  echo HELLO THERE

  To trigger the bug(?), one can then just do

  $ touch testrc
  $ bash --noprofile --rcfile testrc

  The expected result would be that nothing special is shown in the
  terminal. However, it turns out that the string

  HELLO THERE

  is printed.

To manage notifications about this bug go to:
https://bugs.launchpad.net/gnubash/+bug/1097467/+subscriptions


-- 
Mailing list: https://launchpad.net/~touch-packages
Post to : touch-packages@lists.launchpad.net
Unsubscribe : https://launchpad.net/~touch-packages
More help   : https://help.launchpad.net/ListHelp


[Touch-packages] [Bug 1097467] Re: bash does not fulfill --rcfile option properly

2023-11-14 Thread Dave Jones
** Patch added: "1097467-1.debdiff"
   
https://bugs.launchpad.net/gnubash/+bug/1097467/+attachment/5719274/+files/1097467-1.debdiff

-- 
You received this bug notification because you are a member of Ubuntu
Touch seeded packages, which is subscribed to bash in Ubuntu.
https://bugs.launchpad.net/bugs/1097467

Title:
  bash does not fulfill --rcfile option properly

Status in Gnu Bash:
  Unknown
Status in bash package in Ubuntu:
  Confirmed

Bug description:
  I am starting a bash shell using

  $ bash --noprofile --rcfile my-custom-bash-rc-file

  Due to the --rcflag, the newly started bash should *not* execute
  commands from /etc/bash.bashrc. That is at least how I interpret `man
  bash`:

    --rcfile file
    Execute commands from file instead of the system wide 
initialization file /etc/bash.bashrc and the standard personal initial‐
    ization file ~/.bashrc if the shell is interactive (see 
INVOCATION below).

  However, it seems that the commands in /etc/bash.bashrc are in fact
  executed.

  To see/reproduce/diagnose this, on Ubuntu I believe one can just
  invoke bash like this (as the regular user):

  $ touch testrc
  $ env -i bash --noprofile --rcfile testrc

  The expected result would be that nothing special is printed on the
  terminal. However, there is an error message, which is printed from
  /etc/bash.bashrc. The "env -i" causes $HOME to not be set in the
  invoked shell, which in turn triggers the error. The error message is:

  > To run a command as administrator (user "root"), use "sudo ".
  > See "man sudo_root" for details.

  Another way to see this -- without the "env -i" -- is to add  a
  command to /etc/bash.bashrc, such as

  echo HELLO THERE

  To trigger the bug(?), one can then just do

  $ touch testrc
  $ bash --noprofile --rcfile testrc

  The expected result would be that nothing special is shown in the
  terminal. However, it turns out that the string

  HELLO THERE

  is printed.

To manage notifications about this bug go to:
https://bugs.launchpad.net/gnubash/+bug/1097467/+subscriptions


-- 
Mailing list: https://launchpad.net/~touch-packages
Post to : touch-packages@lists.launchpad.net
Unsubscribe : https://launchpad.net/~touch-packages
More help   : https://help.launchpad.net/ListHelp


[Touch-packages] [Bug 1097467] Re: bash does not fulfill --rcfile option properly

2023-11-14 Thread Dave Jones
It appears this has come up before, and was discussed upstream. [1] and
[2] cover discussion of whether --rcfile should ignore the system-wide
bashrc (SYS_BASHRC hereafter), with the conclusion from upstream that it
should not. [3] is an attempt by someone to fix this upstream by
modifying bash's behaviour, which is rejected by the upstream
developers. [4] and [5] are the upstream Debian bugs (which I'll link
this bug to).

At any rate, upstream bash devs have made their position quite clear:
the Debian-patched documentation is wrong, and the behaviour of bash is
as expected. So, the solution to this bug is to fix the documentation.
I'll propose an updated patch here and see if we can't put this decade-
old bug to bed!

I'll also try and rebase the noble patch upstream for Debian (there's
already a patch there, but it's predictably ancient).

[1]: https://lists.gnu.org/archive/html/bug-bash/2018-01/msg3.html

[2]: https://lists.gnu.org/archive/html/bug-bash/2009-05/msg00031.html

[3]: https://savannah.gnu.org/support/index.php?107950

[4]: https://bugs.debian.org/cgi-bin/bugreport.cgi?bug=516152

[5]: https://bugs.debian.org/cgi-bin/bugreport.cgi?bug=343673

** Bug watch added: Debian Bug tracker #516152
   https://bugs.debian.org/cgi-bin/bugreport.cgi?bug=516152

** Bug watch added: Debian Bug tracker #343673
   https://bugs.debian.org/cgi-bin/bugreport.cgi?bug=343673

** Also affects: gnubash via
   https://bugs.debian.org/cgi-bin/bugreport.cgi?bug=516152
   Importance: Unknown
   Status: Unknown

-- 
You received this bug notification because you are a member of Ubuntu
Touch seeded packages, which is subscribed to bash in Ubuntu.
https://bugs.launchpad.net/bugs/1097467

Title:
  bash does not fulfill --rcfile option properly

Status in Gnu Bash:
  Unknown
Status in bash package in Ubuntu:
  Confirmed

Bug description:
  I am starting a bash shell using

  $ bash --noprofile --rcfile my-custom-bash-rc-file

  Due to the --rcflag, the newly started bash should *not* execute
  commands from /etc/bash.bashrc. That is at least how I interpret `man
  bash`:

    --rcfile file
    Execute commands from file instead of the system wide 
initialization file /etc/bash.bashrc and the standard personal initial‐
    ization file ~/.bashrc if the shell is interactive (see 
INVOCATION below).

  However, it seems that the commands in /etc/bash.bashrc are in fact
  executed.

  To see/reproduce/diagnose this, on Ubuntu I believe one can just
  invoke bash like this (as the regular user):

  $ touch testrc
  $ env -i bash --noprofile --rcfile testrc

  The expected result would be that nothing special is printed on the
  terminal. However, there is an error message, which is printed from
  /etc/bash.bashrc. The "env -i" causes $HOME to not be set in the
  invoked shell, which in turn triggers the error. The error message is:

  > To run a command as administrator (user "root"), use "sudo ".
  > See "man sudo_root" for details.

  Another way to see this -- without the "env -i" -- is to add  a
  command to /etc/bash.bashrc, such as

  echo HELLO THERE

  To trigger the bug(?), one can then just do

  $ touch testrc
  $ bash --noprofile --rcfile testrc

  The expected result would be that nothing special is shown in the
  terminal. However, it turns out that the string

  HELLO THERE

  is printed.

To manage notifications about this bug go to:
https://bugs.launchpad.net/gnubash/+bug/1097467/+subscriptions


-- 
Mailing list: https://launchpad.net/~touch-packages
Post to : touch-packages@lists.launchpad.net
Unsubscribe : https://launchpad.net/~touch-packages
More help   : https://help.launchpad.net/ListHelp


[Touch-packages] [Bug 1097467] Re: bash does not fulfill --rcfile option properly

2022-09-30 Thread Nick Rosbrook
** Changed in: bash (Ubuntu)
   Importance: Undecided => Low

-- 
You received this bug notification because you are a member of Ubuntu
Touch seeded packages, which is subscribed to bash in Ubuntu.
https://bugs.launchpad.net/bugs/1097467

Title:
  bash does not fulfill --rcfile option properly

Status in bash package in Ubuntu:
  Confirmed

Bug description:
  I am starting a bash shell using

  $ bash --noprofile --rcfile my-custom-bash-rc-file

  Due to the --rcflag, the newly started bash should *not* execute
  commands from /etc/bash.bashrc. That is at least how I interpret `man
  bash`:

    --rcfile file
    Execute commands from file instead of the system wide 
initialization file /etc/bash.bashrc and the standard personal initial‐
    ization file ~/.bashrc if the shell is interactive (see 
INVOCATION below).

  However, it seems that the commands in /etc/bash.bashrc are in fact
  executed.

  To see/reproduce/diagnose this, on Ubuntu I believe one can just
  invoke bash like this (as the regular user):

  $ touch testrc
  $ env -i bash --noprofile --rcfile testrc

  The expected result would be that nothing special is printed on the
  terminal. However, there is an error message, which is printed from
  /etc/bash.bashrc. The "env -i" causes $HOME to not be set in the
  invoked shell, which in turn triggers the error. The error message is:

  > To run a command as administrator (user "root"), use "sudo ".
  > See "man sudo_root" for details.

  Another way to see this -- without the "env -i" -- is to add  a
  command to /etc/bash.bashrc, such as

  echo HELLO THERE

  To trigger the bug(?), one can then just do

  $ touch testrc
  $ bash --noprofile --rcfile testrc

  The expected result would be that nothing special is shown in the
  terminal. However, it turns out that the string

  HELLO THERE

  is printed.

To manage notifications about this bug go to:
https://bugs.launchpad.net/ubuntu/+source/bash/+bug/1097467/+subscriptions


-- 
Mailing list: https://launchpad.net/~touch-packages
Post to : touch-packages@lists.launchpad.net
Unsubscribe : https://launchpad.net/~touch-packages
More help   : https://help.launchpad.net/ListHelp


[Touch-packages] [Bug 1097467] Re: bash does not fulfill --rcfile option properly

2022-09-29 Thread Julian Andres Klode
This discussion needs to be taken upstream, it's not our place to decide
what is right.

** Tags removed: rls-kk-incoming

-- 
You received this bug notification because you are a member of Ubuntu
Touch seeded packages, which is subscribed to bash in Ubuntu.
https://bugs.launchpad.net/bugs/1097467

Title:
  bash does not fulfill --rcfile option properly

Status in bash package in Ubuntu:
  Confirmed

Bug description:
  I am starting a bash shell using

  $ bash --noprofile --rcfile my-custom-bash-rc-file

  Due to the --rcflag, the newly started bash should *not* execute
  commands from /etc/bash.bashrc. That is at least how I interpret `man
  bash`:

    --rcfile file
    Execute commands from file instead of the system wide 
initialization file /etc/bash.bashrc and the standard personal initial‐
    ization file ~/.bashrc if the shell is interactive (see 
INVOCATION below).

  However, it seems that the commands in /etc/bash.bashrc are in fact
  executed.

  To see/reproduce/diagnose this, on Ubuntu I believe one can just
  invoke bash like this (as the regular user):

  $ touch testrc
  $ env -i bash --noprofile --rcfile testrc

  The expected result would be that nothing special is printed on the
  terminal. However, there is an error message, which is printed from
  /etc/bash.bashrc. The "env -i" causes $HOME to not be set in the
  invoked shell, which in turn triggers the error. The error message is:

  > To run a command as administrator (user "root"), use "sudo ".
  > See "man sudo_root" for details.

  Another way to see this -- without the "env -i" -- is to add  a
  command to /etc/bash.bashrc, such as

  echo HELLO THERE

  To trigger the bug(?), one can then just do

  $ touch testrc
  $ bash --noprofile --rcfile testrc

  The expected result would be that nothing special is shown in the
  terminal. However, it turns out that the string

  HELLO THERE

  is printed.

To manage notifications about this bug go to:
https://bugs.launchpad.net/ubuntu/+source/bash/+bug/1097467/+subscriptions


-- 
Mailing list: https://launchpad.net/~touch-packages
Post to : touch-packages@lists.launchpad.net
Unsubscribe : https://launchpad.net/~touch-packages
More help   : https://help.launchpad.net/ListHelp


[Touch-packages] [Bug 1097467] Re: bash does not fulfill --rcfile option properly

2022-08-23 Thread Dave Jones
** Patch added: "manpage-is-wrong.debdiff"
   
https://bugs.launchpad.net/ubuntu/+source/bash/+bug/1097467/+attachment/5611101/+files/manpage-is-wrong.debdiff

** Tags added: rls-kk-incoming

-- 
You received this bug notification because you are a member of Ubuntu
Touch seeded packages, which is subscribed to bash in Ubuntu.
https://bugs.launchpad.net/bugs/1097467

Title:
  bash does not fulfill --rcfile option properly

Status in bash package in Ubuntu:
  Confirmed

Bug description:
  I am starting a bash shell using

  $ bash --noprofile --rcfile my-custom-bash-rc-file

  Due to the --rcflag, the newly started bash should *not* execute
  commands from /etc/bash.bashrc. That is at least how I interpret `man
  bash`:

    --rcfile file
    Execute commands from file instead of the system wide 
initialization file /etc/bash.bashrc and the standard personal initial‐
    ization file ~/.bashrc if the shell is interactive (see 
INVOCATION below).

  However, it seems that the commands in /etc/bash.bashrc are in fact
  executed.

  To see/reproduce/diagnose this, on Ubuntu I believe one can just
  invoke bash like this (as the regular user):

  $ touch testrc
  $ env -i bash --noprofile --rcfile testrc

  The expected result would be that nothing special is printed on the
  terminal. However, there is an error message, which is printed from
  /etc/bash.bashrc. The "env -i" causes $HOME to not be set in the
  invoked shell, which in turn triggers the error. The error message is:

  > To run a command as administrator (user "root"), use "sudo ".
  > See "man sudo_root" for details.

  Another way to see this -- without the "env -i" -- is to add  a
  command to /etc/bash.bashrc, such as

  echo HELLO THERE

  To trigger the bug(?), one can then just do

  $ touch testrc
  $ bash --noprofile --rcfile testrc

  The expected result would be that nothing special is shown in the
  terminal. However, it turns out that the string

  HELLO THERE

  is printed.

To manage notifications about this bug go to:
https://bugs.launchpad.net/ubuntu/+source/bash/+bug/1097467/+subscriptions


-- 
Mailing list: https://launchpad.net/~touch-packages
Post to : touch-packages@lists.launchpad.net
Unsubscribe : https://launchpad.net/~touch-packages
More help   : https://help.launchpad.net/ListHelp


[Touch-packages] [Bug 1097467] Re: bash does not fulfill --rcfile option properly

2022-08-23 Thread Dave Jones
** Patch added: "bash-is-wrong.debdiff"
   
https://bugs.launchpad.net/ubuntu/+source/bash/+bug/1097467/+attachment/5611100/+files/bash-is-wrong.debdiff

-- 
You received this bug notification because you are a member of Ubuntu
Touch seeded packages, which is subscribed to bash in Ubuntu.
https://bugs.launchpad.net/bugs/1097467

Title:
  bash does not fulfill --rcfile option properly

Status in bash package in Ubuntu:
  Confirmed

Bug description:
  I am starting a bash shell using

  $ bash --noprofile --rcfile my-custom-bash-rc-file

  Due to the --rcflag, the newly started bash should *not* execute
  commands from /etc/bash.bashrc. That is at least how I interpret `man
  bash`:

    --rcfile file
    Execute commands from file instead of the system wide 
initialization file /etc/bash.bashrc and the standard personal initial‐
    ization file ~/.bashrc if the shell is interactive (see 
INVOCATION below).

  However, it seems that the commands in /etc/bash.bashrc are in fact
  executed.

  To see/reproduce/diagnose this, on Ubuntu I believe one can just
  invoke bash like this (as the regular user):

  $ touch testrc
  $ env -i bash --noprofile --rcfile testrc

  The expected result would be that nothing special is printed on the
  terminal. However, there is an error message, which is printed from
  /etc/bash.bashrc. The "env -i" causes $HOME to not be set in the
  invoked shell, which in turn triggers the error. The error message is:

  > To run a command as administrator (user "root"), use "sudo ".
  > See "man sudo_root" for details.

  Another way to see this -- without the "env -i" -- is to add  a
  command to /etc/bash.bashrc, such as

  echo HELLO THERE

  To trigger the bug(?), one can then just do

  $ touch testrc
  $ bash --noprofile --rcfile testrc

  The expected result would be that nothing special is shown in the
  terminal. However, it turns out that the string

  HELLO THERE

  is printed.

To manage notifications about this bug go to:
https://bugs.launchpad.net/ubuntu/+source/bash/+bug/1097467/+subscriptions


-- 
Mailing list: https://launchpad.net/~touch-packages
Post to : touch-packages@lists.launchpad.net
Unsubscribe : https://launchpad.net/~touch-packages
More help   : https://help.launchpad.net/ListHelp


[Touch-packages] [Bug 1097467] Re: bash does not fulfill --rcfile option properly

2022-08-23 Thread Dave Jones
I'm unsure what the "correct" solution is here; could be that bash's
behaviour is wrong, or it could be that the documentation is wrong.
Rather than decide, I'm taking the cowards way out and attaching patches
for both solutions, leaving it to the maintainer to decide which is
appropriate :)

-- 
You received this bug notification because you are a member of Ubuntu
Touch seeded packages, which is subscribed to bash in Ubuntu.
https://bugs.launchpad.net/bugs/1097467

Title:
  bash does not fulfill --rcfile option properly

Status in bash package in Ubuntu:
  Confirmed

Bug description:
  I am starting a bash shell using

  $ bash --noprofile --rcfile my-custom-bash-rc-file

  Due to the --rcflag, the newly started bash should *not* execute
  commands from /etc/bash.bashrc. That is at least how I interpret `man
  bash`:

    --rcfile file
    Execute commands from file instead of the system wide 
initialization file /etc/bash.bashrc and the standard personal initial‐
    ization file ~/.bashrc if the shell is interactive (see 
INVOCATION below).

  However, it seems that the commands in /etc/bash.bashrc are in fact
  executed.

  To see/reproduce/diagnose this, on Ubuntu I believe one can just
  invoke bash like this (as the regular user):

  $ touch testrc
  $ env -i bash --noprofile --rcfile testrc

  The expected result would be that nothing special is printed on the
  terminal. However, there is an error message, which is printed from
  /etc/bash.bashrc. The "env -i" causes $HOME to not be set in the
  invoked shell, which in turn triggers the error. The error message is:

  > To run a command as administrator (user "root"), use "sudo ".
  > See "man sudo_root" for details.

  Another way to see this -- without the "env -i" -- is to add  a
  command to /etc/bash.bashrc, such as

  echo HELLO THERE

  To trigger the bug(?), one can then just do

  $ touch testrc
  $ bash --noprofile --rcfile testrc

  The expected result would be that nothing special is shown in the
  terminal. However, it turns out that the string

  HELLO THERE

  is printed.

To manage notifications about this bug go to:
https://bugs.launchpad.net/ubuntu/+source/bash/+bug/1097467/+subscriptions


-- 
Mailing list: https://launchpad.net/~touch-packages
Post to : touch-packages@lists.launchpad.net
Unsubscribe : https://launchpad.net/~touch-packages
More help   : https://help.launchpad.net/ListHelp


[Touch-packages] [Bug 1097467] Re: bash does not fulfill --rcfile option properly

2022-08-23 Thread Dave Jones
Hmm, on the other hand --norc does indeed suppress both user and system-
wide bashrc files. So, the man-page is correct in that instance, and
apparently the intent of bash is to allow the system-wide bashrc file to
be suppressed in certain circumstances. Which sways me back toward the
notion that the bug is in bash's --rcfile behaviour ...

-- 
You received this bug notification because you are a member of Ubuntu
Touch seeded packages, which is subscribed to bash in Ubuntu.
https://bugs.launchpad.net/bugs/1097467

Title:
  bash does not fulfill --rcfile option properly

Status in bash package in Ubuntu:
  Confirmed

Bug description:
  I am starting a bash shell using

  $ bash --noprofile --rcfile my-custom-bash-rc-file

  Due to the --rcflag, the newly started bash should *not* execute
  commands from /etc/bash.bashrc. That is at least how I interpret `man
  bash`:

    --rcfile file
    Execute commands from file instead of the system wide 
initialization file /etc/bash.bashrc and the standard personal initial‐
    ization file ~/.bashrc if the shell is interactive (see 
INVOCATION below).

  However, it seems that the commands in /etc/bash.bashrc are in fact
  executed.

  To see/reproduce/diagnose this, on Ubuntu I believe one can just
  invoke bash like this (as the regular user):

  $ touch testrc
  $ env -i bash --noprofile --rcfile testrc

  The expected result would be that nothing special is printed on the
  terminal. However, there is an error message, which is printed from
  /etc/bash.bashrc. The "env -i" causes $HOME to not be set in the
  invoked shell, which in turn triggers the error. The error message is:

  > To run a command as administrator (user "root"), use "sudo ".
  > See "man sudo_root" for details.

  Another way to see this -- without the "env -i" -- is to add  a
  command to /etc/bash.bashrc, such as

  echo HELLO THERE

  To trigger the bug(?), one can then just do

  $ touch testrc
  $ bash --noprofile --rcfile testrc

  The expected result would be that nothing special is shown in the
  terminal. However, it turns out that the string

  HELLO THERE

  is printed.

To manage notifications about this bug go to:
https://bugs.launchpad.net/ubuntu/+source/bash/+bug/1097467/+subscriptions


-- 
Mailing list: https://launchpad.net/~touch-packages
Post to : touch-packages@lists.launchpad.net
Unsubscribe : https://launchpad.net/~touch-packages
More help   : https://help.launchpad.net/ListHelp


[Touch-packages] [Bug 1097467] Re: bash does not fulfill --rcfile option properly

2022-08-23 Thread Dave Jones
This has apparently been an issue for some considerable time. I've just
now run into it while delving into a failure in pexpect's test-suite
(during work on LP: #1987420), which apparently assumes that using
--rcfile will suppress both the user *and* the system's bashrc (as the
man-page documents).

However, I'm not entirely convinced this is a bug in bash, so much as
its man-page. Reading the original code (shell.c in bash) its intent is
fairly clear: execute the system-wide bashrc in all interactive shells,
but permit the user's bashrc to be overridden by --rcfile.

It's worth noting that the original (upstream, not Debian) man-page
makes no mention of the system-wide bashrc because it's an option that's
not activated by default. The Debian packaging enables the system-wide
bashrc (SYS_BASHRC in d/p/deb-bash-config.diff) and then patches the
man-page to mention it (d/p/man-bashrc.diff). In other words, I suspect
this is a documentation bug rather than a behavioural bug (i.e. the man-
page is wrong, not the behaviour).

-- 
You received this bug notification because you are a member of Ubuntu
Touch seeded packages, which is subscribed to bash in Ubuntu.
https://bugs.launchpad.net/bugs/1097467

Title:
  bash does not fulfill --rcfile option properly

Status in bash package in Ubuntu:
  Confirmed

Bug description:
  I am starting a bash shell using

  $ bash --noprofile --rcfile my-custom-bash-rc-file

  Due to the --rcflag, the newly started bash should *not* execute
  commands from /etc/bash.bashrc. That is at least how I interpret `man
  bash`:

    --rcfile file
    Execute commands from file instead of the system wide 
initialization file /etc/bash.bashrc and the standard personal initial‐
    ization file ~/.bashrc if the shell is interactive (see 
INVOCATION below).

  However, it seems that the commands in /etc/bash.bashrc are in fact
  executed.

  To see/reproduce/diagnose this, on Ubuntu I believe one can just
  invoke bash like this (as the regular user):

  $ touch testrc
  $ env -i bash --noprofile --rcfile testrc

  The expected result would be that nothing special is printed on the
  terminal. However, there is an error message, which is printed from
  /etc/bash.bashrc. The "env -i" causes $HOME to not be set in the
  invoked shell, which in turn triggers the error. The error message is:

  > To run a command as administrator (user "root"), use "sudo ".
  > See "man sudo_root" for details.

  Another way to see this -- without the "env -i" -- is to add  a
  command to /etc/bash.bashrc, such as

  echo HELLO THERE

  To trigger the bug(?), one can then just do

  $ touch testrc
  $ bash --noprofile --rcfile testrc

  The expected result would be that nothing special is shown in the
  terminal. However, it turns out that the string

  HELLO THERE

  is printed.

To manage notifications about this bug go to:
https://bugs.launchpad.net/ubuntu/+source/bash/+bug/1097467/+subscriptions


-- 
Mailing list: https://launchpad.net/~touch-packages
Post to : touch-packages@lists.launchpad.net
Unsubscribe : https://launchpad.net/~touch-packages
More help   : https://help.launchpad.net/ListHelp


[Touch-packages] [Bug 1097467] Re: bash does not fulfill --rcfile option properly

2022-08-23 Thread Launchpad Bug Tracker
Status changed to 'Confirmed' because the bug affects multiple users.

** Changed in: bash (Ubuntu)
   Status: New => Confirmed

-- 
You received this bug notification because you are a member of Ubuntu
Touch seeded packages, which is subscribed to bash in Ubuntu.
https://bugs.launchpad.net/bugs/1097467

Title:
  bash does not fulfill --rcfile option properly

Status in bash package in Ubuntu:
  Confirmed

Bug description:
  I am starting a bash shell using

  $ bash --noprofile --rcfile my-custom-bash-rc-file

  Due to the --rcflag, the newly started bash should *not* execute
  commands from /etc/bash.bashrc. That is at least how I interpret `man
  bash`:

    --rcfile file
    Execute commands from file instead of the system wide 
initialization file /etc/bash.bashrc and the standard personal initial‐
    ization file ~/.bashrc if the shell is interactive (see 
INVOCATION below).

  However, it seems that the commands in /etc/bash.bashrc are in fact
  executed.

  To see/reproduce/diagnose this, on Ubuntu I believe one can just
  invoke bash like this (as the regular user):

  $ touch testrc
  $ env -i bash --noprofile --rcfile testrc

  The expected result would be that nothing special is printed on the
  terminal. However, there is an error message, which is printed from
  /etc/bash.bashrc. The "env -i" causes $HOME to not be set in the
  invoked shell, which in turn triggers the error. The error message is:

  > To run a command as administrator (user "root"), use "sudo ".
  > See "man sudo_root" for details.

  Another way to see this -- without the "env -i" -- is to add  a
  command to /etc/bash.bashrc, such as

  echo HELLO THERE

  To trigger the bug(?), one can then just do

  $ touch testrc
  $ bash --noprofile --rcfile testrc

  The expected result would be that nothing special is shown in the
  terminal. However, it turns out that the string

  HELLO THERE

  is printed.

To manage notifications about this bug go to:
https://bugs.launchpad.net/ubuntu/+source/bash/+bug/1097467/+subscriptions


-- 
Mailing list: https://launchpad.net/~touch-packages
Post to : touch-packages@lists.launchpad.net
Unsubscribe : https://launchpad.net/~touch-packages
More help   : https://help.launchpad.net/ListHelp


[Touch-packages] [Bug 1097467] Re: bash does not fulfill --rcfile option properly

2022-08-23 Thread Dave Jones
** Summary changed:

- bash does not fulfill --bashrc option properly
+ bash does not fulfill --rcfile option properly

** Description changed:

  I am starting a bash shell using
  
- $ bash --noprofile --bashrc my-custom-bash-rc-file
+ $ bash --noprofile --rcfile my-custom-bash-rc-file
  
  Due to the --rcflag, the newly started bash should *not* execute
  commands from /etc/bash.bashrc. That is at least how I interpret `man
  bash`:
  
-   --rcfile file
-   Execute commands from file instead of the system wide 
initialization file /etc/bash.bashrc and the standard personal initial‐
-   ization file ~/.bashrc if the shell is interactive (see 
INVOCATION below). 
+   --rcfile file
+   Execute commands from file instead of the system wide 
initialization file /etc/bash.bashrc and the standard personal initial‐
+   ization file ~/.bashrc if the shell is interactive (see 
INVOCATION below).
  
  However, it seems that the commands in /etc/bash.bashrc are in fact
  executed.
  
  To see/reproduce/diagnose this, on Ubuntu I believe one can just invoke
  bash like this (as the regular user):
  
  $ touch testrc
- $ env -i bash --noprofile --rcfile testrc 
+ $ env -i bash --noprofile --rcfile testrc
  
  The expected result would be that nothing special is printed on the
  terminal. However, there is an error message, which is printed from
  /etc/bash.bashrc. The "env -i" causes $HOME to not be set in the invoked
  shell, which in turn triggers the error. The error message is:
  
  > To run a command as administrator (user "root"), use "sudo ".
- > See "man sudo_root" for details. 
+ > See "man sudo_root" for details.
  
  Another way to see this -- without the "env -i" -- is to add  a command
  to /etc/bash.bashrc, such as
  
  echo HELLO THERE
  
  To trigger the bug(?), one can then just do
  
  $ touch testrc
- $ bash --noprofile --bashrc testrc
+ $ bash --noprofile --rcfile testrc
  
  The expected result would be that nothing special is shown in the
  terminal. However, it turns out that the string
  
  HELLO THERE
  
  is printed.

-- 
You received this bug notification because you are a member of Ubuntu
Touch seeded packages, which is subscribed to bash in Ubuntu.
https://bugs.launchpad.net/bugs/1097467

Title:
  bash does not fulfill --rcfile option properly

Status in bash package in Ubuntu:
  Confirmed

Bug description:
  I am starting a bash shell using

  $ bash --noprofile --rcfile my-custom-bash-rc-file

  Due to the --rcflag, the newly started bash should *not* execute
  commands from /etc/bash.bashrc. That is at least how I interpret `man
  bash`:

    --rcfile file
    Execute commands from file instead of the system wide 
initialization file /etc/bash.bashrc and the standard personal initial‐
    ization file ~/.bashrc if the shell is interactive (see 
INVOCATION below).

  However, it seems that the commands in /etc/bash.bashrc are in fact
  executed.

  To see/reproduce/diagnose this, on Ubuntu I believe one can just
  invoke bash like this (as the regular user):

  $ touch testrc
  $ env -i bash --noprofile --rcfile testrc

  The expected result would be that nothing special is printed on the
  terminal. However, there is an error message, which is printed from
  /etc/bash.bashrc. The "env -i" causes $HOME to not be set in the
  invoked shell, which in turn triggers the error. The error message is:

  > To run a command as administrator (user "root"), use "sudo ".
  > See "man sudo_root" for details.

  Another way to see this -- without the "env -i" -- is to add  a
  command to /etc/bash.bashrc, such as

  echo HELLO THERE

  To trigger the bug(?), one can then just do

  $ touch testrc
  $ bash --noprofile --rcfile testrc

  The expected result would be that nothing special is shown in the
  terminal. However, it turns out that the string

  HELLO THERE

  is printed.

To manage notifications about this bug go to:
https://bugs.launchpad.net/ubuntu/+source/bash/+bug/1097467/+subscriptions


-- 
Mailing list: https://launchpad.net/~touch-packages
Post to : touch-packages@lists.launchpad.net
Unsubscribe : https://launchpad.net/~touch-packages
More help   : https://help.launchpad.net/ListHelp