summaryrefslogtreecommitdiffstats
path: root/src/util
Commit message (Collapse)AuthorAgeFilesLines
...
* LDAP: Add a new error code for malformed access control filterJakub Hrozek2014-01-092-0/+2
| | | | | | | https://fedorahosted.org/sssd/ticket/2164 The patch adds a new error code and special cases the new code so that access is denied and a nicer log message is shown.
* Use lower-case name for case-insensitive searchesSumit Bose2013-12-192-0/+36
| | | | | | | | | | | | 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.
* Properly align buffer when storing pointers.Michal Zidek2013-12-101-0/+10
| | | | | | | | Properly align buffer address to sizeof(char *) when storing pointers to strings. resolves: https://fedorahosted.org/sssd/ticket/1359
* Fix a trivial typoJakub Hrozek2013-12-091-1/+1
|
* added null checks to authtok modulePallavi Jha2013-12-091-1/+19
|
* SSSD: Improved domain detectionPavel Reichl2013-11-292-5/+29
| | | | | | | A bit more elegant way of detection of what domain the group member belongs to Resolves: https://fedorahosted.org/sssd/ticket/2132
* Remove unused parameter from sss_selinux_extract_userLukas Slebodnik2013-11-272-2/+0
|
* monitor: Specific error message for missing sssd.confPavel Reichl2013-11-272-0/+2
| | | | | | | | Specific error message is logged for missing sssd.conf file. New sssd specific error value is introduced for this case. Resolves: https://fedorahosted.org/sssd/ticket/2156
* Add utility to handle Well-Known SIDsSumit Bose2013-11-152-0/+318
|
* Add sss_tc_fqname2()Sumit Bose2013-11-152-0/+22
| | | | | sss_tc_fqname2() is similar to sss_tc_fqname() but expects domain and flat domain name as string arguments instead of a domain struct.
* sss_names_init: allow empty domain nameSumit Bose2013-11-151-15/+19
| | | | | If no domain name is specified the global name pattern and regular expression will be returned.
* SYSDB: Drop the sysdb_ctx parameter - module sysdb_ops (part 1)Michal Zidek2013-11-151-2/+2
|
* Signals: Refactor termination of processesSimo Sorce2013-11-122-27/+11
| | | | | | | | sig_term() was never used as a real signal handler, but only called by tevent signal handlers in the kerberos and ldap children. Also the same code was duplicated with separate local guard variables in other functions. Unify orderly termination handling, between all these functions.
* Signals: Remove empty sig_hupSimo Sorce2013-11-121-8/+0
| | | | | SIGHUP handling is implemented later using a tevent handler so sig_hup() is useless.
* Signals: Remove unused functionsSimo Sorce2013-11-122-59/+0
| | | | Cleanup unused signal functions
* UTIL: Free log message when using journaldJakub Hrozek2013-11-071-0/+2
|
* Enhance/add unit tests for find_subdomain_by_sid/nameSumit Bose2013-11-041-0/+4
|
* Include ext headers with #include <foo.h> - contPavel Reichl2013-11-043-3/+3
| | | | Changing style of including header files from outside of sssd tree - from "header.h" to <header.h>
* utils: add ERR_DOMAIN_NOT_FOUND error codePavel Březina2013-10-252-0/+2
| | | | | Resolves: https://fedorahosted.org/sssd/ticket/1968
* find_subdomain_by_sid: skip domains with missing domain_idSumit Bose2013-10-251-11/+19
|
* Inherit ID limits of parent domains if setJakub Hrozek2013-10-241-3/+5
| | | | | | | | | https://fedorahosted.org/sssd/ticket/2123 Previously, the subdomains were always unbound even if the administrator limited the ranges with min_id/max_id. This could have posed problems when running programs that scan the whole ID space, such as "groupadd -r".
* UTIL: Move sss_parse_name_for_domains declaration to util.hJakub Hrozek2013-10-221-0/+5
|
* Include external headers with #include <foo.h>Jakub Hrozek2013-10-222-3/+4
| | | | | | I find it more readable to include headers from outside the sssd tree with <foo.h>, not "foo.h". The latter should be used for in-tree headers only.
* util: Add functions to check if IP addresses is specialMichal Zidek2013-10-172-0/+70
| | | | | Added functions to check if given IP address is a special address (broadcast, multicast...).
* INI: Disable line-wrapping functionalityJakub Hrozek2013-10-111-1/+1
| | | | | | | Supporting the latest INI release brought an incompatible change. Lines beginning with a whitespace were treated as continuation of the previous line. This patch reverts to ignoring the whitespace as we did previously so that the existing configurations keep working.
* ipa_server_mode: write capaths to krb5 include fileSumit Bose2013-09-272-2/+52
| | | | | | | | | | | | If there are member domains in a trusted forest which are DNS-wise not proper children of the forest root the IPA KDC needs some help to determine the right authentication path. In general this should be done internally by the IPA KDC but this works requires more effort than letting sssd write the needed data to the include file for krb5.conf. If this functionality is available for the IPA KDC this patch might be removed from the sssd tree. Fixes https://fedorahosted.org/sssd/ticket/2093
* IPA: store forest name for forest member domainsSumit Bose2013-09-272-2/+12
| | | | | In order to fix https://fedorahosted.org/sssd/ticket/2093 the name of the forest must be known for a member domain of the forest.
* util: add get_domains_head()Pavel Březina2013-09-262-0/+15
| | | | | | | This function will return head of the domain list. Resolves: https://fedorahosted.org/sssd/ticket/2066
* util: Allways fall back to old find_uid methodSimo Sorce2013-09-251-4/+4
| | | | | | | | systemd-login still fails with su/sudo login shells, so always fall back for now. Resolves: https://fedorahosted.org/sssd/ticket/2094
* Include header file in implementation module.Lukas Slebodnik2013-09-247-0/+7
| | | | | Declarations of public functions was in header files, but header files was not included in implementation file.
* mmap_cache: Use two chains for hash collision.Lukas Slebodnik2013-09-231-8/+12
| | | | | | | | | | | | | | | | | | | | | | | struct sss_mc_rec had two hash members (hash1 and hash2) but only one next member. This was a big problem in case of higher probability of hash collision. structure sss_mc_rec will have two next members (next1, next2) with this patch. next1 is related to hash1 and next2 is related to hash1. Iterating over chains is changed, because we need to choose right next pointer. Right next pointer will be chosen after comparing record hashes. This behaviour is wrapped in function sss_mc_next_slot_with_hash. Adding new record to chain is also changed. The situation is very similar to iterating. We need to choose right next pointer (next1 or next2). Right next pointer will be chosen after comparing record hashes. Adding reference to next slot is wrapped in function sss_mc_chain_slot_to_record_with_hash Size of structure sss_mc_rec was increased from 32 bytes to 40 bytes. Resolves: https://fedorahosted.org/sssd/ticket/2049
* Check return values of setenv and unsetenvJakub Hrozek2013-09-221-1/+5
|
* BE: Log domain name to journald if availableJakub Hrozek2013-09-183-0/+14
| | | | | | | | If the SSSD is compiled with journald support, then all sss_log() statements will include a new field called "SSSD_DOMAIN" that includes the domain name. Filtering only messages from the single domain is then as easy as: # journalctl SSSD_DOMAIN=foo.example.com
* Add journald supportJakub Hrozek2013-09-181-0/+35
|
* util: add find_subdomain_by_object_name()Pavel Březina2013-09-172-0/+39
| | | | | | | | This function will parse object name into name and domain name part and return appropriate sss domain. Resolves: https://fedorahosted.org/sssd/ticket/2034
* util: add find_subdomain_by_sid()Pavel Březina2013-09-172-0/+35
| | | | | | | | | | | | | | This function takes domain SID (doesn't have the last component) or object SID (have all components) and returns subdomain. The subdomain is found by comparing domain->domainid with the SID. E.g. domain SID: S-1-5-21-3940105347-3434501867-2690409756 object SID: S-1-5-21-3940105347-3434501867-2690409756-513 Resolves: https://fedorahosted.org/sssd/ticket/2034
* util: add sss_idmap_talloc[_free]Pavel Březina2013-09-172-0/+60
| | | | Remove code duplication.
* util: Use systemd-login to check user sessionsSimo Sorce2013-09-161-0/+20
| | | | | | | | | | | | | Use systemd-lgin in preference to check if the user is logged in or not. Fall back to the old method if no systemd-login support is available at compile time or if it returns a fatal error, and can't determine the status of the user on its own. This will allow to consider a user really active (in order to reuse or refresh crdentials) only if it really is logged into the system, and not just if one of the user's processes is stuck around. Resolves: https://fedorahosted.org/sssd/ticket/2084
* Enable printf format string checkingLukas Slebodnik2013-09-111-2/+8
| | | | https://fedorahosted.org/sssd/ticket/1945
* Fix formating of variables with type: id_tLukas Slebodnik2013-09-111-1/+25
|
* Fix formating of variables with type: rlim_tLukas Slebodnik2013-09-111-0/+7
|
* Fix formating of variables with type: key_serial_tLukas Slebodnik2013-09-111-0/+3
|
* Adding new header for printf formating macrosLukas Slebodnik2013-09-112-0/+33
|
* Fix formating of variables with type: size_tLukas Slebodnik2013-09-111-1/+1
|
* Fix formating of variables with type: ssize_tLukas Slebodnik2013-09-113-4/+5
|
* Fix formating of variables with type: intLukas Slebodnik2013-09-111-2/+3
|
* Fix formating of variables with type: longLukas Slebodnik2013-09-111-2/+2
|
* krb5: Remove unused helper functionsHEADmasterSimo Sorce2013-09-092-88/+0
| | | | | | | these functions are not needed anymore. Related: https://fedorahosted.org/sssd/ticket/2061
* krb5: Remove unused functionSimo Sorce2013-09-092-32/+0
| | | | | Related: https://fedorahosted.org/sssd/ticket/2061
* krb5: Make check_for_valid_tgt() staticSimo Sorce2013-09-092-76/+0
| | | | | | | check_for_valid_tgt() is used exclusively in krb5_uitls.c so move it there. Resolves: https://fedorahosted.org/sssd/ticket/2061