bugzilla-daemon at mindrot.org
2002-Jul-18 04:50 UTC
[Bug 345] w (uptime) command still indicates user is logged in after logout
http://bugzilla.mindrot.org/show_bug.cgi?id=345 stevesk at pobox.com changed: What |Removed |Added ---------------------------------------------------------------------------- CC| |Lutz.Jaenicke at aet.TU- | |Cottbus.DE ------- Additional Comments From stevesk at pobox.com 2002-07-18 14:49 ------- *** Bug 352 has been marked as a duplicate of this bug. *** ------- You are receiving this mail because: ------- You are the assignee for the bug, or are watching the assignee.
bugzilla-daemon at mindrot.org
2002-Jul-18 13:26 UTC
[Bug 345] w (uptime) command still indicates user is logged in after logout
http://bugzilla.mindrot.org/show_bug.cgi?id=345 ------- Additional Comments From Lutz.Jaenicke at aet.TU-Cottbus.DE 2002-07-18 23:26 ------- I "trace"ed a little bit: * on login, both /etc/utmpx and /etc/utmp are updated with the login- information * on logout, only /etc/utmpx is updated who (=w) only reads /etc/utmp, so that it gets wrong login information. This applies to today's CVS (2002/07/18). As far as I have added debugging statements, utmpx_write_library() is called for both login and logout. According to the manual page, pututxline() should translate the utmpx entry into an utmp entry and also update utmp accordingly. This only seems to happen for login, not for logout. As far as I have looked over the code, I do not understand, why utmpx_perform_logout() calls line_abbrevname() again (conditionally), as the same code is also part of construct_utmpx(), isn't it? Also utx.ut_type should have been set before unconditionally in construct_utmpx(). So much for now. It seems that the rest is somewhere buried inside pututxline() which does not provide too much diagnostics... Oh, I just see, that in utmpx_perform_login(), there is called utmpx_write_direct(li, &ut) for the case of !UTMPX_USE_LIBRARY (note the "&ut" instead of "&utx", but it does not apply here anyway). ------- You are receiving this mail because: ------- You are the assignee for the bug, or are watching the assignee.
bugzilla-daemon at mindrot.org
2002-Jul-22 13:39 UTC
[Bug 345] w (uptime) command still indicates user is logged in after logout
http://bugzilla.mindrot.org/show_bug.cgi?id=345 ------- Additional Comments From Lutz.Jaenicke at aet.TU-Cottbus.DE 2002-07-22 23:39 ------- More inputs: The problem appears only with privilege separation enabled, it does not appear without privsep. I have added some debugging information and it seems, that the difference between privsep and not is, that without privsep the utmp(x) modifications are performed by 2 processes: the login is performed by the process being the child (later becoming the shell) while the logout is handled by the sshd process. With privsep enabled, both login and logout are handled by the same sshd process (thus pututxline() is called from the same process). I don't know, in how far this influences the process, as the pututxline() function is not open source. Maybe some state information is incorrectly handled, such that the second pututxline() process does handle /etc/utmpx but then has a problem with the /etc/utmp update. This is however just a guess until know. For what it seems to me now, it is more a problem that is caused by HP-UX than a problem of OpenSSH. ------- You are receiving this mail because: ------- You are the assignee for the bug, or are watching the assignee.