<feed xmlns='http://www.w3.org/2005/Atom'>
<title>sssd.git/src/responder/common/negcache.c, branch prompting</title>
<subtitle>Unnamed repository; edit this file to name it for gitweb.</subtitle>
<link rel='alternate' type='text/html' href='https://fedorapeople.org/cgit/sbose/public_git/sssd.git/'/>
<entry>
<title>NEGCACHE: Adding getter for timeout</title>
<updated>2016-05-11T10:50:11+00:00</updated>
<author>
<name>Petr Cech</name>
<email>pcech@redhat.com</email>
</author>
<published>2016-04-22T11:10:15+00:00</published>
<link rel='alternate' type='text/html' href='https://fedorapeople.org/cgit/sbose/public_git/sssd.git/commit/?id=f77ba726e3f8bd1e3cabdee66f38c4ed7a771913'/>
<id>f77ba726e3f8bd1e3cabdee66f38c4ed7a771913</id>
<content type='text'>
It adds new function to negative cache API:
* int sss_ncache_get_timeout(struct sss_nc_ctx *ctx);

Resolves:
https://fedorahosted.org/sssd/ticket/2317

Reviewed-by: Pavel Březina &lt;pbrezina@redhat.com&gt;
</content>
<content type='xhtml'>
<div xmlns='http://www.w3.org/1999/xhtml'>
<pre>
It adds new function to negative cache API:
* int sss_ncache_get_timeout(struct sss_nc_ctx *ctx);

Resolves:
https://fedorahosted.org/sssd/ticket/2317

Reviewed-by: Pavel Březina &lt;pbrezina@redhat.com&gt;
</pre>
</div>
</content>
</entry>
<entry>
<title>NEGCACHE: Removing timeout from sss_ncache_check_*</title>
<updated>2016-05-11T10:49:51+00:00</updated>
<author>
<name>Petr Cech</name>
<email>pcech@redhat.com</email>
</author>
<published>2016-04-22T10:39:11+00:00</published>
<link rel='alternate' type='text/html' href='https://fedorapeople.org/cgit/sbose/public_git/sssd.git/commit/?id=0393f0d44ac92035de29a8bc8b2005db6d90b640'/>
<id>0393f0d44ac92035de29a8bc8b2005db6d90b640</id>
<content type='text'>
It removes timeout parameter from check functions of negative cache.
Timeout is set ny init function and it is handled internally.

API change:
 * int sss_ncache_check_...(struct sss_nc_ctx *ctx,
                            int ttl,      &lt;----- timeout vanished
                            struct sss_domain_info *dom,
                            ...);

Resolves:
https://fedorahosted.org/sssd/ticket/2317

Reviewed-by: Pavel Březina &lt;pbrezina@redhat.com&gt;
</content>
<content type='xhtml'>
<div xmlns='http://www.w3.org/1999/xhtml'>
<pre>
It removes timeout parameter from check functions of negative cache.
Timeout is set ny init function and it is handled internally.

API change:
 * int sss_ncache_check_...(struct sss_nc_ctx *ctx,
                            int ttl,      &lt;----- timeout vanished
                            struct sss_domain_info *dom,
                            ...);

Resolves:
https://fedorahosted.org/sssd/ticket/2317

Reviewed-by: Pavel Březina &lt;pbrezina@redhat.com&gt;
</pre>
</div>
</content>
</entry>
<entry>
<title>NEGCACHE: Adding timeout to struct sss_nc_ctx</title>
<updated>2016-05-11T10:49:45+00:00</updated>
<author>
<name>Petr Cech</name>
<email>pcech@redhat.com</email>
</author>
<published>2016-04-22T08:27:47+00:00</published>
<link rel='alternate' type='text/html' href='https://fedorapeople.org/cgit/sbose/public_git/sssd.git/commit/?id=39d36216a1692eee6cc5359f6c7ccaa7789be76d'/>
<id>39d36216a1692eee6cc5359f6c7ccaa7789be76d</id>
<content type='text'>
It adds timeout of negative cache to handling
struct sss_nc_ctx.

There is one change in API of negatice cache:
 * int sss_ncache_init(TALLOC_CTX *memctx,
                       uint32_t timeout,  &lt;----- new
                       struct sss_nc_ctx **_ctx);

There is also one new function in common/responder:
*  errno_t responder_get_neg_timeout_from_confdb(struct confdb_ctx *cdb,
                                                 uint32_t *ncache_timeout);

Resolves:
https://fedorahosted.org/sssd/ticket/2317

Reviewed-by: Pavel Březina &lt;pbrezina@redhat.com&gt;
</content>
<content type='xhtml'>
<div xmlns='http://www.w3.org/1999/xhtml'>
<pre>
It adds timeout of negative cache to handling
struct sss_nc_ctx.

