[kmscon-devel] /bin/login always runs on /dev/pts/X

David Herrmann dh.herrmann at gmail.com
Tue May 27 04:44:02 PDT 2014


Hi

On Tue, May 27, 2014 at 12:03 PM, zhang xiong <panda0626 at gmail.com> wrote:
> Recently I face an issue on kmscon:
>
> When I run kmscon, a login terminal pop up immediately. But my user account
> and password can't log in.
>
> Then I found login always runa on /dev/pts/X, but /dev/pts/x isn't in
> /etc/securetty, so I can't login.
>
> How can I let /bin/login run on /dev/ttyX ?

First of all, this only restricts root-logins. You should be able to
use your normal user as login, right?

To allow root-logins, either add "/dev/pts/0" up to "/dev/pts/20" to
/etc/securetty (which is a hack!) or, more appropriately, remove this
line:
    auth       required     pam_securetty.so
from /etc/pam.d/login.

Note that /etc/securetty and pam_securetty is crap (in my opinion).
It's a totally useless way to prevent root-logins. You should protect
root-logins with a proper authentication-scheme, instead of relying on
filters like /etc/securetty (which, btw, don't protect against "sudo"
and "su"..).

Thanks
David


More information about the kmscon-devel mailing list