From nobody Fri Jan 14 01:22:28 2022 X-Original-To: dev-commits-src-all@mlmmj.nyi.freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2610:1c1:1:606c::19:1]) by mlmmj.nyi.freebsd.org (Postfix) with ESMTP id EB05E1940B1F; Fri, 14 Jan 2022 01:22:29 +0000 (UTC) (envelope-from git@FreeBSD.org) Received: from mxrelay.nyi.freebsd.org (mxrelay.nyi.freebsd.org [IPv6:2610:1c1:1:606c::19:3]) (using TLSv1.3 with cipher TLS_AES_256_GCM_SHA384 (256/256 bits) key-exchange X25519 server-signature RSA-PSS (4096 bits) server-digest SHA256 client-signature RSA-PSS (4096 bits) client-digest SHA256) (Client CN "mxrelay.nyi.freebsd.org", Issuer "R3" (verified OK)) by mx1.freebsd.org (Postfix) with ESMTPS id 4JZk792BYVz3CwX; Fri, 14 Jan 2022 01:22:29 +0000 (UTC) (envelope-from git@FreeBSD.org) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=freebsd.org; s=dkim; t=1642123349; h=from:from:reply-to:subject:subject:date:date:message-id:message-id: to:to:cc:mime-version:mime-version:content-type:content-type: content-transfer-encoding:content-transfer-encoding; bh=uyF77mEmBylfXNNl9g7IaY8wFJ43IOQ3SUxXOuR330E=; b=pjNDXJp+Zzx9M1rA+Sdu6xTTinfSxqAdyxvhCOfY6M3t5UgcpWNjSZwZjK5jHQeJqNw9ti DT+vIrFo6rDePpoyWx52CMp2lRKovNquZLI3hop8J0aRJZzGYAXLxxYARFJfqGp1aP1Naj Ac/9Yn+0lh3DRe/UNuuNCR7bF4cllS16L4CBQ7fHK0lXMoiGbS7wVyEibh/9QbPtHXUCrZ PHIRv45Ry1zYYyRkwoUGNC0B4o7WIq0yRrhofMxhONjnLcV0v6ac9JFHtdgOIyXK6ZM1Al 9WkNvBr1Xjjkd2rVbAMv8NM8x0H5/fiZlMRzZtLO9rz1vp3USQT1PX33zGznMg== Received: from gitrepo.freebsd.org (gitrepo.freebsd.org [IPv6:2610:1c1:1:6068::e6a:5]) (using TLSv1.3 with cipher TLS_AES_256_GCM_SHA384 (256/256 bits) key-exchange X25519 server-signature RSA-PSS (4096 bits) server-digest SHA256) (Client did not present a certificate) by mxrelay.nyi.freebsd.org (Postfix) with ESMTPS id B4C642953; Fri, 14 Jan 2022 01:22:28 +0000 (UTC) (envelope-from git@FreeBSD.org) Received: from gitrepo.freebsd.org ([127.0.1.44]) by gitrepo.freebsd.org (8.16.1/8.16.1) with ESMTP id 20E1MSoQ049959; Fri, 14 Jan 2022 01:22:28 GMT (envelope-from git@gitrepo.freebsd.org) Received: (from git@localhost) by gitrepo.freebsd.org (8.16.1/8.16.1/Submit) id 20E1MSjs049958; Fri, 14 Jan 2022 01:22:28 GMT (envelope-from git) Date: Fri, 14 Jan 2022 01:22:28 GMT Message-Id: <202201140122.20E1MSjs049958@gitrepo.freebsd.org> To: src-committers@FreeBSD.org, dev-commits-src-all@FreeBSD.org, dev-commits-src-main@FreeBSD.org From: John Baldwin Subject: git: d61effd38b51 - main - Use G_ELI_IVKEYLEN as the size of IV in the user test code. List-Id: Commit messages for all branches of the src repository List-Archive: https://lists.freebsd.org/archives/dev-commits-src-all List-Help: List-Post: List-Subscribe: List-Unsubscribe: Sender: owner-dev-commits-src-all@freebsd.org X-BeenThere: dev-commits-src-all@freebsd.org MIME-Version: 1.0 Content-Type: text/plain; charset=utf-8 Content-Transfer-Encoding: 8bit X-Git-Committer: jhb X-Git-Repository: src X-Git-Refname: refs/heads/main X-Git-Reftype: branch X-Git-Commit: d61effd38b518edd58c29144805cfff235c0d704 Auto-Submitted: auto-generated ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=freebsd.org; s=dkim; t=1642123349; h=from:from:reply-to:subject:subject:date:date:message-id:message-id: to:to:cc:mime-version:mime-version:content-type:content-type: content-transfer-encoding:content-transfer-encoding; bh=uyF77mEmBylfXNNl9g7IaY8wFJ43IOQ3SUxXOuR330E=; b=xKxwtZSCf/qumEukWKngxPw4YDQmfLHgNdWbvbKGCPt8qxYYNpxVfuspgt/+LL+RWBgsqq rFkpI16EkCztUiUnqJEpvKhWCctZnE0G/9HaZG0/Hw/h0nYEQc4wMeujpwDax8DsHQyEbs MLZmpsV/RqH2ga960Dlf8knwJUU9WvvTFJnBCVteYfAO+9RA3bSsY6JRkrWftIdFQvbq7S Vylc4vAwMiAgHAjd4bFweVTpDh79a+QmhA0XEz6ULJUyBWzLkae/RQCcreW0lJoCj2DneM TQbNZye85zTMyYQbMHA/YGVD10e5DloRIPWtPl2503CjyNbfyiJNVdQVhaiAOg== ARC-Seal: i=1; s=dkim; d=freebsd.org; t=1642123349; a=rsa-sha256; cv=none; b=XxmvJ+TNVuHBh1oN9BsM5now3mdfNKmGDD2JQM8O6uZHx9VIjXs66SKo2XrEWyIN3ocmd1 WIO1p2tRz3EbKWKZoUyLEjXXJmKuabV8T6UF98Pt8e/GZhqRwiN1mhN0YNoU9Ox9uMI6Ji v4YBRyrYvMjj865loUT/PQ1tJLoOVEFfslcSApzLkAQ36DxDo323euAAwO1VtiGbtseZkZ N44nal9wfUoMwWoMJy7nVa1e74kkSGrx4k8+fiZ8dsIV+H/RCMHGEnppTh3YpyKSSe38wC 6sXd6a9Nmioki+GCNV1uExTbzLOvRGXf5l2Wm1LyKd/737Kh6bcaxGJNjAj2mg== ARC-Authentication-Results: i=1; mx1.freebsd.org; none X-ThisMailContainsUnwantedMimeParts: N The branch main has been updated by jhb: URL: https://cgit.FreeBSD.org/src/commit/?id=d61effd38b518edd58c29144805cfff235c0d704 commit d61effd38b518edd58c29144805cfff235c0d704 Author: John Baldwin AuthorDate: 2022-01-14 01:22:06 +0000 Commit: John Baldwin CommitDate: 2022-01-14 01:22:06 +0000 Use G_ELI_IVKEYLEN as the size of IV in the user test code. IVs are not the size of keys as a general case. Most often they are the size of a single block. Reviewed by: imp Sponsored by: The FreeBSD Foundation Differential Revision: https://reviews.freebsd.org/D33885 --- sys/geom/eli/g_eli_crypto.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/sys/geom/eli/g_eli_crypto.c b/sys/geom/eli/g_eli_crypto.c index ca8170db7e4d..441bedb030b8 100644 --- a/sys/geom/eli/g_eli_crypto.c +++ b/sys/geom/eli/g_eli_crypto.c @@ -112,7 +112,7 @@ g_eli_crypto_cipher(u_int algo, int enc, u_char *data, size_t datasize, { EVP_CIPHER_CTX *ctx; const EVP_CIPHER *type; - u_char iv[keysize]; + u_char iv[G_ELI_IVKEYLEN]; int outsize; assert(algo != CRYPTO_AES_XTS);