Removes unused parameter 'sending' from derive_secret_key_and_iv()

Fixes #21569

CLA: trivial

Reviewed-by: Tom Cosgrove <tom.cosgrove@arm.com>
Reviewed-by: Paul Dale <pauli@openssl.org>
Reviewed-by: Matt Caswell <matt@openssl.org>
(Merged from https://github.com/openssl/openssl/pull/21569)
This commit is contained in:
Frederik Wedel-Heinen 2023-07-27 11:28:33 +02:00 committed by Matt Caswell
parent c612289b77
commit fbd23b9296

View File

@ -334,8 +334,7 @@ int tls13_setup_key_block(SSL_CONNECTION *s)
return 1;
}
static int derive_secret_key_and_iv(SSL_CONNECTION *s, int sending,
const EVP_MD *md,
static int derive_secret_key_and_iv(SSL_CONNECTION *s, const EVP_MD *md,
const EVP_CIPHER *ciph,
const unsigned char *insecret,
const unsigned char *hash,
@ -624,7 +623,7 @@ int tls13_change_cipher_state(SSL_CONNECTION *s, int which)
if (!ossl_assert(cipher != NULL))
goto err;
if (!derive_secret_key_and_iv(s, which & SSL3_CC_WRITE, md, cipher,
if (!derive_secret_key_and_iv(s, md, cipher,
insecret, hash, label, labellen, secret, key,
&keylen, iv, &ivlen, &taglen)) {
/* SSLfatal() already called */
@ -723,7 +722,7 @@ int tls13_update_key(SSL_CONNECTION *s, int sending)
else
insecret = s->client_app_traffic_secret;
if (!derive_secret_key_and_iv(s, sending, md,
if (!derive_secret_key_and_iv(s, md,
s->s3.tmp.new_sym_enc, insecret, NULL,
application_traffic,
sizeof(application_traffic) - 1, secret, key,