summaryrefslogtreecommitdiffstats
path: root/src
Commit message (Collapse)AuthorAgeFilesLines
* Correct the NIS defaults for "hosts" mapsNalin Dahyabhai2014-04-221-4/+4
| | | | | The values for NIS hosts.byname and hosts.byaddr maps should start with addresses, not names. Reported by Rik Megens.
* Better handle out-of-memory reading configurationNalin Dahyabhai2014-03-171-8/+6
| | | | | Avoid calling strdup() in a situation where we don't need to, so that we can better handle cases where it fails (static analysis).
* Accept schema-compat-lookup-nsswitch: passwdNalin Dahyabhai2014-03-171-1/+8
| | | | | | Treat "schema-compat-lookup-nsswitch: passwd" in the configuration the same as "schema-compat-lookup-nsswitch: user", to not fail for people who forget and try to use the nsswitch database name.
* Better handle out-of-memory reading configurationNalin Dahyabhai2014-03-171-4/+20
| | | | | | | If we hit out-of-memory (strdup() failures) while reading the configuration, don't crash (static analysis). In some cases, this means we proceed with garbage data until the copy_config() function sanity-checks its input and output.
* Better handle out-of-memory reading configurationNalin Dahyabhai2014-03-171-2/+15
| | | | | If we hit out-of-memory (strdup() failures) while reading the configuration, don't crash (static analysis).
* Ignore unnamed entries when constructing NIS mapsNalin Dahyabhai2014-03-141-2/+3
|
* Fix a couple of memory leaks (static analysis)Nalin Dahyabhai2014-03-141-1/+3
|
* Check for OOM in format_expand_simple()Nalin Dahyabhai2014-03-131-1/+4
|
* Add free() of a NULL pointer to make tools happyNalin Dahyabhai2014-02-171-0/+4
|
* Cast away type-mismatches calling xdr_free() (static analysis)Nalin Dahyabhai2014-02-171-9/+9
|
* Don't leak ftmp on out-of-memory (static analysis)Nalin Dahyabhai2014-02-171-0/+1
|
* Removing domains and maps correctlyNalin Dahyabhai2013-12-161-6/+6
| | | | | On domain or map removal, fill in gaps in the list of domains or maps correctly.
* Remove an unused local variableNalin Dahyabhai2013-12-121-1/+1
|
* Stop checking if a non-NULL value has a NULL valueNalin Dahyabhai2013-12-121-2/+2
|
* Silence a compiler warningNalin Dahyabhai2013-12-121-1/+2
|
* Accept slightly larger fragments (8K vs 8K - 4)Nalin Dahyabhai2013-12-091-4/+4
|
* Don't leak arguments to yp_all() (more of #967468)Nalin Dahyabhai2013-12-091-0/+1
|
* Remove a possible memmove() of 0 bytesNalin Dahyabhai2013-11-191-4/+6
| | | | | Don't bother memmove()ing a 0-byte chunk of data. Found by static analysis.
* Coverity#11937: use proper structure to pass to map_data_set_entry()Alexander Bokovoy2013-11-151-6/+8
| | | | | map_data_set_entry() passes pointers to the lengths of the key and the value to map_data_save_list() which interpretes them as arrays of integers.
* Try reconnecting if rpcbind EPIPEs usNalin Dahyabhai2013-10-013-60/+94
| | | | | | | If the NIS server encounters an EPIPE while attempting to communicate with the portmapper, try to reconnect before giving up on registering. Depending on which RPC implementation is used, rpcbind may drop idle clients after 30 seconds, and our startup can take longer than that.
* Use MSG_NOSIGNAL when sending a request to portmapNalin Dahyabhai2013-10-011-1/+1
|
* Up the log severity on portmap errorsNalin Dahyabhai2013-10-011-9/+9
| | | | | | Log errors encountered while talking to portmap/rpcbind at level SLAPI_LOG_FATAL rather than at the previous SLAPI_LOG_PLUGIN, so that they show up even when we're not actively debugging.
* Add ignore-subtree and restrict-subtree settingsNalin Dahyabhai2013-09-197-74/+333
| | | | | | | | | | | | | | Add {nis,schema-compat}-ignore-subtree (subtrees under which we ignore contents and updates )and {nis,schema-compat}-restrict-subtree (subtrees out of which we ignore contents and updates, if set) settings, and default the former to "cn=tasks,cn=config". This should avoid cases where we're looking through the ldbm backend for entries which have a dangling reference to a newly-added task (which, because it's in the DSE, means we acquire an ldbm lock after acquiring our internal lock) while also updating a compat entry after its source entry is modified (for example, by the memberOf plugin, which results in us attempting to acquire our lock while the ldbm lock is already held).
* Add a missing word in a commentNalin Dahyabhai2013-09-121-1/+1
|
* Add nis-relevant-subtree and nis-ignore-subtreeNalin Dahyabhai2013-09-121-4/+12
|
* Add schema-compat-relevant-subtreeNalin Dahyabhai2013-09-124-3/+42
| | | | | | | | | | Add a schema-compat-relevant-subtree configuration option, listing the only parts of the DIT that we should ever look at, either as source entries or as other entries which contain data which might be pulled in as part of computing the contents of compat entries. This is more or less the whitelist to schema-compat-ignore-subtree's blacklist.
* Add schema-compat-ignore-subtreeNalin Dahyabhai2013-09-125-1/+115
| | | | | | | Add a schema-compat-ignore-subtree configuration option, listing parts of the DIT that we should never look at, neither as source entries nor as random other entries which contain data which might be pulled in as part of computing the contents of compat entries.
* Remove a pair of unused variablesNalin Dahyabhai2013-08-281-2/+0
|
* Warn if we fail to set SO_LINGER for TCP clientsNalin Dahyabhai2013-08-271-1/+7
|
* Warn if non-blocking-ifying a client socket failsNalin Dahyabhai2013-08-271-1/+7
|
* Error out if the listener can't be non-blockingNalin Dahyabhai2013-08-271-2/+9
|
* Omit an unnecessary switch caseNalin Dahyabhai2013-08-271-2/+0
|
* Don't make an unnecessary checkNalin Dahyabhai2013-08-271-1/+1
|
* Skip values that are going to come up emptyNalin Dahyabhai2013-08-271-0/+3
|
* Sanity check the request size correctlyNalin Dahyabhai2013-08-271-3/+4
| | | | | Use the amount of data that we could have read as the upper bound on reasonable-looking request lengths.
* Make sure that length is always initializedNalin Dahyabhai2013-08-271-0/+1
|
* Fix a missing xdr_free()Nalin Dahyabhai2013-08-271-1/+1
|
* Directly return lists when making single queriesNalin Dahyabhai2013-08-271-35/+42
|
* Don't leak "buf" if its contents are unusedNalin Dahyabhai2013-08-271-0/+2
|
* Break out passwd-to-slapi_entry conversionNalin Dahyabhai2013-08-271-55/+70
| | | | | | Break out a backend_make_user_entry_from_nsswitch_passwd function for converting a passwd structure to an entry, and rename the helper for groups to match it.
* Free staged data correctly when locking failsNalin Dahyabhai2013-08-271-0/+2
|
* Don't use pamh before or after it's validNalin Dahyabhai2013-08-271-9/+23
| | | | | Don't use the PAM handle before it's initialized or after it's freed (static analysis).
* Log successful authentication at PLUGIN, not FATALNalin Dahyabhai2013-08-121-1/+1
| | | | | | The server's mainline code doesn't appear to log successful authentication beyond what already shows up in the access log, so we should probably behave ourselves.
* Finish PAM->LDAP mapping logging codeNalin Dahyabhai2013-08-121-15/+40
|
* Handle binds to compat entries without "uid"sNalin Dahyabhai2013-08-121-11/+35
| | | | | | | Use a dummy user name if the one we get passed is NULL, which happens when the bind target entry doesn't contain a "uid" attribute. Try to avoid a timing attack by calling into PAM anyway. Switch to just logging the detailed error information, and telling the client nothing.
* Always use normalized RDNs as map keysNalin Dahyabhai2013-08-121-2/+3
| | | | | | Always use normalized RDNs as map keys, so that we can be sure that a lookup using part of the DN will find the entry, even if it needed to be escaped and/or normalized to something else at some point.
* Only add extensibleObject if we have an SIDNalin Dahyabhai2013-08-121-1/+1
| | | | | | Make the addition of extensibleObject to the list of objectclasses conditional on there being a ipaNTSecurityIdentifier value in the source entry.
* Properly escape DNs of nsswitch-based entriesNalin Dahyabhai2013-08-121-15/+59
|
* Suppress some compiler warningsNalin Dahyabhai2013-08-121-0/+1
|
* Remove some unused variablesNalin Dahyabhai2013-08-122-6/+1
|