diff options
author | Günther Deschner <gd@samba.org> | 2006-09-14 10:08:36 +0000 |
---|---|---|
committer | Gerald (Jerry) Carter <jerry@samba.org> | 2007-10-10 11:51:45 -0500 |
commit | b2c0260219c400b1b219333d7b18d9ed81e1ffe4 (patch) | |
tree | 4654815d4414a28e42889889a3a07067b16a9678 /source3 | |
parent | 415c75f320ff44fd6e297e969737a38dee17877d (diff) | |
download | samba-b2c0260219c400b1b219333d7b18d9ed81e1ffe4.tar.gz samba-b2c0260219c400b1b219333d7b18d9ed81e1ffe4.tar.bz2 samba-b2c0260219c400b1b219333d7b18d9ed81e1ffe4.zip |
r18510: Protect against storing null-sids in the winbind cache.
Guenther
(This used to be commit b04c8d46efc67e013b976e0ba1be558b70a1f899)
Diffstat (limited to 'source3')
-rw-r--r-- | source3/nsswitch/winbindd_cache.c | 8 |
1 files changed, 8 insertions, 0 deletions
diff --git a/source3/nsswitch/winbindd_cache.c b/source3/nsswitch/winbindd_cache.c index ac3b2661f0..09b10f27f8 100644 --- a/source3/nsswitch/winbindd_cache.c +++ b/source3/nsswitch/winbindd_cache.c @@ -788,6 +788,10 @@ static void wcache_save_sid_to_name(struct winbindd_domain *domain, NTSTATUS sta struct cache_entry *centry; fstring sid_string; + if (is_null_sid(&sid)) { + return; + } + centry = centry_start(domain, status); if (!centry) return; @@ -807,6 +811,10 @@ static void wcache_save_user(struct winbindd_domain *domain, NTSTATUS status, WI struct cache_entry *centry; fstring sid_string; + if (is_null_sid(&info->user_sid)) { + return; + } + centry = centry_start(domain, status); if (!centry) return; |