The initialize_winbindd_cache() function uses tdb_fetch_uint32_byblob()
to check if the cache version is valid and up to date. As
tdb_fetch_uint32_byblob() returns false for a successful fetch, we
always remove the winbind cache database. This breaks the winbind
offline logon feature.
This also affects other caches and pdb.
BUG: https://bugzilla.samba.org/show_bug.cgi?id=14702
Signed-off-by: Andreas Schneider <asn@samba.org>
Reviewed-by: Jeremy Allison <jra@samba.org>
Autobuild-User(master): Jeremy Allison <jra@samba.org>
Autobuild-Date(master): Wed May 12 21:19:03 UTC 2021 on sn-devel-184
uint32_t *value)
{
int ret = tdb_parse_record(tdb, key, fetch_uint32_parser, value);
- return ret;
+
+ if (ret == -1) {
+ return false;
+ }
+
+ return true;
}
/****************************************************************************
+++ /dev/null
-samba.blackbox.offline_logon.wbinfo.pam_logon_alice\(ad_member_offline_logon\)
-samba.blackbox.offline_logon.wbinfo.pam_logon_bob\(ad_member_offline_logon\)
-samba.blackbox.offline_logon.wbinfo.kerberos_logon_alice\(ad_member_offline_logon\)
-samba.blackbox.offline_logon.wbinfo.kerberos_logon_bob\(ad_member_offline_logon\)