diff options
author | Stefan Metzmacher <metze@samba.org> | 2019-06-11 17:47:33 +0200 |
---|---|---|
committer | Stefan Metzmacher <metze@samba.org> | 2019-06-12 12:42:26 +0000 |
commit | 2ad02acf386757b50a957e35bb29a7d34c921e53 (patch) | |
tree | 1e701d47c6aa2bdddad49df49d7bdbad26aa9957 /libcli | |
parent | 824db2967279dd01e7cfd69abf9b848975b5d451 (diff) | |
download | samba-2ad02acf386757b50a957e35bb29a7d34c921e53.tar.gz |
Revert "libcli:smb: Fix signing with multichannel"
This reverts commit 1817db965dc0caf55e4308fa4d9203ab4381dc90.
This was pushed to fast, the corrected commit follows.
Signed-off-by: Stefan Metzmacher <metze@samba.org>
Reviewed-by: Andreas Schneider <asn@samba.org>
Diffstat (limited to 'libcli')
-rw-r--r-- | libcli/smb/smbXcli_base.c | 12 |
1 files changed, 4 insertions, 8 deletions
diff --git a/libcli/smb/smbXcli_base.c b/libcli/smb/smbXcli_base.c index e916a17e07a..a82146a60f4 100644 --- a/libcli/smb/smbXcli_base.c +++ b/libcli/smb/smbXcli_base.c @@ -3282,8 +3282,7 @@ skip_credits: * If it is a channel binding, we already have the main * signing key and try that one. */ - if (signing_key != NULL && - !smb2_signing_key_valid(signing_key)) { + if (!smb2_signing_key_valid(signing_key)) { signing_key = state->session->smb2->signing_key; } @@ -3291,8 +3290,7 @@ skip_credits: * If we do not have any session key yet, we skip the * signing of SMB2_OP_SESSSETUP requests. */ - if (signing_key != NULL && - !smb2_signing_key_valid(signing_key)) { + if (!smb2_signing_key_valid(signing_key)) { signing_key = NULL; } } @@ -3791,14 +3789,12 @@ static NTSTATUS smb2cli_conn_dispatch_incoming(struct smbXcli_conn *conn, * we try the main signing key, if it is not * the final response. */ - if (signing_key != NULL && - !smb2_signing_key_valid(signing_key) && + if (!smb2_signing_key_valid(signing_key) && !NT_STATUS_IS_OK(status)) { signing_key = session->smb2->signing_key; } - if (signing_key != NULL && - !smb2_signing_key_valid(signing_key)) { + if (!smb2_signing_key_valid(signing_key)) { /* * If we do not have a session key to * verify the signature, we defer the |