There is one change in API of negatice cache:
 * int sss_ncache_init(TALLOC_CTX *memctx,
                       uint32_t timeout,  &lt;----- new
                       struct sss_nc_ctx **_ctx);

There is also one new function in common/responder:
*  errno_t responder_get_neg_timeout_from_confdb(struct confdb_ctx *cdb,
                                                 uint32_t *ncache_timeout);

Resolves:
https://fedorahosted.org/sssd/ticket/2317

Reviewed-by: Pavel Březina &lt;pbrezina@redhat.com&gt;
</pre>
</div>
</content>
</entry>
<entry>
<title>NEGCACHE: Removing of condition for ttl = -1</title>
<updated>2016-04-20T18:07:21+00:00</updated>
<author>
<name>Petr Cech</name>
<email>pcech@redhat.com</email>
</author>
<published>2016-04-19T11:35:26+00:00</published>
<link rel='alternate' type='text/html' href='https://fedorapeople.org/cgit/sbose/public_git/sssd.git/commit/?id=85a9d31cb955fa2d6c6ec45b4bf04b00118829fb'/>
<id>85a9d31cb955fa2d6c6ec45b4bf04b00118829fb</id>
<content type='text'>
If ttl = -1 then function sss_ncache_check_str() returns EEXIST without
checking negcache. This behaviour is out of logic.

We use ttl = 0 for permanent caching.

Reviewed-by: Lukáš Slebodník &lt;lslebodn@redhat.com&gt;
</content>
<content type='xhtml'>
<div xmlns='http://www.w3.org/1999/xhtml'>
<pre>
If ttl = -1 then function sss_ncache_check_str() returns EEXIST without
checking negcache. This behaviour is out of logic.

We use ttl = 0 for permanent caching.

Reviewed-by: Lukáš Slebodník &lt;lslebodn@redhat.com&gt;
</pre>
</div>
</content>
</entry>
<entry>
<title>Fix typos reported by lintian</title>
<updated>2016-02-23T11:04:42+00:00</updated>
<author>
<name>Lukas Slebodnik</name>
<email>lslebodn@redhat.com</email>
</author>
<published>2016-02-12T21:05:21+00:00</published>
<link rel='alternate' type='text/html' href='https://fedorapeople.org/cgit/sbose/public_git/sssd.git/commit/?id=42604cc8d11743febf5aa892cb3a7d3c32bfed48'/>
<id>42604cc8d11743febf5aa892cb3a7d3c32bfed48</id>
<content type='text'>
Reviewed-by: Pavel Březina &lt;pbrezina@redhat.com&gt;
</content>
<content type='xhtml'>
<div xmlns='http://www.w3.org/1999/xhtml'>
<pre>
Reviewed-by: Pavel Březina &lt;pbrezina@redhat.com&gt;
</pre>
</div>
</content>
</entry>
<entry>
<title>util: Update get_next_domain's interface</title>
<updated>2015-10-23T08:32:23+00:00</updated>
<author>
<name>Michal Židek</name>
<email>mzidek@redhat.com</email>
</author>
<published>2015-09-09T12:37:48+00:00</published>
<link rel='alternate' type='text/html' href='https://fedorapeople.org/cgit/sbose/public_git/sssd.git/commit/?id=877b92e80bde510d5cd9f03dbf01e2bcf73ab072'/>
<id>877b92e80bde510d5cd9f03dbf01e2bcf73ab072</id>
<content type='text'>
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 &lt;jhrozek@redhat.com&gt;
</content>
<content type='xhtml'>
<div xmlns='http://www.w3.org/1999/xhtml'>
<pre>
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 &lt;jhrozek@redhat.com&gt;
</pre>
</div>
</content>
</entry>
<entry>
<title>negcache: allow domain name for UID and GID</title>
<updated>2015-07-27T20:03:42+00:00</updated>
<author>
<name>Sumit Bose</name>
<email>sbose@redhat.com</email>
</author>
<published>2015-07-22T12:21:52+00:00</published>
<link rel='alternate' type='text/html' href='https://fedorapeople.org/cgit/sbose/public_git/sssd.git/commit/?id=e1aed98d7c195f844ac8e85050d04f3ca5f899b3'/>
<id>e1aed98d7c195f844ac8e85050d04f3ca5f899b3</id>
<content type='text'>
Related to https://fedorahosted.org/sssd/ticket/2731

Reviewed-by: Jakub Hrozek &lt;jhrozek@redhat.com&gt;
</content>
<content type='xhtml'>
<div xmlns='http://www.w3.org/1999/xhtml'>
<pre>
Related to https://fedorahosted.org/sssd/ticket/2731

