Debian Bug report logs - #614049
ngetty: version 1.1 (from sid) has problems cooperating with pam.

version graph

Package: ngetty; Maintainer for ngetty is NIIBE Yutaka <gniibe@fsij.org>; Source for ngetty is src:ngetty.

Reported by: "L\.Schmidt" <l.dbug@scarydevilmonastery.net>

Date: Sat, 19 Feb 2011 10:24:03 UTC

Severity: grave

Found in version ngetty/1.1-2

Fixed in version ngetty/1.1-3

Done: NIIBE Yutaka <gniibe@fsij.org>

Bug is archived. No further changes may be made.

Toggle useless messages

View this report as an mbox folder, status mbox, maintainer mbox


Report forwarded to debian-bugs-dist@lists.debian.org, NIIBE Yutaka <gniibe@fsij.org>:
Bug#614049; Package ngetty. (Sat, 19 Feb 2011 10:24:08 GMT) Full text and rfc822 format available.

Acknowledgement sent to "L\.Schmidt" <l.dbug@scarydevilmonastery.net>:
New Bug report received and forwarded. Copy sent to NIIBE Yutaka <gniibe@fsij.org>. (Sat, 19 Feb 2011 10:24:08 GMT) Full text and rfc822 format available.

Message #5 received at submit@bugs.debian.org (full text, mbox):

From: "L\.Schmidt" <l.dbug@scarydevilmonastery.net>
To: Debian Bug Tracking System <submit@bugs.debian.org>
Subject: ngetty: version 1.1 (from sid) has problems cooperating with pam.
Date: Sat, 19 Feb 2011 11:15:02 +0100
Package: ngetty
Version: 1.0-1
Severity: grave
Justification: renders package unusable


problem manifests during login dialog, or after dialog was completed. either
case, the screen is blanked, and the "login:" prompt is presented again,
after a variable time elapsed since login or login attempt - mostly between
1 and 20 seconds. According auth.log, username or password are irretrievable,
even though actual login is possible, albeit not persistent. Downgrading pam
to wheezy version doesn't change the behaviour. downgrading ngetty to 1.0,
from wheezy, causes error symptoms to disappear, and reverts to apparently
stable login behaviour again.

from auth.log:
login[24632]: pam_unix(login:auth): auth could not identify password for [user]
login[24632]: FAILED LOGIN (1) on '/dev/tty1' FOR 'user', Authentication failure
login[24632]: pam_securetty(login:auth): unexpected response from failed conversation function
login[24632]: pam_securetty(login:auth): cannot determine username
login[24632]: FAILED LOGIN (2) on '/dev/tty1' FOR 'UNKNOWN', Error in service module
login[24632]: pam_securetty(login:auth): unexpected response from failed conversation function
login[24632]: pam_securetty(login:auth): cannot determine username
login[24632]: FAILED LOGIN (3) on '/dev/tty1' FOR 'UNKNOWN', Error in service module
login[24632]: pam_securetty(login:auth): unexpected response from failed conversation function
login[24632]: pam_securetty(login:auth): cannot determine username
login[24632]: FAILED LOGIN (4) on '/dev/tty1' FOR 'UNKNOWN', Error in service module
login[24632]: pam_securetty(login:auth): unexpected response from failed conversation function
login[24632]: pam_securetty(login:auth): cannot determine username
login[24632]: FAILED LOGIN (5) on '/dev/tty1' FOR 'UNKNOWN', Error in service module
login[24632]: TOO MANY LOGIN TRIES (5) on '/dev/tty1' FOR 'UNKNOWN'
login[24632]: pam_mail(login:session): cannot determine username
login[24632]: pam_unix(login:session): close_session - error recovering username


-- System Information:
Debian Release: wheezy/sid
  APT prefers testing
  APT policy: (500, 'testing')
Architecture: i386 (i686)

Kernel: Linux 2.6.32-5-686 (SMP w/4 CPU cores)
Locale: LANG=C, LC_CTYPE=en (charmap=ANSI_X3.4-1968) (ignored: LC_ALL set to C)
Shell: /bin/sh linked to /bin/dash

-- no debconf information




Information forwarded to debian-bugs-dist@lists.debian.org, NIIBE Yutaka <gniibe@fsij.org>:
Bug#614049; Package ngetty. (Sat, 19 Feb 2011 16:36:10 GMT) Full text and rfc822 format available.

