Bug 2278 - 'configure --disable-lastlog' should mark PrintLastLog as unsupported in servconf.c
Summary: 'configure --disable-lastlog' should mark PrintLastLog as unsupported in serv...
Status: CLOSED FIXED
Alias: None
Product: Portable OpenSSH
Classification: Unclassified
Component: sshd (show other bugs)
Version: 6.6p1
Hardware: All Solaris
: P5 minor
Assignee: Assigned to nobody
URL:
Keywords:
Depends on:
Blocks: V_6_8
  Show dependency treegraph
 
Reported: 2014-09-17 21:22 AEST by brent.paulson
Modified: 2015-10-22 09:36 AEDT (History)
2 users (show)

See Also:


Attachments
mark PrintLastLog as unsupported if DISABLE_LASTLOG is true (625 bytes, application/octet-stream)
2014-09-17 21:22 AEST, brent.paulson
no flags Details

Note You need to log in before you can comment on or make changes to this bug.
Description brent.paulson 2014-09-17 21:22:56 AEST
Created attachment 2476 [details]
mark PrintLastLog as unsupported if DISABLE_LASTLOG is true

It is possible to disable all lastlog references in OpenSSH by using the
following configure option:

  --disable-lastlog       disable use of lastlog even if detected

This also has the side-effect of removing support for the 'PrintLastLog'
sshd_config(8) keyword although it is still parsed and processed in
servconf.c as if it were possible to change.  The sshd_config(8) man
page describes the PrintLastLog option as:

     PrintLastLog
          Specifies whether sshd(1M) should print  the  date  and
          time  of  the  last  user  login  when  a  user logs in
          interactively.  The default is ``yes''.

Thus, in line with other sshd_config(8) keywords which are no longer
available when the associated functionality is disabled I'd like to
propose patching servconf.c to mark 'printlastlog' as unsupported if
DISABLE_LASTLOG is set.
Comment 1 Damien Miller 2014-12-18 17:48:44 AEDT
applied - thanks!

commit 5a1284bba78f51d09c6f6a7cdec60a7584d55263
Author: Damien Miller <djm@google.com>
Date:   Thu Dec 18 17:43:04 2014 +1100

    turn off PrintLastLog when --disable-lastlog
    
    bz#2278 from Brent Paulson
Comment 2 Damien Miller 2015-03-18 18:17:16 AEDT
openssh-6.8 is released
Comment 3 Tomas Kuthan 2015-10-19 23:28:22 AEDT
That's weird: referenced commit 5a1284bba78f51d09c6f6a7cdec60a7584d55263 does not exist on github and the patch is not applied to HEAD nor 6.8p1.
Comment 4 Damien Miller 2015-10-22 09:36:06 AEDT
Not sure what happened there - I've reapplied the patch and it will be in openssh-7.2