Reviewed-by: Jakub Hrozek &lt;jhrozek@redhat.com&gt;
</pre>
</div>
</content>
</entry>
<entry>
<title>ncache: add calls for certificate based searches</title>
<updated>2015-06-19T16:48:13+00:00</updated>
<author>
<name>Sumit Bose</name>
<email>sbose@redhat.com</email>
</author>
<published>2015-06-03T14:18:05+00:00</published>
<link rel='alternate' type='text/html' href='https://fedorapeople.org/cgit/sbose/public_git/sssd.git/commit/?id=8d4dedea12e2b71f83a1b0e5f0fc5cdb706dcf98'/>
<id>8d4dedea12e2b71f83a1b0e5f0fc5cdb706dcf98</id>
<content type='text'>
Related to https://fedorahosted.org/sssd/ticket/2596

Reviewed-by: Pavel Březina &lt;pbrezina@redhat.com&gt;
</content>
<content type='xhtml'>
<div xmlns='http://www.w3.org/1999/xhtml'>
<pre>
Related to https://fedorahosted.org/sssd/ticket/2596

Reviewed-by: Pavel Březina &lt;pbrezina@redhat.com&gt;
</pre>
</div>
</content>
</entry>
<entry>
<title>negcache: Soften condition for expired entries</title>
<updated>2015-05-22T10:26:59+00:00</updated>
<author>
<name>Lukas Slebodnik</name>
<email>lslebodn@redhat.com</email>
</author>
<published>2015-05-20T11:13:40+00:00</published>
<link rel='alternate' type='text/html' href='https://fedorapeople.org/cgit/sbose/public_git/sssd.git/commit/?id=75e4a7753c44e9f2a7a65fad77d95e394f81c125'/>
<id>75e4a7753c44e9f2a7a65fad77d95e394f81c125</id>
<content type='text'>
Type of timestamp for entries in negative cache is time_t
which is number of *seconds* that have elapsed since 1 January 1970.

The condition for ttl was to strict so entry could be valid
 from  "ttl-1" to  ttl e.g.
 * ttl is 1 second
 * entry was stored to negative cache at 1432120871.999639
   stored_timestamp = 1432120871
 * entry was tested few miliseconds later 1432120872.001293
   current_time = 1432120872

Entry was marked as expired becuase result of condition was false
  stored_timestamp + ttl &lt; current_time
          1432120871 + 1 &lt; 1432120872

This is a reason why ./test-negcache sometime fails.
It's quite easily reproducible on slow machine or when valgrind was used.

sh$ while libtool --mode=execute valgrind ./test-negcache ; do echo OK: done

Reviewed-by: Pavel Reichl &lt;preichl@redhat.com&gt;
</content>
<content type='xhtml'>
<div xmlns='http://www.w3.org/1999/xhtml'>
<pre>
Type of timestamp for entries in negative cache is time_t
which is number of *seconds* that have elapsed since 1 January 1970.

The condition for ttl was to strict so entry could be valid
 from  "ttl-1" to  ttl e.g.
 * ttl is 1 second
 * entry was stored to negative cache at 1432120871.999639
   stored_timestamp = 1432120871
 * entry was tested few miliseconds later 1432120872.001293
   current_time = 1432120872

Entry was marked as expired becuase result of condition was false
  stored_timestamp + ttl &lt; current_time
          1432120871 + 1 &lt; 1432120872

This is a reason why ./test-negcache sometime fails.
It's quite easily reproducible on slow machine or when valgrind was used.

sh$ while libtool --mode=execute valgrind ./test-negcache ; do echo OK: done

Reviewed-by: Pavel Reichl &lt;preichl@redhat.com&gt;
</pre>
</div>
</content>
</entry>
<entry>
<title>ncache: Add sss_ncache_reset_repopulate_permanent</title>
<updated>2015-04-09T06:35:20+00:00</updated>
<author>
<name>Jakub Hrozek</name>
<email>jhrozek@redhat.com</email>
</author>
<published>2015-03-29T14:30:27+00:00</published>
<link rel='alternate' type='text/html' href='https://fedorapeople.org/cgit/sbose/public_git/sssd.git/commit/?id=0d19785f9ffd9c66df5b30d208ec7b0216a9555b'/>
<id>0d19785f9ffd9c66df5b30d208ec7b0216a9555b</id>
<content type='text'>
This new function resets the negative cache and then re-adds the
permanent entries.

Reviewed-by: Lukáš Slebodník &lt;lslebodn@redhat.com&gt;
</content>
<content type='xhtml'>
<div xmlns='http://www.w3.org/1999/xhtml'>
<pre>
This new function resets the negative cache and then re-adds the
permanent entries.

Reviewed-by: Lukáš Slebodník &lt;lslebodn@redhat.com&gt;
</pre>
</div>
</content>
</entry>
</feed>
