3996e391054a1c02ab62e1541ae21a8204bd5d0a |
|
03-Aug-2017 |
AmitKumar <amitkuma@redhat.com> |
Moving headers used by both server and client to special folder
These are the header files which are used by both client and server:
src/util/io.h
src/util/murmurhash3.h
src/util/util_safealign.h
This patch is about moving these header files to special folder
(src/shared). It will be easier to identify these headers when looking
for them in the src tree.
util_safalign.h is renamed as safalign.h because util_ namespace is
appropriate when this file belonged to the util's folder which is no
longer the case.
Resolves:
https://pagure.io/SSSD/sssd/issue/1898
Reviewed-by: Fabiano Fidêncio <fidencio@redhat.com> |
dda0258705de7255e6ec54b7f9adbde83a220996 |
|
05-Aug-2015 |
Lukas Slebodnik <lslebodn@redhat.com> |
NSS: Initgr memory cache should work with fq names
We need to stored two versions of name to the initgroups memory cache.
Otherwise it could be stored many times if sssd is configured with
case_sensitive = false. It would be impossible to invalidate all
version of names after user login. As a result of this wrong user
groups could be returned from initgroups memory cache.
Therefore we store raw name provided by glibc function
and internal sanitized fully qualified name,
which is unique for particular user.
This patch also increase average space for initgroups
because there are also stored two quite long names in case of
fq names.
Resolves:
https://fedorahosted.org/sssd/ticket/2712
Reviewed-by: Michal Židek <mzidek@redhat.com> |
225dc6914cdc8920b02a129b98ece1ed97b99c03 |
|
05-Aug-2015 |
Lukas Slebodnik <lslebodn@redhat.com> |
mmap_cache: "Override" functions for initgr mmap cache
Functions sss_mc_get_strs_offset and sss_mc_get_strs_len provides
data about strings for individual memory caches (passwd, ...)
Their are used in generic responder mmap cache code to find a record
in mmap cache (sss_mc_find_record). Data provided from functions sss_mc_get_*
are used for checking the validity of record. So in case of corrupted record
the whole mmap cache can be invalidated.
Functions sss_mc_get_strs_offset and sss_mc_get_strs_len did not provide
data for initgroups mmap cache and therefore particular record could not be
invalidated.
Resolves:
https://fedorahosted.org/sssd/ticket/2716
Reviewed-by: Michal Židek <mzidek@redhat.com> |
39b31427e2d11ca318df11fd48db33a7cc610aa7 |
|
05-Aug-2015 |
Lukas Slebodnik <lslebodn@redhat.com> |
mmap_cache: Rename variables
Reviewed-by: Michal Židek <mzidek@redhat.com> |
ebf6735dd4f71bf3dc9105e5d04d11e744c64a59 |
|
03-Jul-2015 |
Lukas Slebodnik <lslebodn@redhat.com> |
nss: Store entries in responder to initgr mmap cache
Resolves:
https://fedorahosted.org/sssd/ticket/2485
Reviewed-by: Michal Židek <mzidek@redhat.com> |
581de96fc30b7fe44070f17a8a73f3374d38d6ff |
|
23-Sep-2013 |
Lukas Slebodnik <lslebodn@redhat.com> |
mmap_cache: Use two chains for hash collision.
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 |
441e6050f4b67134d15862e401b4c4e8546d7387 |
|
19-Aug-2013 |
Michal Zidek <mzidek@redhat.com> |
mmap_cache: Use better checks for corrupted mc in responder
We introduced new way to check integrity of memcache in the
client code. We should use similiar checks in the responder. |
13df7b9e400211c717284fb841c849ba034ed348 |
|
19-Aug-2013 |
Michal Zidek <mzidek@redhat.com> |
mmap_cache: Off by one error.
Removes off by one error when using macro MC_SIZE_TO_SLOTS
and adds new macro MC_SLOT_WITHIN_BOUNDS. |
9028706a00da1bc48547e74aa872c825ac15adb2 |
|
11-Aug-2013 |
Michal Zidek <mzidek@redhat.com> |
mmap_cache: Check if slot and name_ptr are not invalid.
This patch prevents jumping outside of allocated memory in
case of corrupted slot or name_ptr values. It is not proper
solution, just hotfix until we find out what is the root cause
of ticket https://fedorahosted.org/sssd/ticket/2018 |
4869633dc87dadb2b9a114444d375c39703ac863 |
|
07-Jan-2013 |
Pavel Březina <pbrezina@redhat.com> |
memcache: make MC_PTR_TO_SLOT() more readable |
31c47cacc7f9453153e57319474909d23122883f |
|
07-Jan-2013 |
Pavel Březina <pbrezina@redhat.com> |
memcache: add macro that validates record length |
6acf7c92ab38ad388295b2d57cc97c4598aa95cc |
|
20-Dec-2012 |
Simo Sorce <simo@redhat.com> |
Carefully check records when forcibly invalidating
We should never try to invalidate an already invalid record as
internal pointers will not be consistent. Carefully test that the
record really is valid when we are fishing for free space, and
properly invalidate records or return a fatal error if something
goes wrong.
In order to make the code more robust always invalidate the whole
data space on initialization by setting all bits to 1, and make sure
to invalidate the whole last allocated slot by converting rec->len to
the number of slots instead of just the space used. |
c3ef027218fe9a7d16a70ca9d2f53e3d995e369f |
|
19-Mar-2012 |
Simo Sorce <simo@redhat.com> |
nsssrv: add handling of memory cache group map |
5f90993426fa2bdc3b3d994c9e85e0805bb92bbc |
|
19-Mar-2012 |
Simo Sorce <simo@redhat.com> |
util: Helper headers for shared memory cache |