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 <mi...@uiae.at>

Attachment: signature.asc
Description: Digital signature

Reply via email to