Greetings! Hope ths is the right place to post this... Or maybe I should do it on bugzilla. Anyway.. With Reference to Bug ID: 124310 Assigned To: pknirsch@xxxxxxxxxx Summary: finger reports incorrect idle times This is an sshd problem. Not a finger bug. There is a solution described here: http://archive.netbsd.se/?list=openssh-bugs&a=2004-04&mid=188151 -------------- Subject: [Bug 855] doesn't properly log logout event in utmp entry when pts From: bugzilla-daemon(-at-)mindrot.org Id:<20040428231648.BC0BF27C189@xxxxxxxxxxxxxxxxxx> Date: Thu, 29 Apr 2004 09:16:48 +1000 (EST) http://bugzilla.mindrot.org/show_bug.cgi?id=855 Summary: doesn't properly log logout event in utmp entry when pts bigger than 999 Product: Portable OpenSSH Version: 3.8p1 Platform: All OS/Version: Linux Status: NEW Severity: normal Priority: P2 Component: sshd AssignedTo: openssh-bugs@xxxxxxxxxxx ReportedBy: arekm@xxxxxxxxxxxxx The problem is: syslogin_perform_logout() uses char line[8]; so tty name can have max 7 characters which is not common on recent linux 2.6.5 (and higher) systems which do not use first free pts number (see http://testing.lkml.org/slashdot.php? mid=465538 if you are really interested). Due to that there are bad entries in utmp left like: misiek pts/1049 192.168.2.2 Thu Apr 29 01:11 gone - no logout misiek pts/1046 192.168.2.2 Thu Apr 29 01:05 gone - no logout misiek pts/1045 192.168.2.2 Thu Apr 29 01:05 gone - no logout misiek pts/1044 192.168.2.2 Thu Apr 29 01:04 gone - no logout Patch to fix issue: diff -urN openssh-3.8p1.org/loginrec.c openssh-3.8p1/loginrec.c --- openssh-3.8p1.org/loginrec.c 2004-04-29 01:06:46.350105456 +0200 +++ openssh-3.8p1/loginrec.c 2004-04-29 01:07:37.357351176 +0200 @@ -1354,7 +1354,7 @@ syslogin_perform_logout(struct logininfo *li) { # ifdef HAVE_LOGOUT - char line[8]; + char line[LINFO_LINESIZE]; (void)line_stripname(line, li->line, sizeof(line)); ---------------- Please fix! :) Thanks and Regards Deepak