Acknowledgement sent to Nikola Vladov <vladov@riemann.fmi.uni-sofia.bg>:
Extra info received and forwarded to list. Copy sent to NIIBE Yutaka <gniibe@fsij.org>. (Sat, 19 Feb 2011 16:36:10 GMT) Full text and rfc822 format available.

Message #10 received at 614049@bugs.debian.org (full text, mbox):

From: Nikola Vladov <vladov@riemann.fmi.uni-sofia.bg>
To: "L.Schmidt" <l.dbug@scarydevilmonastery.net>, 614049@bugs.debian.org
Subject: Re: Bug#614049: ngetty: version 1.1 (from sid) has problems cooperating with pam.
Date: Sat, 19 Feb 2011 18:25:35 +0200
On Sat, Feb 19, 2011 at 11:15:02AM +0100, L.Schmidt wrote:
> Package: ngetty
> Version: 1.0-1
> Severity: grave
> Justification: renders package unusable
> 
> 
> problem manifests during login dialog, or after dialog was completed. either
> case, the screen is blanked, and the "login:" prompt is presented again,
> after a variable time elapsed since login or login attempt - mostly between
> 1 and 20 seconds. According auth.log, username or password are irretrievable,
> even though actual login is possible, albeit not persistent. Downgrading pam
> to wheezy version doesn't change the behaviour. downgrading ngetty to 1.0,
> from wheezy, causes error symptoms to disappear, and reverts to apparently
> stable login behaviour again.

Hmmm,

something make problem on login.  Ngetty doesn't change terminal setting
like agetty.  Could you try for me the following:

log as root on some terminal and start 

   starce /sbin/agetty 38400 tty8 2>/tmp/XXX.getty

Then login on tty8 and after that immediatelly logout.
Edit then the file /tmp/XXX.getty and remove your password.

Similarly also for:
   starce /sbin/ngetty 8 2>/tmp/XXX.ngetty
and 
   starce -f /sbin/ngetty 8 2>/tmp/XXX.nfgetty

Then send me the files /tmp/XXX.*getty

Since my native system is not debian, I cannot repoduce your
problems.  I am the author of ngetty.

If yoy have mmingetty try also

   starce /sbin/mingetty 8 2>/tmp/XXX.mgetty

Say me also which getty works correct.  You could try
also ngetty-1.0 and ngetty-1.1.  How do you start ngetty
by inittab or by init.d script

/nv

> 
> from auth.log:
> login[24632]: pam_unix(login:auth): auth could not identify password for [user]
> login[24632]: FAILED LOGIN (1) on '/dev/tty1' FOR 'user', Authentication failure
> login[24632]: pam_securetty(login:auth): unexpected response from failed conversation function
> login[24632]: pam_securetty(login:auth): cannot determine username
> login[24632]: FAILED LOGIN (2) on '/dev/tty1' FOR 'UNKNOWN', Error in service module
> login[24632]: pam_securetty(login:auth): unexpected response from failed conversation function
> login[24632]: pam_securetty(login:auth): cannot determine username
> login[24632]: FAILED LOGIN (3) on '/dev/tty1' FOR 'UNKNOWN', Error in service module
> login[24632]: pam_securetty(login:auth): unexpected response from failed conversation function
> login[24632]: pam_securetty(login:auth): cannot determine username
> login[24632]: FAILED LOGIN (4) on '/dev/tty1' FOR 'UNKNOWN', Error in service module
> login[24632]: pam_securetty(login:auth): unexpected response from failed conversation function
> login[24632]: pam_securetty(login:auth): cannot determine username
> login[24632]: FAILED LOGIN (5) on '/dev/tty1' FOR 'UNKNOWN', Error in service module
> login[24632]: TOO MANY LOGIN TRIES (5) on '/dev/tty1' FOR 'UNKNOWN'
> login[24632]: pam_mail(login:session): cannot determine username
> login[24632]: pam_unix(login:session): close_session - error recovering username
> 
> 
> -- System Information:
> Debian Release: wheezy/sid
>   APT prefers testing
>   APT policy: (500, 'testing')
> Architecture: i386 (i686)
> 
> Kernel: Linux 2.6.32-5-686 (SMP w/4 CPU cores)
> Locale: LANG=C, LC_CTYPE=en (charmap=ANSI_X3.4-1968) (ignored: LC_ALL set to C)
> Shell: /bin/sh linked to /bin/dash
> 
> -- no debconf information
> 
> 
> 




