problem with PAM and login.defs in shadow-4.0.9

Andreas Haumer <[email protected]> Mon, 27 Jun 2005 11:18:12 +0200
Newsgroups gmane.linux.pld.shadow.general
Organization xS+S
Message-ID <[email protected]>
-----BEGIN PGP SIGNED MESSAGE-----
Hash: SHA1

Hi!

I just tried shadow-4.0.9 and found a problem with the way
login handles /etc/login.defs when PAM support is enabled.

I noticed that def_table in file getdef.c now has many options
removed if USE_PAM is defined. Function def_find() gives an
error if it is called with an option which is not present in
def_table and so any "pam" option in /etc/login.defs produces
an error message. This is fine, as these options ought to be
handled by corresponding pam modules, anyway.

But: The login program itself unconditionally tries to lookup
some of the "pam" options, namely

in login.c:main()
ULIMIT
ENV_TZ
ENV_HZ

in setupenv.c:setupenv()
ENV_SUPATH
ENV_PATH
QMAIL_DIR
MAIL_DIR
MAIL_FILE

All these lookups are done via a call to the def_find()
function and so also print an ugly error messages if pam is
used.

HTH

- - andreas

- --
Andreas Haumer                     | mailto:[email protected]
*x Software + Systeme              | http://www.xss.co.at/
Karmarschgasse 51/2/20             | Tel: +43-1-6060114-0
A-1100 Vienna, Austria             | Fax: +43-1-6060114-71
-----BEGIN PGP SIGNATURE-----
Version: GnuPG v1.4.0 (GNU/Linux)
Comment: Using GnuPG with Thunderbird - http://enigmail.mozdev.org

iD8DBQFCv8RExJmyeGcXPhERAqMmAKCjUIlb3aqTRonTx1n5bYQ3soa1MACfehad
ErgjEqAPrCJ7T45Hk3tW5D4=
=0Exx
-----END PGP SIGNATURE-----