[Pkg-kbd-devel] Bug#522453: fgconsole doesn't work as user

Michael Schutte michi at uiae.at
Sun Apr 5 18:39:10 UTC 2009


On Sun, Apr 05, 2009 at 02:03:00PM +0200, Mauro Sacchetto wrote:
> Il domenica 5 aprile 2009 10:41:46 Michael Schutte ha scritto:
> > This is true.  It doesn’t only affect fgconsole, but also chvt, openvt
> > and any other kbd utility which tries to get a console file descriptor.
> [cut]
> > As none of these is able to respond to a VT_GETSTATE ioctl, fgconsole
> > and friends fail.  I’m afraid this situation won’t change.
> Fgconsole fails in Slackware too, if I set
> the automatic access in X.

I may be misunderstanding you here: fgconsole should always fail when
run from a virtual terminal under X, regardless of automatic or manual
login.

> So there is no real solution, if I don't use sudo?

You cannot change the permissions of /dev/tty0 or /dev/console without
opening a giant security hole.  Setting the desired programs suid is an
option, but I’d stay away from it.  sudo is much safer and can be
controlled in more detail (see sudoers(5)).

Cheers,
-- 
Michael Schutte <michi at uiae.at>
-------------- next part --------------
A non-text attachment was scrubbed...
Name: not available
Type: application/pgp-signature
Size: 489 bytes
Desc: Digital signature
URL: <http://lists.alioth.debian.org/pipermail/pkg-kbd-devel/attachments/20090405/a87253d3/attachment.pgp>


More information about the Pkg-kbd-devel mailing list