Information forwarded to debian-bugs-dist@lists.debian.org, NIIBE Yutaka <gniibe@fsij.org>:
Bug#614049; Package ngetty. (Mon, 21 Feb 2011 03:57:03 GMT) Full text and rfc822 format available.

Acknowledgement sent to Guillem Jover <guillem@debian.org>:
Extra info received and forwarded to list. Copy sent to NIIBE Yutaka <gniibe@fsij.org>. (Mon, 21 Feb 2011 03:57:03 GMT) Full text and rfc822 format available.

Message #15 received at 614049@bugs.debian.org (full text, mbox):

From: Guillem Jover <guillem@debian.org>
To: Nikola Vladov <vladov@riemann.fmi.uni-sofia.bg>, 614049@bugs.debian.org
Cc: "L.Schmidt" <l.dbug@scarydevilmonastery.net>
Subject: Re: Bug#614049: ngetty: version 1.1 (from sid) has problems cooperating with pam.
Date: Mon, 21 Feb 2011 04:51:41 +0100
found 614049 1.1-2
notfound 614049 1.0-1
thanks

Hi!

On Sat, 2011-02-19 at 18:25:35 +0200, Nikola Vladov wrote:
> On Sat, Feb 19, 2011 at 11:15:02AM +0100, L.Schmidt wrote:
> > Package: ngetty
> > Version: 1.0-1
> > Severity: grave
> > Justification: renders package unusable

> > problem manifests during login dialog, or after dialog was completed. either
> > case, the screen is blanked, and the "login:" prompt is presented again,
> > after a variable time elapsed since login or login attempt - mostly between
> > 1 and 20 seconds. According auth.log, username or password are irretrievable,
> > even though actual login is possible, albeit not persistent. Downgrading pam
> > to wheezy version doesn't change the behaviour. downgrading ngetty to 1.0,
> > from wheezy, causes error symptoms to disappear, and reverts to apparently
> > stable login behaviour again.
> 
> Hmmm,
> 
> something make problem on login.  Ngetty doesn't change terminal setting
> like agetty.  Could you try for me the following:
> 
> log as root on some terminal and start 
> 
>    starce /sbin/agetty 38400 tty8 2>/tmp/XXX.getty
> 
> Then login on tty8 and after that immediatelly logout.
> Edit then the file /tmp/XXX.getty and remove your password.
> 
> Similarly also for:
>    starce /sbin/ngetty 8 2>/tmp/XXX.ngetty
> and 
>    starce -f /sbin/ngetty 8 2>/tmp/XXX.nfgetty
> 
> Then send me the files /tmp/XXX.*getty
> 
> Since my native system is not debian, I cannot repoduce your
> problems.  I am the author of ngetty.
> 
> If yoy have mmingetty try also
> 
>    starce /sbin/mingetty 8 2>/tmp/XXX.mgetty
> 
> Say me also which getty works correct.  You could try
> also ngetty-1.0 and ngetty-1.1.  How do you start ngetty
> by inittab or by init.d script

Found this problem too the other day when upgrading but didn't have
the time to file a bug report. Anyway, the problem here is that init
starts the agettys from inittab and ngetty starts itself too from the
new init script. And both gettys fight for the terminal. This will
happen if one has not deactivated the gettys entries in inittab, it
might also happen if one has configured inittab to start the ngetty
helper.

The correct solution here is to remove the init script, and the users
should change the inittab themselves. This also agrees with the sance
from the sysvinit maintainer in #613618.

thanks,
guillem




Bug Marked as found in versions ngetty/1.1-2. Request was from Guillem Jover <guillem@debian.org> to control@bugs.debian.org. (Mon, 21 Feb 2011 03:57:04 GMT) Full text and rfc822 format available.

Bug No longer marked as found in versions ngetty/1.0-1. Request was from Guillem Jover <guillem@debian.org> to control@bugs.debian.org. (Mon, 21 Feb 2011 03:57:05 GMT) Full text and rfc822 format available.

Information forwarded to debian-bugs-dist@lists.debian.org, NIIBE Yutaka <gniibe@fsij.org>:
Bug#614049; Package ngetty. (Mon, 21 Feb 2011 10:09:11 GMT) Full text and rfc822 format available.

