diff options
author | Enzo Matsumiya <ematsumiya@suse.de> | 2024-09-26 14:46:16 -0300 |
---|---|---|
committer | Steve French <stfrench@microsoft.com> | 2024-09-26 18:15:19 -0500 |
commit | 220d83b52c7d16ec3c168b82f4e6ce59c645f7ab (patch) | |
tree | eec846177fdd5b3e10712ee3606c90ff337d3c89 /fs/smb/client/sess.c | |
parent | db44ca9f7bc00a368d345b9fa1ecee0c4e75ac48 (diff) |
smb: client: make SHA-512 TFM ephemeral
The SHA-512 shash TFM is used only briefly during Session Setup stage,
when computing SMB 3.1.1 preauth hash.
There's no need to keep it allocated in servers' secmech the whole time,
so keep its lifetime inside smb311_update_preauth_hash().
This also makes smb311_crypto_shash_allocate() redundant, so expose
smb3_crypto_shash_allocate() and use that.
Signed-off-by: Enzo Matsumiya <ematsumiya@suse.de>
Signed-off-by: Steve French <stfrench@microsoft.com>
Diffstat (limited to 'fs/smb/client/sess.c')
-rw-r--r-- | fs/smb/client/sess.c | 2 |
1 files changed, 1 insertions, 1 deletions
diff --git a/fs/smb/client/sess.c b/fs/smb/client/sess.c index 3216f786908f..03c0b484a4b5 100644 --- a/fs/smb/client/sess.c +++ b/fs/smb/client/sess.c @@ -624,7 +624,7 @@ cifs_ses_add_channel(struct cifs_ses *ses, * to sign packets before we generate the channel signing key * (we sign with the session key) */ - rc = smb311_crypto_shash_allocate(chan->server); + rc = smb3_crypto_shash_allocate(chan->server); if (rc) { cifs_dbg(VFS, "%s: crypto alloc failed\n", __func__); mutex_unlock(&ses->session_mutex); |