summaryrefslogtreecommitdiff
path: root/server/responder/pam
AgeCommit message (Collapse)AuthorFilesLines
2010-02-18Rename server/ directory to src/Stephen Gallagher5-2080/+0
Also update BUILD.txt
2010-02-18Supress warnings with -O2Jakub Hrozek1-2/+1
2010-02-10Make return values more specific during password changeSumit Bose1-34/+52
- return PAM_AUTHTOK_ERR instead of PAM_SYSTEM_ERR if the password change operation fails - send a message to the user if the system is offline and the password cannot be changed
2010-02-10Send a message to the user if the login is delayedSumit Bose1-3/+24
2010-02-05Added option to use libcrypto instead of NSS.George McCollister1-1/+1
crypto_sha512crypt.c is a clone of nss_sha512crypt.c with the exception that all usage of NSS and related libraries has been switched to libcrypto. I renamed nss_sha512crypt.h to sha512crypt.h since it is common to both crypto_sha512crypt.c and nss_sha512crypt.c. Note that the random number generator is not seeded manually and thus relies on seeding done automatically by libcrypto. On some systems without /dev/urandom seeding may not be performed. See http://www.openssl.org/docs/crypto/RAND_add.html. Signed-off-by: George McCollister <georgem@novatech-llc.com>
2010-02-02Warn the user if authentication happens offlineSumit Bose1-1/+19
2010-02-02Add offline failed login counterSumit Bose1-6/+7
2010-02-01Avoid 'PAM' at the beginning of define and enum namesSumit Bose2-17/+17
2010-01-25Fix size error on 64-bit systemsStephen Gallagher1-1/+1
2010-01-22Pointers to non 32 bit aligned data were being cast to uint32_t *George McCollister1-8/+10
uint32_t pointers must point to 32 bit aligned data on ARM. Instead of padding the data to force it into alignment I altered the code to memcpy the data to an aligned location. I'd appreciate any and all feedback especially on whether I took the best approach. pam_test_client auth and pam_test_client acct now work on my armeb-xscale-linux-gnueabi target. Signed-off-by: George McCollister <georgem@opteron.novatech-llc.com>
2010-01-20Fix a double free bugSumit Bose1-3/+0
2010-01-20Add sysdb request to authenticate against a cached passwordSumit Bose4-216/+59
The code for authentication against a cached password is moved from the pam responder to a generic sysdb tevent request. The new code can be used by other components of sssd to verify passwords on their own. Tests for the sysdb_cache_password and sysdb_cache_auth request are added and some unneeded or unused code and variables are removed.
2009-12-18Fix broken password changes for local usersStephen Gallagher1-1/+6
2009-12-18Handle chauthtok with PAM_PRELIM_CHECK separatelySumit Bose1-0/+6
If pam_sm_chauthtok is called with the flag PAM_PRELIM_CHECK set we generate a separate call to the sssd to validate the old password before asking for a new password and sending the change password request.
2009-11-23Speed up user requests while offlineStephen Gallagher1-3/+5
This adds a new boolean option to sss_dp_send_acct_req() called fast_reply. If we make a request to the backends and we are currently offline, this option will determine whether we should immediately return from the cache (acceptable for NSS requests) or potentially wait for an online check to complete (required for PAM requests).
2009-11-18Change the pam code to perform an initgroups callSimo Sorce1-1/+1
An initgroups call refreshes both the user and the user's groups, this is ideal for pam so that we don't need addiotnal initgroups calls (initgroups calls are cached too now) during the login process.
2009-11-09Fix segfault on unknown user/domainStephen Gallagher1-2/+2
2009-11-09Fix tevent_req error checking.Simo Sorce1-6/+1
When possible using a macro that correctly deals with tstate
2009-10-27Move responsibility for entry expiration timeoutSimo Sorce1-7/+4
The providers are now responsible for determining how long a cached entry is considered valid. The default is the same as before (600s)
2009-10-27Fix segfaultSimo Sorce1-1/+1
Fix copy/paste error that picked up the wrong request structure to pass down. This was causing the talloc code that checks for the right signature to fail and abort as the 2 request structures have different state structures attacched.
2009-10-26Use standard coding practice to set last loginSimo Sorce1-90/+128
This rewrite should also fix a segfault in the code that may happen when exiting in case of error conditions. The previous code was attaching the transaction handle to llreq structure and then calling prepare_reply() from within the request handlers which could ultimately free the preq and llreq and handle before the transaction request was actually completed by tevent.
2009-10-22Add support for offline auth cache timeoutStephen Gallagher4-3/+192
This adds a new option (offline_credentials_expiration) to the [PAM] section of the sssd.conf If the user does not perform an online authentication within the timeout (in days), they will be denied auth once the timeout passes.
2009-10-22Add pam_ctx (similar to nss_ctx) for storing global PAM configStephen Gallagher2-5/+25
2009-10-15Remove two unused functions.Stephen Gallagher1-10/+0
These functions were used when reconnecting to the DP after losing the connection. Since there is no DP any longer, there's no reason to have these functions.
2009-10-15Fix offline authenticationSimo Sorce1-16/+3
The way we were processing errors from the provider caused offline authentication to stop working. Previously the problem was masked by a bug in the data provider that always returned "Success" for any operation no matter what the actual return code was. when DP got removed the bug became evident.
2009-10-09Remove DP processSimo Sorce2-22/+27
Turn the backend process into data provider servers Make Frontends (pam, nss) directly attach to the backends
2009-10-06Remove unused btreemap codeStephen Gallagher1-1/+0
We have converted to using dhash in place of btreemap everywhere in the code.
2009-09-25Send debug messages to logfileJakub Hrozek1-1/+3
Introduces a new option --debug-to-files which makes SSSD output its debug information to a file instead of stderr, which is still the default. Also introduces a new confdb option debug_to_files which does the same, but can be specified per-service in the config file. The logfiles are stored in /var/log/sssd by default. Changes the initscript to log to files by default.
2009-09-25Upgrade confdb to version 2Stephen Gallagher1-5/+4
This converts a great many configuration options to the new standard format.
2009-09-23Revert "Use syslog for logging error conditions in SSSD"Stephen Gallagher5-22/+14
This reverts commit 8c50bd085c0efe5fde354deee2c8118887aae29d. Amended: commit 1016af2b1b97ad4290ccce8fa462cc7e3c191b2e also made use of the SYSLOG_ERROR() macro, so those portions of that code also needed to be reverted.
2009-09-21Use syslog for logging error conditions in SSSDJakub Hrozek5-14/+22
This is just a band-aid until ELAPI is fully functional and ready to use.
2009-09-14make cli_pid mandatory and increase version number of pam protocolSumit Bose1-1/+25
2009-09-14Let the PAM client send its PIDSumit Bose1-0/+19
- the client sends the PID as uint32_t and sssd will use uint32_t too - fix a possible type issue where a uint32_t is sent as int32 in internal dbus communication
2009-09-11Add copyright noticesJakub Hrozek1-0/+21
Fixes: #138
2009-09-08Split database in multiple filesSimo Sorce3-5/+41
The special persistent local database retains the original name. All other backends now have their own cache-NAME.ldb file.
2009-08-17Fix reconnection codeSimo Sorce4-48/+57
Remove redundant reconnection code that was interfeering with the sbus reconnection code. Consolidate include files for sbus relates operations. Make pamsrv code similar to nsssrv code.
2009-08-14Refactor responder_dp.cStephen Gallagher1-6/+6
Many of the functions in responder_dp.c were originally NSS- specific and were moved there from the NSS responder code. Since they are now generic to any responder, rename them to sss_dp_*
2009-08-11Change the why DP clients identifySimo Sorce3-53/+16
Mirrors what we have done with the monitor.
2009-08-11Change services identification mechanismSimo Sorce1-72/+5
Let services identify themselves voiluntarily as the first operation instead of polling from the monitor. Also consolidate some common functions and make them available as monitor helpers.
2009-08-11Make child processes exit when parent diesJakub Hrozek1-0/+6
The child processes call prctl() and when their parent process is killed, they are sent SIGTERM using prctl. This is currently Linux-specific, for non-Linuxes, a similar effect is achieved by catching a set of common termination signals and sending SIGTERM to the process group.
2009-08-11Make socket paths a compile-time optionStephen Gallagher1-1/+0
Previously, we had hardcoded the paths for the NSS, PAM and private PAM sockets to /var/lib/sss/pipes. With this patch, we will specify the sockets with --with-pipe-path.
2009-08-10Simplify interfaces initializationSimo Sorce3-30/+37
Make as much as possible static, and remove use of talloc_reference and allocation/deallocation of memory when not necessary. Fix also responder use of rctx->conn, was mistakenly used for both monitor and dp connections.
2009-08-10Cosmetic changesSimo Sorce2-21/+21
Rationalize and rename connection names in preparatoin for merging of server and connection structures.
2009-08-10Remove redundant memory contextsSimo Sorce2-5/+5
Simplify code by removing stuff that is never used or redundant.
2009-07-29Address CVE-2009-2410Stephen Gallagher1-1/+1
Fix incorrect error code return in local_handler_callback
2009-07-20Implement resInit for monitor, NSS, PAM, DP and the backendsStephen Gallagher1-0/+20
2009-07-03Rework transaction code to use tevent_reqSimo Sorce1-31/+84
This is part of a set of patches to rewrite sysdb to a hopefully better API, that will also let use use tevent_req async style calls to manipulate our cache.
2009-07-03Rename sysdb_req to sysdb_handle.Simo Sorce2-12/+6
This sysdb_req has always really been a transaction handle and not a request. This is part of a set of patches to rewrite transaction support in sysdb to a hopefully better API, that will also let use use tevent_req async style to manipulate our cache.
2009-07-02check pending_return after dbus_connection_send_with_replySumit Bose1-1/+1
2009-07-02added kerberos backend with tevent_req event handlingSumit Bose1-1/+19