Acknowledgement sent to Nikola Vladov <vladov@riemann.fmi.uni-sofia.bg>:
Extra info received and forwarded to list. Copy sent to NIIBE Yutaka <gniibe@fsij.org>. (Mon, 21 Feb 2011 10:09:11 GMT) Full text and rfc822 format available.

Message #24 received at 614049@bugs.debian.org (full text, mbox):

From: Nikola Vladov <vladov@riemann.fmi.uni-sofia.bg>
To: Guillem Jover <guillem@debian.org>, 614049@bugs.debian.org
Subject: Re: Bug#614049: ngetty: version 1.1 (from sid) has problems cooperating with pam.
Date: Mon, 21 Feb 2011 12:08:30 +0200
On Mon, Feb 21, 2011 at 04:51:41AM +0100, Guillem Jover wrote:
> found 614049 1.1-2
> notfound 614049 1.0-1

...
 
> Anyway, the problem here is that init
> starts the agettys from inittab and ngetty starts itself too from the
> new init script. And both gettys fight for the terminal. This will
> happen if one has not deactivated the gettys entries in inittab, it
> might also happen if one has configured inittab to start the ngetty
> helper.
> 
> The correct solution here is to remove the init script, and the users
> should change the inittab themselves. This also agrees with the sance
> from the sysvinit maintainer in #613618.

Right!  The problem is how to find which ttys are unused.  If X-server
or agetty opens /dev/tty1 we should not start ngetty on tty1.  I wrote
a simple program which find all free ttys.  If this solves the problem
in next release of ngetty I'll include it in the package.  Maybe the
name lsfreevt is better ;)  Start for example:
	tryvt 12
to see which tty <= 12 are free (not in use).
You must start it as root or make it SUID.

How do you find the idea:
	ngetty -5
It finds the first 5 free consoles and open them.  They could
be for example:  2 5 6 7 9.  X-server opens the first free tty. 

/nv

----------- tryvt.c ------------
/* 
   [diet -Os] gcc -Wall -W -o tryvt tryvt.c 
   usage: tryvt [number]
   only first two digits of number are important!
*/

#include <unistd.h>
#include <fcntl.h>
#include <sys/ioctl.h>
#include <linux/vt.h>

int main(int argc, char **argv) {
  int vtno, fd, max_consoles;
  char tty[12] = "/dev/tty0", *x = tty + 8; 
  max_consoles = MAX_NR_CONSOLES;

  if (argc > 1) {
    unsigned char ch;
    max_consoles = 0;
    if ((ch = argv[1][0] - '0') < 10) max_consoles = ch;
    if ((ch = argv[1][1] - '0') < 10) max_consoles = max_consoles*10 + ch;
  }

  fd = open(tty, O_RDWR, 0);
  if (fd < 0) return -1;

  do {
    char *y = x;
    if (ioctl(fd, VT_OPENQRY, &vtno) || vtno > max_consoles) break;

    if (vtno >= 10) *y++ = '0' + vtno/10;
    *y++ = '0' + vtno%10;
    *y++ = ' ';

    write(1, x, y-x);
    y[-1] = 0;

    if (open(tty, O_RDWR | O_NOCTTY) < 0) break;
  } while (1);

  write(1,"\n",1);
  return 0;
}




Reply sent to NIIBE Yutaka <gniibe@fsij.org>:
You have taken responsibility. (Sat, 24 Nov 2012 07:51:04 GMT) Full text and rfc822 format available.

Notification sent to "L\.Schmidt" <l.dbug@scarydevilmonastery.net>:
Bug acknowledged by developer. (Sat, 24 Nov 2012 07:51:04 GMT) Full text and rfc822 format available.

Message #29 received at 614049-close@bugs.debian.org (full text, mbox):

From: NIIBE Yutaka <gniibe@fsij.org>
To: 614049-close@bugs.debian.org
Subject: Bug#614049: fixed in ngetty 1.1-3
Date: Sat, 24 Nov 2012 07:47:57 +0000
Source: ngetty
Source-Version: 1.1-3

We believe that the bug you reported is fixed in the latest version of
ngetty, which is due to be installed in the Debian FTP archive.

A summary of the changes between this version and the previous one is
attached.

