Thorsten Kukuk [Wed, 26 Nov 2003 10:31:10 +0000 (10:31 +0000)]
Relevant BUGIDs: 849545
Purpose of commit: bugfix/cleanup
Commit summary:
---------------
CFLAGS from configure run is ignored by Make.Rules.
modules should build after libpam, so that we can link against libpam.
In one place, "ar" instead of "$(AR)" is used.
Thorsten Kukuk [Wed, 26 Nov 2003 08:50:59 +0000 (08:50 +0000)]
Relevant BUGIDs: 849498
Purpose of commit: bugfix
Commit summary:
---------------
The type of remember in support.c is int, not
long. But we compare remember with LONG_MIN
and LONG_MAX. While this works on 32bit
architectures, this fails on 64bit one.
INT_MIN and INT_MAX should be used.
Thorsten Kukuk [Tue, 25 Nov 2003 09:06:54 +0000 (09:06 +0000)]
Relevant BUGIDs: 848337
Purpose of commit: bugfix
Commit summary:
---------------
pam_shells uses strlen/strcmp, but does not
include the corresponding string.h header file.
This could lead to problems on architectures,
where gcc needs a correct prototype to generate
correct calling code.
pam_stress.c complains about a redefined
__USE_BSD symbol. This is a internal glibc
define and should not be used in source code.
Thorsten Kukuk [Mon, 24 Nov 2003 14:46:06 +0000 (14:46 +0000)]
Relevant BUGIDs:
Purpose of commit:
bugfix for pam_securetty
Commit summary:
---------------
Move the first usage of uttyname ofter the initialisation
(Bug # 848316). This move was forgetten with the last changes.
Jan Rekorajski [Thu, 25 Sep 2003 17:54:44 +0000 (17:54 +0000)]
Relevant BUGIDs: 812567
Purpose of commit: new feature
Commit summary:
---------------
Implementation of "include" directive for pam config file syntax.
- added module type PAM_T_ANY needed to know if we are loading included file or main one
- let _pam_parse_conf_file() know of new directive
- new function _pam_load_conf_file() used to load "included" configs
Steve Langasek [Sun, 13 Jul 2003 20:01:44 +0000 (20:01 +0000)]
Relevant BUGIDs: 770645
Purpose of commit: cleanup
Commit summary:
---------------
Fix the many compile-time warnings caused by features.h being included
before our _pam_aconf.h. This should make it much easier to find other
bugs.
Also, call config.status instead of configure, to allow rebuilding
generated files with the same options.
Steve Langasek [Sun, 13 Jul 2003 18:41:04 +0000 (18:41 +0000)]
Relevant BUGIDs: 643357
Purpose of commit: bugfix
Commit summary:
---------------
Patch from Sam Hartman to fix handling of module linking on Linux:
modules should be linked against libpam if they call any functions from
the library, since not all platforms will correctly resolve symbol
references otherwise. Also, make sure we use gcc, not ld, when linking,
since there's additional linker glue that gcc will pull in for us.
Steve Langasek [Sun, 13 Jul 2003 06:43:04 +0000 (06:43 +0000)]
Relevant BUGIDs: patch 476984
Purpose of commit: bugfix
Commit summary:
---------------
Patch from Nalin Dahyabhai: always compare tty names without the "/dev",
working around inconsistent handling among apps.
Also, make minor adjustments for robustness (handle DOS EOL chars, and
don't hardcode array sizes).
Steve Langasek [Sun, 13 Jul 2003 06:34:15 +0000 (06:34 +0000)]
Relevant BUGIDs: patch 476976
Purpose of commit: bugfix
Commit summary:
---------------
Patch from Nalin Dahyabhai: when updating /etc/{passwd,shadow}, always
respect any admin-specified permissions on the existing files.
Steve Langasek [Sun, 13 Jul 2003 06:16:13 +0000 (06:16 +0000)]
Relevant BUGIDs: patch 476968
Purpose of commit: bugfix
Commit summary:
---------------
Patch from Nalin Dahyabhai to prevent a buffer overflow in pam_issue
(rare, but could be triggered by a race condition when the admin updates
/etc/issue).
Steve Langasek [Sun, 13 Jul 2003 05:14:08 +0000 (05:14 +0000)]
Relevant BUGIDs: patch 476936
Purpose of commit: cleanup
Commit summary:
---------------
Variant on Nalin's patch: 'unsigned int' is /usually/ 32 bits, but
uint32_t is /always/ 32 bits -- where present. Since C99 is fairly
recent, we may need some autoconf support for older platforms, but
should at least be covered for Linux & Solaris. (Still a better choice
than the non-standard sys/types.h, though.)
Andrew G. Morgan [Sat, 13 Jul 2002 05:48:19 +0000 (05:48 +0000)]
Relevant BUGIDs: 476951, 476953
Purpose of commit: bugfix
Commit summary:
---------------
Be more careful when using the deny option - pay attention to the trust
option before you grant access.
Fix from Nalin.
Andrew G. Morgan [Thu, 11 Jul 2002 06:22:45 +0000 (06:22 +0000)]
Relevant BUGIDs: 476941, 476980
Purpose of commit: bugfix and new feature
Commit summary:
---------------
fix case that wheel is the primary group of the user
add support for passwordless transitions from a trusted user to another
non-root user.
Andrew G. Morgan [Thu, 11 Jul 2002 05:43:50 +0000 (05:43 +0000)]
Relevant BUGIDs: 476963
Purpose of commit: new feature
Commit summary:
---------------
some applications are not prepared to get a SIGCHLD from a child
process they didn't think they launched, so we now suppress
this signal for the duration of use of the helper binary.
The 'noreap' module argument is provided to override this new
default.
Commit summary:
---------------
bigcrypt does not match crypt when password length is too long.
This led to a pam_unix problem when the module had not set the
password in bigcrypt mode, but was trying to compare with bigcrypt
output. The fix is to use the stored password as a guide to how much
of the encrypted password to compare against.
Andrew G. Morgan [Thu, 27 Jun 2002 05:54:05 +0000 (05:54 +0000)]
Relevant BUGIDs: 415423
Purpose of commit: cleanup
Commit summary:
---------------
Shouldn't explicitly include prototype in the file - it conflicts with
common defaults and thus should not be there. (Request for removal from
David Lee.)
Andrew G. Morgan [Thu, 27 Jun 2002 05:43:28 +0000 (05:43 +0000)]
Relevant BUGIDs: 419307
Purpose of commit: new feature/cleanup
Commit summary:
---------------
made pam_nologin more secure by changing the default behavior and
adding some more features. General code clean up in the process.
Andrew G. Morgan [Thu, 27 Jun 2002 04:04:54 +0000 (04:04 +0000)]
Relevant BUGIDs: 565470
Purpose of commit: bugfix
Commit summary:
---------------
It seems that configure was barfing on some packages because libpam_misc
could not compile without also being linked to libpam.
Andrew G. Morgan [Wed, 29 May 2002 06:35:46 +0000 (06:35 +0000)]
Relevant BUGIDs: 491466
Purpose of commit: cleanup
Commit summary:
---------------
These were all suggestions from the OS X patch provided by Luke Howard.
There is another proposed patch for OS X support which promises to be
a little cleaner with the heavy stuff, so I am committing these simple
changes now, with the intention of moving to the other patch for the
big stuff (see 534205).
Andrew G. Morgan [Wed, 29 May 2002 04:51:07 +0000 (04:51 +0000)]
Relevant BUGIDs: 490938, 409852
Purpose of commit: debugging
Commit summary:
---------------
Added a simple wrapper to make it easier to test xsh with the sandbox
libraries (no help with modules - besides editing your personal pam.d/xsh
file).
Andrew G. Morgan [Wed, 29 May 2002 04:44:43 +0000 (04:44 +0000)]
Relevant BUGIDs: 424315
Purpose of commit: cleanup
Commit summary:
---------------
This was a reimplementation of pam_warn to be more useful. I did it in
conjuction with testing the new setcred behavior.
Andrew G. Morgan [Sun, 26 May 2002 23:58:23 +0000 (23:58 +0000)]
Relevant BUGIDs: 517064
Purpose of commit: feature
Commit summary:
---------------
document old feature and add '\]' parsing to make it a better feature.
The feature is that we can accept spaces in module arguments by enclosing
the whole argument inside square brackets. For example a module argument
like this:
"[hello [you\], this is me]"
will be parsed as
"hello [you], this is me"
Not very interesting, but you get the idea.
Thanks to Russell Kliese for requesting this.
Commit summary:
---------------
Both of these fixes inspired by use with X based services.
The first makes a TTY of the form hostname:0 work (if you specify a different
separator with the module argument "fieldsep=".
The second treats "" for a RHOST the same way it would treat a NULL value.
Commit summary:
---------------
there were some dangling file descriptors and unclear pass/fail
properties of some of the password updating code in pam_unix.
Bug report from Len Lattanzi.
Andrew G. Morgan [Sat, 19 Jan 2002 07:10:45 +0000 (07:10 +0000)]
Relevant BUGIDs: 493294
Purpose of commit: bugfix and document
Commit summary:
---------------
The login limit counting seemed to have its math incorrect.
The default has been changed to the sane one, and a new module argument
has been added "utmp_early" that returns the module to its old behavior.
Thanks to Berend De Schouwe for getting to the bottom of this issue.
Andrew G. Morgan [Tue, 11 Dec 2001 07:41:39 +0000 (07:41 +0000)]
Relevant BUGIDs: 486063
Purpose of commit: compatibility
Commit summary:
---------------
A BSD fix from Dag-Erling Smørgrav and Anton Berezin. What was there
before did not correctly deal with BSD dynamic linking.
Commit summary:
---------------
If you are looking for an object that you can blindly dlopen() and
use to bind to pam w/ modules, this commit is for you. Its not fully
integrated into the build tree, but I'd like some feedback before
wiring it in as a regular feature.
Commit summary:
---------------
pam_unix is too generic a module to override the PAM_USER_PROMPT item.
(More modifications to xsh to help me test this change.)
Commit summary:
---------------
Added libpammodutil and link it with every module as its built.
The issue here is that there is a lot of code that the various modules
use in common, and this staic library can be used to help make this code
more maintainable. I do not intend to make this library dynamic. Especially
right now, as I want to be free to chop and change the API and don't want
to deal with revision control and third party modules.
This checkin makes the pam_rhost_auth module make some use of this new
library. I don't intend to add support for any other module prior to
releasing 0.76.
Commit summary:
---------------
The malloc debugging stuff appears to have had a few residual issues
that I've fixed (trying to resolve another checkin!).
Steve Langasek [Tue, 27 Nov 2001 18:26:29 +0000 (18:26 +0000)]
Relevant BUGIDs: 483959, 113596
Purpose of commit: bugfix
Commit summary:
---------------
* Restore pam_unix's handling of 'likeauth' argument to a known working
state
* prettify AUTH_RETURN macro
* remove redundant argv checks in pam_sm_setcred()
Andrew G. Morgan [Tue, 27 Nov 2001 05:15:37 +0000 (05:15 +0000)]
Relevant BUGIDs: 483959
Purpose of commit: fix memory leak
Commit summary:
---------------
Fernando Trias pointed out a silly memory leak in pam_unix.so. It looks
like some allocated memory that is simply not needed for anything.
Andrew G. Morgan [Mon, 26 Nov 2001 03:04:46 +0000 (03:04 +0000)]
Relevant BUGIDs: 485454
Purpose of commit: revive feature
Commit summary:
---------------
malloc et al. debugging was not supported by the new autoconf setup,
this commit rectifies that. It also adds a couple of header file inclusions
that seem to be needed with recent glibc headers.
Andrew G. Morgan [Tue, 13 Nov 2001 05:07:24 +0000 (05:07 +0000)]
Relevant BUGIDs: 476986
Purpose of commit: new feature, cleanup
Commit summary:
---------------
patch from Nalin to support '+hostname' as equivalent to 'hostname'.
fixed compiler warning by working out when to include header file.
Andrew G. Morgan [Thu, 11 Oct 2001 04:52:25 +0000 (04:52 +0000)]
Relevant BUGIDs: 468724
Purpose of commit: bugfix
Commit summary:
---------------
Legacy behavior for pam_close_session and pam_setcred was not sufficient.
Basically, it appears to be common practice for some applications to call
these functions without first calling pam_authenticate and pam_open_session
which would have frozen the auth and session module stacks.
The new behavior is to treat the returns of these secondary functions as
authoritative when navigating the stack in the absence of a chain-freezing
first set of calls.
pam_chauthtok should not benefit from this behavior, and there does not
appear to be a justification for using an event like this to freeze the
stack outright - legacy behavior did not do that.
Andrew G. Morgan [Thu, 11 Oct 2001 04:14:30 +0000 (04:14 +0000)]
Relevant BUGIDs: 463984
Purpose of commit: bugfix
Commit summary:
---------------
The last fix to the conversation function was less than marginal: it
didn't actually work! This second commit adds the all important 'return
the user's input' bit!
Also added some more D() stuff to pam_misc to help locate the problem
and finally cleaned up the Makefile in the examples/ directory. I used
xsh to do the testing.
Andrew G. Morgan [Wed, 10 Oct 2001 05:00:11 +0000 (05:00 +0000)]
Relevant BUGIDs: 424315
Purpose of commit: cleanup, new feature
Commit summary:
---------------
I'm adding a new module (pam_debug) that helped me to verify that
the new setcred handling did not suffer from a bug in the handling
of 'auth optional'. I'm also fixing a D(()) line from
libpam/pam_dispatch.c which was simply broken.
[There is still an outstanding backward compatibility issue with
pam_dispatch that I'll address with respect to Bug 468724.]
Andrew G. Morgan [Wed, 19 Sep 2001 06:16:34 +0000 (06:16 +0000)]
Relevant BUGIDs: 440107
Purpose of commit: keep configure in synch
Commit summary:
---------------
Vorlon updated configure.in, but didn't check in configure to match it.
I'm doing it so I can test and then commit another patch.