Commit Graph

9 Commits

Author SHA1 Message Date
Dag-Erling Smørgrav 05bd3febc0 Gitify. 2021-10-20 15:44:03 +02:00
Dag-Erling Smørgrav 9cd25f7e7d Switch from $Id$ to $OpenPAM$.
git-svn-id: svn+ssh://svn.openpam.org/svn/openpam/trunk@938 185d5e19-27fe-0310-9dcf-9bff6b9f3609
2017-04-30 21:34:42 +00:00
Dag-Erling Smørgrav 26fbccde77 Bump dates if required on files modified in 2014 or later.
git-svn-id: svn+ssh://svn.openpam.org/svn/openpam/trunk@890 185d5e19-27fe-0310-9dcf-9bff6b9f3609
2016-01-11 16:22:09 +00:00
Dag-Erling Smørgrav d84d7367fe Add a feature flag to control whether to fall back to the "other" policy
for chains that are still empty after the requested policy was loaded.


git-svn-id: svn+ssh://svn.openpam.org/svn/openpam/trunk@862 185d5e19-27fe-0310-9dcf-9bff6b9f3609
2015-07-30 23:42:38 +00:00
Dag-Erling Smørgrav 7dbd5c38b7 In openpam_parse_chain():
1. Finish a comment which was meant to describe the four different
   termination conditions for the loop in openpam_parse_chain() but
   ended in mid-sentence.

2. Ensure that errno is consistently set to EINVAL if a syntax error
   is encountered in the policy file.

3. If openpam_load_module() fails because the module could not be
   loaded, set errno to ENOEXEC instead of ENOENT.  This closes a hole
   where a missing module or a typo in a module name would cause the
   corresponding chain to fail open.  Normally, if the policy exists
   but cannot be loaded, openpam_load_chain() will return an error,
   and openpam_configure() will discard any partially constructed
   chains.  However, openpam_load_chain() interprets ENOENT to mean
   that the policy was not found, so it does not immediately return an
   error, the partially-loaded chain is not discarded, and the policy
   is incorrectly considered to have been successfully loaded.

4. Ensure that errors encountered while parsing an included policy are
   correctly propagated to the original policy, and that ENOENT while
   processing an include directive is a hard error, not a soft error.

CVE-2014-3879


git-svn-id: svn+ssh://svn.openpam.org/svn/openpam/trunk@795 185d5e19-27fe-0310-9dcf-9bff6b9f3609
2014-06-03 21:27:48 +00:00
Dag-Erling Smørgrav 7b4ce30d8e Currently, openpam_policy_path is a hardcoded array of short strings, and
filename is much larger than it needs to be.  However, this might not be
the case in the future.  To be safe, add a length check after strlcpy().
This should silence a Coverity warning about possible array overflow.


git-svn-id: svn+ssh://svn.openpam.org/svn/openpam/trunk@745 185d5e19-27fe-0310-9dcf-9bff6b9f3609
2013-09-21 23:22:48 +00:00
Dag-Erling Smørgrav 32d5e093bd Remove unneeded #include
git-svn-id: svn+ssh://svn.openpam.org/svn/openpam/trunk@667 185d5e19-27fe-0310-9dcf-9bff6b9f3609
2013-03-17 14:24:00 +00:00
Dag-Erling Smørgrav 785bc19867 Move openpam_policy_path into openpam_constants.c, and add a corresponding
openpam_module_path.


git-svn-id: svn+ssh://svn.openpam.org/svn/openpam/trunk@659 185d5e19-27fe-0310-9dcf-9bff6b9f3609
2013-03-11 14:10:13 +00:00
Dag-Erling Smørgrav a9a5497d3f Reorganize:
- move libpam into lib/libpam
 - move the OATH code into lib/liboath
 - move oath.h into include/security
 - update all pointers


git-svn-id: svn+ssh://svn.openpam.org/svn/openpam/trunk@646 185d5e19-27fe-0310-9dcf-9bff6b9f3609
2013-03-05 17:49:06 +00:00
Renamed from lib/openpam_configure.c (Browse further)