Siduction Forum

Siduction Forum => Upgrade Warnings => Topic started by: dibl on 2012/02/17, 22:35:57

Title: sux "cannot set terminal process group ...." error
Post by: dibl on 2012/02/17, 22:35:57
After d-u today, when you run "sux" in the terminal to become root, you can expect to see an error like this:

Code: [Select]
bash: cannot set terminal process group (-1): Inappropriate ioctl for device
bash: no job control in this shell



There is a bug report:  http://bugs.debian.org/cgi-bin/bugreport.cgi?bug=659878

The error does not prevent root from doing root work.
Title: sux "cannot set terminal process group ...." error
Post by: devil on 2012/02/17, 22:45:16
The real bugreport is http://bugs.debian.org/cgi-bin/bugreport.cgi?bug=659832

greetz
devil
Title: sux "cannot set terminal process group ...." error
Post by: dibl on 2012/02/17, 22:48:19
Aha -- danke, Devil.   :)
Title: sux "cannot set terminal process group ...." error
Post by: devil on 2012/02/17, 23:06:02
The reason for this is to be found in the changelog of login:
Quote
* New upstream release:
- su: Fix possible tty hijacking by dropping the controlling terminal when
executing a command (CVE-2005-4890). Closes: #628843


greetz
devil
Title: sux "cannot set terminal process group ...." error
Post by: braveheartleo on 2012/02/23, 01:59:20
What is broken by the change, which is indicated by this message, is the ability to control foreground jobs (e.g., ctrl+c) from the terminal after logging in from sux.

su, gksu and others are not affected by the change, and can still control and terminate hang-up jobs running in the foreground by doing job control key combinations in the terminal.

To demonstrate:
Code: [Select]
$ su
Passsword: (enter root password)
# cat /dev/zero > /dev/null
(terminal hangs, ctrl+c to kill the job)

$ sux
Passsword: (enter root password)
# cat /dev/zero > /dev/null
(terminal hangs, ctrl+c ends the session with:
Session terminated, terminating shell...^C
but the job is left running. kill the job from another terminal)


quoted from here (http://groups.google.com/group/linux.debian.bugs.dist/msg/2f7a61d32b2bd7b7?dmode=source):
Quote
This needs to be investigated further (in particular to check what sux is
doing, and whether this could be fixed on the sux side).
(The fix removes the controlling terminal for non-interactive executions)
Title: sux "cannot set terminal process group ...." error
Post by: anticapitalista on 2012/02/25, 01:20:41
su -c bash
gives the same error.