Thank you for reporting the bug, which will now be closed.  If you
have further comments please address them to 614049@bugs.debian.org,
and the maintainer will reopen the bug report if appropriate.

Debian distribution maintenance software
pp.
NIIBE Yutaka <gniibe@fsij.org> (supplier of updated ngetty package)

(This message was generated automatically at their request; if you
believe that there is a problem with it please contact the archive
administrators by mailing ftpmaster@debian.org)


-----BEGIN PGP SIGNED MESSAGE-----
Hash: SHA256

Format: 1.8
Date: Sat, 24 Nov 2012 16:27:43 +0900
Source: ngetty
Binary: ngetty
Architecture: source amd64
Version: 1.1-3
Distribution: unstable
Urgency: low
Maintainer: NIIBE Yutaka <gniibe@fsij.org>
Changed-By: NIIBE Yutaka <gniibe@fsij.org>
Description: 
 ngetty     - getty replacement - one single daemon for all consoles
Closes: 614049
Changes: 
 ngetty (1.1-3) unstable; urgency=low
 .
   * debian/ngetty.lintian-overrides: Remove dot-slash for newer lintian.
   * debian/ngetty.init.sample: Rename (was: ngetty.init).
     It's just a sample now, it's better to change inittab in most cases.
   * debian/ngetty.examples: New.
   * debian/README.Debian: Add explanation (Closes: #614049).
Checksums-Sha1: 
 32c39ab0983ad9f222ac47312eff6e4582d73117 1365 ngetty_1.1-3.dsc
 ad9c41befb608c5772e9b6b976d51d0157bbaefe 5296 ngetty_1.1-3.debian.tar.gz
 51158ee1cff3146cb6fb3a349062127a076437db 26010 ngetty_1.1-3_amd64.deb
Checksums-Sha256: 
 9937120394c7db68680bd805ca9a4145eaa56dc3a8cf84831fce2dc6e54ce396 1365 ngetty_1.1-3.dsc
 3acc3343955ce46abde236de2bc326b87d8843f8df54ee690c394c2b568f0059 5296 ngetty_1.1-3.debian.tar.gz
 ef6d9070c8ec46b8ef204077e17a8d9aecfd8f885dd4c6c5fc73330025561a23 26010 ngetty_1.1-3_amd64.deb
Files: 
 1b7733dee97f5b00f7e72ae70b543701 1365 comm optional ngetty_1.1-3.dsc
 1802f8e31fdbb6fa54afef87f1f1f75f 5296 comm optional ngetty_1.1-3.debian.tar.gz
 4d205352f8b184b4528df4a0551ea855 26010 comm optional ngetty_1.1-3_amd64.deb

-----BEGIN PGP SIGNATURE-----
Version: GnuPG v1.4.12 (GNU/Linux)

iQEcBAEBCAAGBQJQsHsjAAoJEAC0Xr1Mp7q+UlUH/A5SOTHsjasFxhZqY5LoJUNW
C8B3sDcwNETtUj4qvo2iUUsDbRiXrXsvbCdG6z3Od5O5fh3pyy0QqxffWgi2sy2N
cSduYFWbW1QbFkcQ2+Q+g7Wn+97MkPsoEct0wPk+DFRDx3PPc38zhPxRbpDweNC0
canfkBQj8fdHgvMuo2DcPvpDGbjYV4cPCHca5dUoSKnBaGq66dVRqoHw4BgyzY9q
wHdmcIuXB3afkF1LcrQxw2kOUK9Zqd1zgibozdRO7OpmxFPYzSeBIBgLLdKBktRZ
qCOuTyYmVckGVTao0WOnI9q9BTTE7cy8QJwpQjQyHPUG0jkdDxgrfX85mtaZ5RY=
=NodT
-----END PGP SIGNATURE-----




Bug archived. Request was from Debbugs Internal Request <owner@bugs.debian.org> to internal_control@bugs.debian.org. (Tue, 25 Dec 2012 07:28:25 GMT) Full text and rfc822 format available.

Send a report that this bug log contains spam.


Debian bug tracking system administrator <owner@bugs.debian.org>. Last modified: Thu Apr 17 13:18:24 2014; Machine Name: buxtehude.debian.org

Debian Bug tracking system
Copyright (C) 1999 Darren O. Benham, 1997,2003 nCipher Corporation Ltd, 1994-97 Ian Jackson.