summaryrefslogtreecommitdiffstats
path: root/server/db/sysdb_ops.c
Commit message (Collapse)AuthorAgeFilesLines
* Fix nested group membershipsSimo Sorce2009-12-071-64/+1
| | | | | | | | | Search the local db to find the local DN using the original DN as search key. This way we do not have to rely on weak and faulty heuristicts based on DN names. Add a few helper functions in the process and change the way we pass members to sysdb_store_group_send(), instead of passing users and groups list, just add member DNs to the other sysdb attrs.
* Make strdn build functions more availableSimo Sorce2009-12-071-42/+6
|
* Add sysdb_search_custom requestSumit Bose2009-12-071-11/+86
|
* Correctly escape DN value.Simo Sorce2009-11-201-6/+42
| | | | | In building the DN string we weren't correctly escaping the value of the RDN component. This patches fixes that.
* Fix crash due to uninitialized timeout variableSimo Sorce2009-11-181-0/+1
| | | | | This slipped through in previous patches. Fixes #283
* Refactor delete functions and add a fewSimo Sorce2009-11-101-177/+572
| | | | | | Refactor user/group delete functions so that they can be used without a transaction (they autostart an operation). Add user and group search function where a subfilter can be specified.
* Fix tevent_req error checking.Simo Sorce2009-11-091-56/+18
| | | | When possible using a macro that correctly deals with tstate
* Always set last update and expire timeSimo Sorce2009-11-061-108/+102
| | | | | modifications to existing users/groups were setting metadata, but creation was not. Fixes #259
* Fix for a seg fault during recursive deleteSumit Bose2009-11-041-1/+7
|
* add sysdb_delete_recursive request to sysdb APISumit Bose2009-11-021-0/+153
|
* Allow sysdb_search_entry request to return more than one resultSumit Bose2009-10-291-26/+64
|
* added a ASQ search API for sysdbSumit Bose2009-10-291-0/+218
|
* Move responsibility for entry expiration timeoutSimo Sorce2009-10-271-5/+31
| | | | | The providers are now responsible for determining how long a cached entry is considered valid. The default is the same as before (600s)
* Read the right buffer, avoids potential segfaultsSimo Sorce2009-10-261-5/+5
| | | | Also fix some debug message levels
* add store/search/delete interface for custom sysdb objectsSumit Bose2009-10-221-0/+523
|
* Remove magicPrivateGroups optionSimo Sorce2009-10-091-5/+5
| | | | | | | | | In sssd only local is a native mpg domain, and it is forced. All other providers will have to unroll mpg users into a user/group pair of entries in the db. This allows the provider to automatically establish if the remote server provides mpg users w/o possibily conflicting manual configurations on the client trying to force an mpg behavior where none is provided.
* Revert "Use syslog for logging error conditions in SSSD"Stephen Gallagher2009-09-231-5/+5
| | | | | | | | 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.
* Use syslog for logging error conditions in SSSDJakub Hrozek2009-09-211-5/+5
| | | | | This is just a band-aid until ELAPI is fully functional and ready to use.
* Complete the removal of "legacy" option.Simo Sorce2009-09-111-38/+34
| | | | | | | | | The code was still dependent on it for the ldap driver. Changed the driver code to depend on the schema type. Fix defaults for user and groups trees. ATM if you use the rfc2307bis schema you have to put users and groups in 2 separate trees (what people does by default anyway. If this limitation will turn to be too hard, we will change this later.
* Remove redunant function and always pass attrs.Simo Sorce2009-08-271-29/+11
|
* Always save using member/memberOfSimo Sorce2009-08-271-148/+113
| | | | | First pass to remove the legacy option and make it just a property of the provider
* Add debug statements to sysdb_opsSimo Sorce2009-08-241-10/+111
|
* store additional LDAP attributesSumit Bose2009-08-211-1/+22
| | | | | If available the original DN and the user principle will be stored in sysdb.
* Ensure nextID doesn't reuse an existing local UID or GIDStephen Gallagher2009-08-201-9/+21
| | | | | | | | | If there was no maxID set for a domain, the search filter to check whether the UID was available would always return empty (because no UIDs can be <= 0) This patch changes the search filter if the maxID is unset so that it has no upper limit
* Do not fail enumerations because of range checksSimo Sorce2009-08-101-3/+3
|
* Add ignore_not_found parameter to sysdb delete functionsJakub Hrozek2009-07-311-8/+15
| | | | Also add tests
* Fix saving new nextIDJakub Hrozek2009-07-201-1/+1
|
* fixed typos and a potential memory leakSumit Bose2009-07-091-2/+3
|
* Implement the ldap identity module.Simo Sorce2009-07-081-71/+220
| | | | This uses and exapands the async helpers.
* Unify password caching ops in sysdbSimo Sorce2009-07-081-24/+89
|
* Add async helper functionsSimo Sorce2009-07-081-24/+13
| | | | | | These functions use the tevent_req async model, where a pair of _send/_recv functions pilot requests, with additional helpers like _done functions, and where needed multiple stage helpers.
* Rework transaction code to use tevent_reqSimo Sorce2009-07-031-1250/+2383
| | | | | | 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-031-88/+88
| | | | | | | | | 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.
* Fix manual UID assignment in sysdbJakub Hrozek2009-05-261-11/+15
| | | | | If it's an MPG domain, set them equal. If it's a non-MPG domain, get the next available GID and use that.
* Move actual password caching into sysdbSimo Sorce2009-05-181-1/+49
| | | | Convert auth modules to do the caching themselves
* enable uid/gid generation againSumit Bose2009-04-271-3/+6
|
* fixes for user and group creation in LOCAL domainSumit Bose2009-04-231-0/+19
| | | | | - added range check for supplied UIDs and GIDs - initialize pc_gid to 0 to trigger gid generation
* Always pass full domain infoSimo Sorce2009-04-131-18/+23
| | | | | 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.
* Clean up warnings in SSSDStephen Gallagher2009-04-071-1/+0
|
* Fix segfault error caused by a double freeSimo Sorce2009-03-181-178/+118
| | | | | | | | In delete_callback we were freeing rep after having called return_done() This caused a double free becuse rep is already freed as child of the request when return_done calles the callback. To avoid future errors like this convert return_error and return_done into functions and make them always be the last call of the function and call them as part of the function return.
* Fix returning user with missing optional attributes.Simo Sorce2009-03-101-7/+13
| | | | | | | | | Gecos, homedir and shell are optional, fix the responder not to refuse to return the user completely if they are missing, replace an empty homedir with "/". Also fix fullname vs gecos, and always return gecos for NSS data. On user creation set gecos to the same value as the user Full Name, to help populate the gecos field with data that makes sense.
* Move MPG checks within sysdb.Simo Sorce2009-03-091-12/+184
| | | | | This allows to perform checks and modifications in one transaction. Uses configuration stored in confdb to determins if a domain uses MPGs.
* Implement SetGroupGID in the InfoPipeStephen Gallagher2009-03-091-0/+67
|
* Remove obsolete commentSimo Sorce2009-03-061-3/+0
|
* Remove _PW_ and _GR_ from SYSDB_ definesSimo Sorce2009-03-051-26/+26
| | | | Also unify SYSDB_PW_NAME and SYSDB_GR_NAME in SYSDB_NAME and make it "name"
* Add functions to add regular users and groupsSimo Sorce2009-03-051-15/+286
| | | | | | Calulates next id automatically if uid/gid are not specified. Fixes to sysdb_get_next_available_id. Add tests to create users and groups through the new functions.
* Add internal min/max/next id management fucntionsSimo Sorce2009-03-041-13/+276
| | | | | | | | Retrieve minID and maxID from domain configuration so that lower and upper bounds can be set per domain. Add function that keeps track of the next available id, increments and returns it on requests, avoiding collisions with existing ids.
* Provide sysdb_set_user_attr() functions.Simo Sorce2009-03-031-0/+56
| | | | | | Provide also helper functions to build struct sysdb_attrs. Also fix sysdb_get_user_attr() to have a consistent interface as all other functions.
* Expose some more functions needed by the testsSimo Sorce2009-02-281-0/+98
|
* Convert sync calls in sysdb to async, transaction dependent, calls.Simo Sorce2009-02-281-0/+938