04d4c4d45f3942a813b7f772737f801f877f4e64 |
|
29-Jul-2016 |
Sumit Bose <sbose@redhat.com> |
utils: add is_email_from_domain()
Reviewed-by: Jakub Hrozek <jhrozek@redhat.com> |
19bb5bfc2821c5644e10614c5730ca5c180c2856 |
|
26-Jul-2016 |
Petr Cech <pcech@redhat.com> |
test_utils: Fixing assignment discards 'const' qualifier
Reviewed-by: Lukáš Slebodník <lslebodn@redhat.com> |
66588a6241df42a04cb9ead75cf3afb38495d74a |
|
25-Jul-2016 |
Sumit Bose <sbose@redhat.com> |
tests: add tests for sss_get_domain_mappings_content()
Reviewed-by: Jakub Hrozek <jhrozek@redhat.com> |
059904af2d20debcb8ffe1c6f45b996c2c57574e |
|
18-Jul-2016 |
Lukas Slebodnik <lslebodn@redhat.com> |
test_utils: Clean files after sss_write_krb5_conf_snippet
The test directory was not removed (tp_test_utils-test_utils)
because it contain the snippet for krb5_libdefaults.
Reviewed-by: Fabiano Fidêncio <fabiano@fidencio.org> |
393306307bd908fcec8858f665226ac56238a21b |
|
07-Jul-2016 |
Jakub Hrozek <jhrozek@redhat.com> |
UTIL: Remove unused functions
The conversion to sysdb made several functions obsolete. Remove them.
Reviewed-by: Sumit Bose <sbose@redhat.com> |
accff8ebe158251b1d25a95b3b035fe7e08fd1ee |
|
07-Jul-2016 |
Jakub Hrozek <jhrozek@redhat.com> |
UTIL: expand_homedir_template manages usernames internally
expand_homedir_template() can be considered an outward-facing interface,
therefore the function and its input structure will accept the internal
name format and parse it internally into a username and domain
component.
Reviewed-by: Sumit Bose <sbose@redhat.com> |
87c6d9ea92d83460457353cfea6c5bde8744994a |
|
07-Jul-2016 |
Jakub Hrozek <jhrozek@redhat.com> |
UTIL: Add a utility function sss_output_name
Adds a convenience function that will help reduce the amount of code
duplication in the responders. All responders need to parse the username
from the internal format, lower-case the name, if the domain is
case-insensitive and then replace spaces if the responder is configured
to do so.
Reviewed-by: Sumit Bose <sbose@redhat.com> |
8858d820445cffb67ef8cf790b3a8d37b008d654 |
|
07-Jul-2016 |
Jakub Hrozek <jhrozek@redhat.com> |
UTIL: Add a utility function to create a list of qualified names
Adds a convenience wrapper around sss_create_fqname that qualifies a
list of names into the format used internally in sssd.
Reviewed-by: Sumit Bose <sbose@redhat.com> |
35b7aaf0f718390b06be8414258e3fc83326a871 |
|
07-Jul-2016 |
Jakub Hrozek <jhrozek@redhat.com> |
TESTS: Add a test for sss_create_internal_fqname
Reviewed-by: Sumit Bose <sbose@redhat.com> |
31851748aa1c6d7f17afcbf1c36c8feed6d651f8 |
|
07-Jul-2016 |
Jakub Hrozek <jhrozek@redhat.com> |
TESTS: Add a test for sss_parse_internal_fqname
Reviewed-by: Sumit Bose <sbose@redhat.com> |
e6b6b9fa79c67d7d2698bc7e33d2e2f6bb53d483 |
|
06-Jul-2016 |
Sumit Bose <sbose@redhat.com> |
IPA/AD: globally set krb5 canonicalization flag
If Kerberos principal canonicalization is configured in SSSD, currently
it is the default for the IPA provider, a configuration snippet is
generated for the system-wide libkrb5 configuration so that all
kerberized applications will use canonicalization by default.
Resolves https://fedorahosted.org/sssd/ticket/3041
Reviewed-by: Jakub Hrozek <jhrozek@redhat.com> |
53ef8f81b60929a6c866efdd133627e7d7d61705 |
|
09-Jun-2016 |
Sumit Bose <sbose@redhat.com> |
p11: add OCSP default responder options
Reviewed-by: Jakub Hrozek <jhrozek@redhat.com> |
28f336bdb32db0b89cb98174a3f8e308e4e928db |
|
13-Apr-2016 |
Sumit Bose <sbose@redhat.com> |
util: make concatenate_string_array() reusable
Reviewed-by: Pavel Březina <pbrezina@redhat.com> |
2a5cf841dec2785333117a293fcd8c875ace28b9 |
|
12-Apr-2016 |
Petr Cech <pcech@redhat.com> |
TESTS: global_talloc_context push/pop remove
Push/pop global_talloc_context into check_leaks is redudant. It is done
in leak_check_setup() and leak_check_teardown() functions in
src/tests/check_leaks.
Reviewed-by: Lukáš Slebodník <lslebodn@redhat.com> |
c84dcaa58449c53cf038311ce63bb2c304081b9d |
|
23-Oct-2015 |
Michal Židek <mzidek@redhat.com> |
tests: Add get_next_domain_flags test
Ticket:
https://fedorahosted.org/sssd/ticket/2673
Reviewed-by: Jakub Hrozek <jhrozek@redhat.com> |
877b92e80bde510d5cd9f03dbf01e2bcf73ab072 |
|
23-Oct-2015 |
Michal Židek <mzidek@redhat.com> |
util: Update get_next_domain's interface
Update get next domain to be able to
include disbled domains and change the
interface to accept flags instead of
multiple booleans.
Ticket:
https://fedorahosted.org/sssd/ticket/2673
Reviewed-by: Jakub Hrozek <jhrozek@redhat.com> |
cffe3defa3cb5011efc92a7773fe113a1e69774f |
|
22-Sep-2015 |
Jakub Hrozek <jhrozek@redhat.com> |
tests: Move named_domain from test_utils to common test code
This handy function should be reused by other parts of the code.
Reviewed-by: Lukáš Slebodník <lslebodn@redhat.com> |
b5825c74b6bf7a99ae2172392dbecb51179013a6 |
|
21-Sep-2015 |
Jakub Hrozek <jhrozek@redhat.com> |
UTIL: Convert domain->disabled into tri-state with domain states
Required for:
https://fedorahosted.org/sssd/ticket/2637
This is a first step towards making it possible for domain to be around,
but not contacted by Data Provider.
Also explicitly create domains as active, previously we only relied on
talloc_zero marking dom->disabled as false.
Reviewed-by: Pavel Březina <pbrezina@redhat.com> |
50c9d542e8bf641412debaa82a4dcf67ddb72258 |
|
18-Sep-2015 |
Lukas Slebodnik <lslebodn@redhat.com> |
tests: Use unique name for TEST_PATH
We had a cases in patch where two tests were using the same TEST_PATH
and therefore they were stepping each other to the same files
which caused failures. These failures are not easy to reproduce.
This patch uses macro BASE_FILE_STEM for unique name. It should prevent
copy&paste problem resulting to intermittent failures.
@see also
https://www.gnu.org/software/make/manual/html_node/Automatic-Variables.html
Reviewed-by: Jakub Hrozek <jhrozek@redhat.com> |
d95bcfe23c574de7b6b7b44b52a0d4db5cc8529a |
|
14-Aug-2015 |
Jakub Hrozek <jhrozek@redhat.com> |
UTIL: Provide a common interface to safely create temporary files
Reviewed-by: Pavel Březina <pbrezina@redhat.com> |
a99845006f96f9d1e7af871ec67c71cee8408a62 |
|
19-Jun-2015 |
Sumit Bose <sbose@redhat.com> |
utils: add get_last_x_chars()
Reviewed-by: Pavel Březina <pbrezina@redhat.com> |
4f97aaa2fd81e90c2d1f74d8b6619083db4061a5 |
|
02-Jun-2015 |
Jakub Hrozek <jhrozek@redhat.com> |
TESTS: Add test for get_next_domain
Reviewed-by: Lukáš Slebodník <lslebodn@redhat.com> |
3fe2e555edd3963d72483600e5d9616873afd00a |
|
06-May-2015 |
Sumit Bose <sbose@redhat.com> |
IPA: do not add domain name unconditionally
Depending on the server-side configuration the extdom plugin can return
short or fully qualified names for IPA objects. The client must handle
the names according to its own configuration and not add the domain part
of the fully-qualified name unconditionally.
Resolves https://fedorahosted.org/sssd/ticket/2647
Reviewed-by: Jakub Hrozek <jhrozek@redhat.com> |
1d93029624d708119bbf803e6647a2cbb271f001 |
|
20-Mar-2015 |
Sumit Bose <sbose@redhat.com> |
sdap: properly handle binary objectGuid attribute
Although in the initial processing SSSD treats the binary value right at
some point it mainly assumes that it is a string. Depending on the value
this might end up with the correct binary value stored in the cache but
in most cases there will be only a broken entry in the cache.
This patch converts the binary value into a string representation which
is described in [MS-DTYP] and stores the result in the cache.
Resolves https://fedorahosted.org/sssd/ticket/2588
Reviewed-by: Jakub Hrozek <jhrozek@redhat.com> |
4e5e846de22407f825fe3b4040d79606818a2419 |
|
11-Mar-2015 |
Jakub Hrozek <jhrozek@redhat.com> |
tests: convert all unit tests to cmocka 1.0 or later
All tests now use the cmocka-1.0-compatible API.
Reviewed-by: Lukáš Slebodník <lslebodn@redhat.com> |
dd5ebcde05442422f39084acb49b28cf47002d1e |
|
23-Jan-2015 |
Sumit Bose <sbose@redhat.com> |
IPA: properly handle mixed-case trusted domains
In the SSSD cache domain names are handled case-sensitive. As a result
fully-qualified names in RDN contain the domain part in the original
spelling. When IPA client lookup up group-memberships on the IPA server
via the extdom plugin the names returned are all lower case. To make
sure new DNs are generated correctly the domain part must adjusted.
Related to https://fedorahosted.org/sssd/ticket/2159
Reviewed-by: Jakub Hrozek <jhrozek@redhat.com> |
cb4742876508a08ba90c82466c9dba708e4bf999 |
|
09-Jan-2015 |
Pavel Březina <pbrezina@redhat.com> |
tests: remove code duplication in single domain cleanup
Reviewed-by: Michal Židek <mzidek@redhat.com> |
4fa184e2c60b377fd71e0115a618bd68dc73627d |
|
25-Nov-2014 |
Sumit Bose <sbose@redhat.com> |
AD/IPA: add krb5_confd_path configuration option
With this new parameter the directory where Kerberos configuration
snippets are created can be specified.
Fixes https://fedorahosted.org/sssd/ticket/2473
Reviewed-by: Jakub Hrozek <jhrozek@redhat.com> |
9ce7a46f6578a86b72f20acd7b0e55b1b4ebea09 |
|
05-Nov-2014 |
Sumit Bose <sbose@redhat.com> |
Add add_strings_lists() utility function
Reviewed-by: Jakub Hrozek <jhrozek@redhat.com> |
022c6b90bb37851c0e8704c0e5388ebc113c6470 |
|
28-Jul-2014 |
Lukas Slebodnik <lslebodn@redhat.com> |
UTIL: Add functions for replacing whitespaces.
Reviewed-by: Pavel Reichl <preichl@redhat.com>
Reviewed-by: Michal Židek <mzidek@redhat.com> |
462db32918a05097652f8232cd6c8d78a826e63c |
|
28-Jul-2014 |
Lukas Slebodnik <lslebodn@redhat.com> |
test_utils: Use common header file for libsss_util tests.
Reviewed-by: Pavel Reichl <preichl@redhat.com>
Reviewed-by: Michal Židek <mzidek@redhat.com> |
db18dda869bc6c52a41797b2066cf121cf10f49c |
|
22-Jul-2014 |
Pavel Reichl <preichl@redhat.com> |
UTIL: rename find_subdomain_by_name
The function was named "find_subdomain" yet it could find both main
domain and subdomain.
sed 's/find_subdomain_by_name/find_domain_by_name/' -i `find . -name "*.[ch]"`
Reviewed-by: Jakub Hrozek <jhrozek@redhat.com> |
9ca0071db0e226e4e65b2a80fdeddd5048ca8990 |
|
22-Jul-2014 |
Pavel Reichl <preichl@redhat.com> |
UTIL: rename find_subdomain_by_sid
The function was named "find_subdomain" yet it could find both main
domain and subdomain.
sed 's/find_subdomain_by_sid/find_domain_by_sid/' -i `find . -name "*.[ch]"`
Reviewed-by: Jakub Hrozek <jhrozek@redhat.com> |
6b57784f0f175275fd900eca21c77415e3a5ea52 |
|
09-Jul-2014 |
Jakub Hrozek <jhrozek@redhat.com> |
TOOLS: Always debug to stderr
https://fedorahosted.org/sssd/ticket/2348
Programs that are supposed to only be executed on the foreground should
log to stderr automatically.
Reviewed-by: Michal Židek <mzidek@redhat.com> |
b5f61c9b3f5ea79bf319c18ff59394070c04d607 |
|
18-Jun-2014 |
Pavel Reichl <preichl@redhat.com> |
TESTS: sss_ssh - textual public key format
Reviewed-by: Lukáš Slebodník <lslebodn@redhat.com> |
59af140ef81f6d0f10db9549089998f5e05631cb |
|
02-Jun-2014 |
Lukas Slebodnik <lslebodn@redhat.com> |
TEST: Add test for expand homedir |
a3c8390d19593b1e5277d95bfb4ab206d4785150 |
|
12-Feb-2014 |
Nikolai Kondrashov <Nikolai.Kondrashov@redhat.com> |
Make DEBUG macro invocations variadic
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:
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> |
c86904baad32fbf9e66bf1cdc667aa5e683b48ba |
|
12-Jan-2014 |
Stef Walter <stefw@redhat.com> |
NSS: Don't use printf(3) on user provided strings.
This also fixes several corner cases and crashers.
It's not prudent to pass user input to (even admin) input as a
format string to printf, and various distros now check for this.
This can cause accessing memory incorrectly, and various also
various libc abort()'s.
In addition various assumptions were made about full_name_format
that aren't necessarily the case if the user uses a more complex
format.
Use safe-printf.c implementation for formatting full_name_format.
Adapt the NSS resolver so it doesn't barf on formatted strings that
are shorter than expected given a full_name_format.
Tests added and updated appropriately. |
15a1519ec9c23f598716ffa89e533cd9bfb2a4f3 |
|
19-Dec-2013 |
Sumit Bose <sbose@redhat.com> |
Use lower-case name for case-insensitive searches
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. |
3e64f9f6c551dc25327d4ff552757304da3066eb |
|
18-Nov-2013 |
Lukas Slebodnik <lslebodn@redhat.com> |
TESTS: Remove test dir after successful tests
test_utils removed files from test_dir before test execution, but
files wasn't clean up after successful test execution. |
de38d860e39585486e3ccbb42555196e319c7efd |
|
15-Nov-2013 |
Sumit Bose <sbose@redhat.com> |
Add utility to handle Well-Known SIDs |
45ba1e10beddf082c061e0a2950340596817861a |
|
15-Nov-2013 |
Sumit Bose <sbose@redhat.com> |
sss_names_init: allow empty domain name
If no domain name is specified the global name pattern and regular
expression will be returned. |
ec7732b91c7ca5367e2ae62a237d975ed1b9763f |
|
04-Nov-2013 |
Sumit Bose <sbose@redhat.com> |
Enhance/add unit tests for find_subdomain_by_sid/name |
f64296c40e07614668c4ac4c978bc8980fb6a7db |
|
25-Oct-2013 |
Lukas Slebodnik <lslebodn@redhat.com> |
tests: Use right format string for type size_t
This patch fixes few format string warnings in the file test_utils.c
src/tests/cmocka/test_utils.c:54:56:
warning: format specifies type 'unsigned int' but the
argument has type 'size_t' (aka 'unsigned long') [-Wformat] |
939246537b0b9a4af6862c513d3919501ad57d92 |
|
25-Oct-2013 |
Sumit Bose <sbose@redhat.com> |
find_subdomain_by_sid: skip domains with missing domain_id |