Re: [PATCH v3 2/6] ksmbd: sign with the negotiated SMB 3.1.1 signing algorithm
From: Namjae Jeon
Date: Tue Nov 10 2026 - 10:27:13 EST
> +void ksmbd_sign_smb3_pdu(struct ksmbd_conn *conn, __le16 signing_algorithm,
> + char *key, struct kvec *iov, int n_vec, char *sig)
> {
> struct aes_cmac_key cmac_key __cleanup(aes_cmac_zeroize_key);
> struct aes_cmac_ctx cmac_ctx;
> int i;
>
> + if (signing_algorithm == SIGNING_ALG_HMAC_SHA256_LE) {
> + u8 mac[SHA256_DIGEST_SIZE];
We can use SMB2_HMACSHA256_SIZE.