libceph: Rename hmac_sha256() to ceph_hmac_sha256()
Rename hmac_sha256() to ceph_hmac_sha256(), to avoid a naming conflict with the upcoming hmac_sha256() library function. This code will be able to use the HMAC-SHA256 library, but that's left for a later commit. Acked-by: Ard Biesheuvel <ardb@kernel.org> Link: https://lore.kernel.org/r/20250630160645.3198-2-ebiggers@kernel.org Signed-off-by: Eric Biggers <ebiggers@kernel.org>pull/1309/head
parent
22375adaa0
commit
1cf5cdf8d2
|
|
@ -793,8 +793,8 @@ static int setup_crypto(struct ceph_connection *con,
|
||||||
return 0; /* auth_x, secure mode */
|
return 0; /* auth_x, secure mode */
|
||||||
}
|
}
|
||||||
|
|
||||||
static int hmac_sha256(struct ceph_connection *con, const struct kvec *kvecs,
|
static int ceph_hmac_sha256(struct ceph_connection *con,
|
||||||
int kvec_cnt, u8 *hmac)
|
const struct kvec *kvecs, int kvec_cnt, u8 *hmac)
|
||||||
{
|
{
|
||||||
SHASH_DESC_ON_STACK(desc, con->v2.hmac_tfm); /* tfm arg is ignored */
|
SHASH_DESC_ON_STACK(desc, con->v2.hmac_tfm); /* tfm arg is ignored */
|
||||||
int ret;
|
int ret;
|
||||||
|
|
@ -1462,8 +1462,8 @@ static int prepare_auth_signature(struct ceph_connection *con)
|
||||||
if (!buf)
|
if (!buf)
|
||||||
return -ENOMEM;
|
return -ENOMEM;
|
||||||
|
|
||||||
ret = hmac_sha256(con, con->v2.in_sign_kvecs, con->v2.in_sign_kvec_cnt,
|
ret = ceph_hmac_sha256(con, con->v2.in_sign_kvecs,
|
||||||
CTRL_BODY(buf));
|
con->v2.in_sign_kvec_cnt, CTRL_BODY(buf));
|
||||||
if (ret)
|
if (ret)
|
||||||
return ret;
|
return ret;
|
||||||
|
|
||||||
|
|
@ -2460,8 +2460,8 @@ static int process_auth_signature(struct ceph_connection *con,
|
||||||
return -EINVAL;
|
return -EINVAL;
|
||||||
}
|
}
|
||||||
|
|
||||||
ret = hmac_sha256(con, con->v2.out_sign_kvecs,
|
ret = ceph_hmac_sha256(con, con->v2.out_sign_kvecs,
|
||||||
con->v2.out_sign_kvec_cnt, hmac);
|
con->v2.out_sign_kvec_cnt, hmac);
|
||||||
if (ret)
|
if (ret)
|
||||||
return ret;
|
return ret;
|
||||||
|
|
||||||
|
|
|
||||||
Loading…
Reference in New Issue