summaryrefslogtreecommitdiffstats
path: root/server/responder
Commit message (Collapse)AuthorAgeFilesLines
* Don't go to the backend for identical cache entry requestsStephen Gallagher2009-08-142-54/+294
| | | | | | | | | Currently, if an additional request comes in for a cache entry while that same entry is already in the process of being refreshed, we start a duplicate cache update request. This patch adds allows the cache to maintain a hash table of all in-progress requests and queue up multiple callbacks for updates in progress. Once the data is returned, all of these callbacks will fire.
* Eliminate unnecessary explicit timeout for DP account requestsStephen Gallagher2009-08-121-33/+19
| | | | | | | D-BUS handles timeouts itself and reports DBUS_ERROR_NO_REPLY if a timeout fires, so we can rely on this instead of having an explicit timeout ourselves. Furthermore, the two timeouts present a potential race condition.
* Change the why DP clients identifySimo Sorce2009-08-119-143/+69
| | | | Mirrors what we have done with the monitor.
* Change services identification mechanismSimo Sorce2009-08-114-150/+24
| | | | | | | 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.
* Make child processes exit when parent diesJakub Hrozek2009-08-112-0/+12
| | | | | | | | 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.
* Make socket paths a compile-time optionStephen Gallagher2009-08-112-2/+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.
* Simplify interfaces initializationSimo Sorce2009-08-109-100/+86
| | | | | | | 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.
* merge server and connection structuresSimo Sorce2009-08-102-4/+4
| | | | | | This reduce code duplication as it allows to use one set of watch and timeout functions, and at the same time also allow not to use a secondary structure just to unify these functions.
* Cosmetic changesSimo Sorce2009-08-107-51/+51
| | | | | Rationalize and rename connection names in preparatoin for merging of server and connection structures.
* Remove redundant memory contextsSimo Sorce2009-08-106-30/+36
| | | | Simplify code by removing stuff that is never used or redundant.
* Move parsing of names and domains into util/Jakub Hrozek2009-08-052-120/+1
|
* Address CVE-2009-2410Stephen Gallagher2009-07-291-1/+1
| | | | Fix incorrect error code return in local_handler_callback
* Raise debug level for version negotiationSimo Sorce2009-07-201-2/+2
|
* Implement resInit for monitor, NSS, PAM, DP and the backendsStephen Gallagher2009-07-202-0/+40
|
* Rework transaction code to use tevent_reqSimo Sorce2009-07-031-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.
* Rename sysdb_req to sysdb_handle.Simo Sorce2009-07-032-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.
* check pending_return after dbus_connection_send_with_replySumit Bose2009-07-022-2/+2
|
* added kerberos backend with tevent_req event handlingSumit Bose2009-07-021-1/+19
|
* fix detection of authentication against LOCAL domainSumit Bose2009-06-081-3/+9
|
* Fix user enumeration bugSimo Sorce2009-05-281-4/+0
| | | | | | The previous patch to fix an enumeration bug found with group enumeration inadvertently introduced a bug with user enumeration. Yeah, almost funny!
* special-case NSS calls in PAM codeJakub Hrozek2009-05-281-2/+2
|
* Fix enumerations (bug #42)Simo Sorce2009-05-271-12/+76
| | | | | | | | | | If a backend had all its results filtered in fill_pwent or fill_grent then we would return an empty result, which means "end of results" to the client. Now we return ENOENT and let callers decide what to do. Also make sure we do not grow packets unless we are going to fill them as that's a recipe for killing the client as the size passed to sss_packet_grow is used to determine the size of the final packet.
* fix a wrong timeoutSumit Bose2009-05-261-3/+4
| | | | | The timeout of the data provider call (in ms) got overwritten by a cache timeout (in s).
* Silence warningsSimo Sorce2009-05-263-6/+10
|
* Do not fire up backend search when the data provider is localJakub Hrozek2009-05-262-14/+18
|
* Move actual password caching into sysdbSimo Sorce2009-05-184-126/+2
| | | | Convert auth modules to do the caching themselves
* Prevent accepting blank passwordsSimo Sorce2009-05-181-0/+7
|
* Fix crypt functions to not use static buffers.Simo Sorce2009-05-182-18/+16
| | | | Also fix style, clarify, and simplify some logic.
* added new pam client protocolSumit Bose2009-05-151-1/+132
|
* added more flexible handling of client protocolSumit Bose2009-05-154-2/+63
| | | | | - allow different protocol versions for PAM and NSS - support more than one protocol version in the responder
* added check for NULL valuesSumit Bose2009-05-142-9/+1
| | | | | - allow unspecified value in struct pam_data to be NULL - check if domain structure is initialized in pam_reply
* Fix some more return paths using uninitalized retSimo Sorce2009-05-061-3/+3
|
* Fix use of uninitialized return variableSimo Sorce2009-04-291-5/+5
|
* handle other pam calls when offlineSumit Bose2009-04-281-0/+10
|
* Use different attribute for cached passwords change timeSumit Bose2009-04-281-2/+2
|
* change PAM timeout the match NSS timeSumit Bose2009-04-282-3/+1
|
* Use different attribute for cached passwordsSimo Sorce2009-04-271-3/+3
| | | | | | | This fixes a bug with legacy backends where the cached password would be cleared on a user update. Using a different attribute we make sure a userPassword coming from the remote backend does not interfere with a cachedPassword (and vice versa).
* Eliminate segfault on NSS and PAM responder startup.Stephen Gallagher2009-04-271-0/+4
| | | | | | | | If the data provider is not yet available when NSS and PAM start, they will generate a segmentation fault when trying to configure their automatic reconnection to the Data Provider. I've now added code in sss_dp_init() to detect whether the dp_ctx is NULL and return EIO.
* fix for pam proxy chauthtokSumit Bose2009-04-271-0/+1
| | | | | | | | | | When a user from a domain served by the proxy backend changes his password with passwd the passwd command asks for the old password, but it is not validated by the pam_chauthtok call in the proxy backend, because it is running as root. If the request is coming the unpriviledged socket we now call pam_authenticate explicitly before pam_chauthtok.
* removed length of unused element from packet size calculationSumit Bose2009-04-231-1/+1
| | | | | | The domain name is no longer send as an element on its own, but if set as a member of the response array. If the user was not found pd->domain is NULL and strlen will seg-fault.
* fix for a seq fault when pam_reply_delay is called.Sumit Bose2009-04-221-2/+2
| | | | see https://fedorahosted.org/sssd/ticket/25
* Force user check and discover user's domainSimo Sorce2009-04-176-297/+593
| | | | | | | | | | | Force a user lookup against the users domain provider. If a user domain is not specified search though all non fully qualifying domains. Perform authentication against the corrent domain auth backend, based on the user's domain found in the lookup if one was not specified. Also move the NSS-DP functions in COMMON-DP as they are reused by the PAM responder too now.
* Fix by_id enumeration with multiple domainsSimo Sorce2009-04-161-0/+10
| | | | | | We need to stop parsing domains as soon as a caaandidate is found and let the callback search additional domains if the id is not found. Should fix ticket #21
* Add common function to retrieve comma sep. listsSimo Sorce2009-04-141-11/+13
| | | | | | Also convert all places where we were using custom code to parse config arguments. And fix a copy&paste error in nss_get_config
* Make reconnection to the Data Provider a global settingStephen Gallagher2009-04-142-7/+4
| | | | | | | Previously, every DP client was allowed to set its own "retries" option. This option was ambiguous, and useless. All DP clients will now use a global option set in the services config called "reconnection_retries"
* Add reconnection code between the NSS responder and the Data providerStephen Gallagher2009-04-141-1/+52
|
* Fix a couple of segfaults and timeout checksSimo Sorce2009-04-132-31/+14
|
* Fix segfaults when passing an unknown domainSimo Sorce2009-04-131-9/+20
| | | | | Also setting dctx->domain to NULL is a recipe for segfaults :-) Assign dctx->domain only when dom actually holds a domain pointer.
* Implement credentials caching in pam responder.Simo Sorce2009-04-138-373/+494
| | | | | | | Implement credentials caching in pam responder. Currently works only for the proxy backend. Also cleanup pam responder code and mode common code in data provider. (the data provider should never include responder private headers)
* Always pass full domain infoSimo Sorce2009-04-131-1/+1
| | | | | Change sysdb to always passwd sss_domain_info, not just the domain name. This way domain specific options can always be honored at the db level.