summaryrefslogtreecommitdiffstats
path: root/src/db/sysdb_search.c
Commit message (Collapse)AuthorAgeFilesLines
* Update DEBUG* invocations to use new levelsNikolai Kondrashov2014-05-021-6/+8
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | Use a script (identical to commit 83bf46f4066e3d5e838a32357c201de9bd6ecdfd) to update DEBUG* macro invocations, which use literal numbers for levels, to use bitmask macros instead: grep -rl --include '*.[hc]' DEBUG . | while read f; do mv "$f"{,.orig} perl -e 'use strict; use File::Slurp; my @map=qw" SSSDBG_FATAL_FAILURE SSSDBG_CRIT_FAILURE SSSDBG_OP_FAILURE SSSDBG_MINOR_FAILURE SSSDBG_CONF_SETTINGS SSSDBG_FUNC_DATA SSSDBG_TRACE_FUNC SSSDBG_TRACE_LIBS SSSDBG_TRACE_INTERNAL SSSDBG_TRACE_ALL "; my $text=read_file(\*STDIN); my $repl; $text=~s/ ^ ( .* \b (DEBUG|DEBUG_PAM_DATA|DEBUG_GR_MEM) \s* \(\s* )( [0-9] )( \s*, ) ( \s* ) ( .* ) $ / $repl = $1.$map[$3].$4.$5.$6, length($repl) <= 80 ? $repl : $1.$map[$3].$4."\n".(" " x length($1)).$6 /xmge; print $text; ' < "$f.orig" > "$f" rm "$f.orig" done
* Make DEBUG macro invocations variadicNikolai Kondrashov2014-05-021-12/+12
| | | | | | | | | | | | | | | | | | | | | | | | | Use a script to update DEBUG macro invocations to use it as a variadic macro, supplying format string and its arguments directly, instead of wrapping them in parens. This script was used to update the code (identical to commit a3c8390d19593b1e5277d95bfb4ab206d4785150): grep -rwl --include '*.[hc]' DEBUG . | while read f; do mv "$f"{,.orig} perl -e \ 'use strict; use File::Slurp; my $text=read_file(\*STDIN); $text=~s#(\bDEBUG\s*\([^(]+)\((.*?)\)\s*\)\s*;#$1$2);#gs; print $text;' < "$f.orig" > "$f" rm "$f.orig" done Reviewed-by: Jakub Hrozek <jhrozek@redhat.com> Reviewed-by: Stephen Gallagher <sgallagh@redhat.com> Reviewed-by: Simo Sorce <simo@redhat.com>
* Use lower-case name for case-insensitive searchesSumit Bose2013-12-191-8/+22
| | | | | | | | | | | | The patch makes sure that a completely lower-cased version of a fully qualified name is used for case insensitive searches. Currently there are code paths where the domain name was used as configured and was not lower-cased. To make sure this patch does not break with old entries in the cache or case sensitive domains a third template was added to the related filters templates which is either filled with a completely lower-cased version or with the old version. The other two template values are unchanged.
* SYSDB: Skip malformed netgroup attribute.Lukas Slebodnik2013-11-151-1/+5
| | | | | | | | | | It was not easy find out why netgroup could not be covert into result entries. Problem was that nisNetgroupTriple contained unexpected string "(,user01)" This patch will ignore only malformed attribute and processing of netgroup will not fail. Resolves: https://fedorahosted.org/sssd/ticket/2137
* Fix formating of variables with type: size_tLukas Slebodnik2013-09-111-1/+1
|
* New utility function sss_get_domain_nameJakub Hrozek2013-06-071-14/+4
| | | | | Instead of copying a block of code that checks whether domain is a subdomain and uses only name of FQDN as appropriate, wrap the logic into a function.
* Add utility functions for formatting fully-qualified namesJakub Hrozek2013-05-301-4/+2
| | | | | | Instead of using printf-like functions directly, provide two wrappers that would encapsulate formatting the fully-qualified names. No functional change is present in this patch.
* Fix initialization of multiple variablesOndrej Kos2013-03-131-1/+1
|
* Introduce IS_SUBDOMAIN() macroSimo Sorce2013-02-101-2/+2
| | | | Fixes https://fedorahosted.org/sssd/ticket/1766
* Move mpg flag to the domain where it belongsSimo Sorce2013-01-151-3/+3
| | | | | A sysdb contains now multiple domains, but the mpg property is a property of a specific domain not of the underlying database.
* Add domain argument to sysdb_get_user_attr()Simo Sorce2013-01-151-1/+2
|
* Add domain argument to sysdb_initgroups()Simo Sorce2013-01-151-1/+2
|
* Add domain option to sysdb_get/netgr/attrs() fnsSimo Sorce2013-01-151-3/+5
|
* Pass domain to sysdb_enum<pw/gr>ebt() functionsSimo Sorce2013-01-151-3/+5
|
* Pass domain to sysdb_get<pwu/grg><id() functionsSimo Sorce2013-01-151-3/+5
|
* Pass domain to sysdb_get<pw/gr>nam() functionsSimo Sorce2013-01-151-8/+38
| | | | | | Also allows us to remove sysdb_subdom_get<pw/gr>nam() wrappers and restore fqnames proper value in subdomains, by testing for a parent domain being present or not.
* Refactor the way subdomain accounts are savedSimo Sorce2012-11-191-1/+3
| | | | | | | | | | | | | | | | | The original sysdb code had a strong assumption that only users from one domain are saved in the databse, with the subdomain feature, we have changed reality, but have not adjusted all the code arund the sysdb calls to not rely on the original assumption. One of the side effects of this incongrunece is that currently group memberships do not return fully qualified names for subdomain users as they should. In oreder to fix this and other potential issues surrounding the violation of the original assumption, we need to fully qualify subdomain user names. By savin them fully qualified we do not risk aliasing local users and have group memberhips or other name based matching code mistake a domain user with subdomain usr or vice versa.
* Search netgroups by alias, tooJakub Hrozek2012-03-061-1/+3
| | | | https://fedorahosted.org/sssd/ticket/1228
* Fix FTBFS related to -Werror=format-securityKrzysztof Klimonda2011-11-211-1/+1
|
* Sanitize DN in sysdb_get_direct_parentsJakub Hrozek2011-10-171-1/+7
|
* Fix typo in sysdb_get_direct_parentsJakub Hrozek2011-10-061-1/+1
|
* Return users and groups based on aliasJakub Hrozek2011-09-281-3/+4
| | | | https://fedorahosted.org/sssd/ticket/926
* Add a sysdb_get_direct_parents functionJakub Hrozek2011-09-281-0/+101
|
* Remaining memory context variables renamedJan Zeleny2011-08-151-62/+62
| | | | | memctx to mem_ctx tmpctx to tmp_ctx
* sysdb refactoring: memory context deletedJan Zeleny2011-08-151-9/+9
| | | | | | This patch deletes memory context parameter in those places in sysdb where it is not necessary. The code using modified functions has been updated. Tests updated as well.
* sysdb refactoring: deleted domain variables in sysdb APIJan Zeleny2011-08-151-60/+14
| | | | | The patch also updates code using modified functions. Tests have also been adjusted.
* sysdb refactoring: renamed ctx variable to sysdbJan Zeleny2011-08-151-37/+37
|
* Sanitize search filters for the sysdbStephen Gallagher2010-11-151-6/+39
|
* Also return member groups to the clientSumit Bose2010-10-131-55/+71
|
* Netgroups sysdb APIStephen Gallagher2010-10-131-0/+336
|
* Initgroups on a non-cached user should go to the data providerStephen Gallagher2010-09-221-1/+11
| | | | | | | We were accidentally returning an error when sysdb_getpwnam() returned zero results internally in sysdb_initgroups(). The correct behavior here is to return EOK and a result object with zero entries.
* sysdb: remove obsolete helpers from sysdbSimo Sorce2010-04-121-150/+0
|
* sysdb: convert sysdb_initgroupsSimo Sorce2010-04-121-95/+48
|
* sysdb: convert sysdb_enumgrentSimo Sorce2010-04-121-55/+33
|
* sysdb: convert sysdb_enumpwentSimo Sorce2010-04-121-53/+22
|
* sysdb: convert sysdb_get_user_attrSimo Sorce2010-04-121-17/+22
|
* sysdb: convert sysdb_getgrgidSimo Sorce2010-04-121-21/+33
|
* sysdb: convert sysdb_getgrnamSimo Sorce2010-04-121-17/+46
|
* sysdb: convert sysdb_getpwuidSimo Sorce2010-04-121-18/+22
|
* sysdb: convert sysdb_getpwnamSimo Sorce2010-04-121-17/+21
|
* Rename server/ directory to src/Stephen Gallagher2010-02-181-0/+691
Also update BUILD.txt