Friday, February 10, 2012

login(1) changes

I have completely refactored login(1). The new login(1) merges features from Suse login(1) back into util-linux version and is more compatible with login(1) from shadow-utils. I believe that now we have login(1) implementation which is usable in all mainstream Linux distributions.

The original util-linux login(1) code is derived from 4.3 BSD (so older than Linux kernel).

Changes:
  • PAM only

    It's obvious that in all mainstream distributions is PAM de facto standard for users authentication and maintain any non-PAM methods in login(1) is waste of time.

    If you don't like this change (really?) than you can use login(1) from shadow-utils.

  • support /etc/login.defs(5) config file

    Supported options: MOTD_FILE, LOGIN_TIMEOUT, LOGIN_RETRIES, FAIL_DELAY, TTYPERM, TTYGROUP HUSHLOGIN_FILE, DEFAULT_HOME, LOG_UNKFAIL_ENAB, ENV_PATH, ENV_ROOTPATH, ENV_SUPATH

  • print hostname in the login prompt, the default prompt is compatible with initial prompt from agetty

  • add -H for compatibility with Suse version. This option suppresses the hostname printing in the login prompt.

  • global hush mode for all accounts (enabled if /etc/hushlogins exists, but is empty). The global hush mode allows to use PAM for "Last login" message.
More details: http://thread.gmane.org/gmane.linux.utilities.util-linux-ng/4866

No comments:

Post a Comment