diff options
author | Joseph Sutton <josephsutton@catalyst.net.nz> | 2023-05-02 14:48:25 +1200 |
---|---|---|
committer | Andrew Bartlett <abartlet@samba.org> | 2023-05-18 01:03:37 +0000 |
commit | 78cca1411ff510f06f6665ccc32f2808e18f02cc (patch) | |
tree | 40aa3e44db97e7b6db4d889a523edd7959f0d01b | |
parent | 3424c6d20fe32f7821ccd61b385189ef271e68ab (diff) | |
download | samba-78cca1411ff510f06f6665ccc32f2808e18f02cc.tar.gz |
netlogon:schannel: Fix NULL pointer dereference
We should not pass a NULL pointer into netlogon_creds_client_init().
Signed-off-by: Joseph Sutton <josephsutton@catalyst.net.nz>
Reviewed-by: Andrew Bartlett <abartlet@samba.org>
-rw-r--r-- | source4/librpc/rpc/dcerpc_schannel.c | 3 |
1 files changed, 3 insertions, 0 deletions
diff --git a/source4/librpc/rpc/dcerpc_schannel.c b/source4/librpc/rpc/dcerpc_schannel.c index 35395ffd214..244c39a9c90 100644 --- a/source4/librpc/rpc/dcerpc_schannel.c +++ b/source4/librpc/rpc/dcerpc_schannel.c @@ -173,6 +173,9 @@ static void continue_srv_challenge(struct tevent_req *subreq) /* prepare credentials for auth2 request */ s->mach_pwd = cli_credentials_get_nt_hash(s->credentials, c); + if (s->mach_pwd == NULL) { + return composite_error(c, NT_STATUS_INTERNAL_ERROR); + } /* auth2 request arguments */ s->a.in.server_name = s->r.in.server_name; |