From: Guenther Deschner Date: Thu, 7 May 2009 19:53:00 +0000 (-0700) Subject: s3-credentials: protect netlogon_creds_server_step() against NULL creds. X-Git-Url: http://git.ipfire.org/cgi-bin/gitweb.cgi?a=commitdiff_plain;h=c578c66569eed3ae19b42c9787399eb70b935e0a;p=thirdparty%2Fsamba.git s3-credentials: protect netlogon_creds_server_step() against NULL creds. Found by SCHANNEL torture tests. Guenther --- diff --git a/source/libsmb/credentials.c b/source/libsmb/credentials.c index 9d33e6d93d7..4bfa2318c44 100644 --- a/source/libsmb/credentials.c +++ b/source/libsmb/credentials.c @@ -255,6 +255,10 @@ bool netlogon_creds_server_step(struct dcinfo *dc, bool ret; struct dcinfo tmp_dc = *dc; + if (!received_cred || !cred_out) { + return false; + } + /* Do all operations on a temporary copy of the dc, which we throw away if the checks fail. */