From nobody Tue Jul 04 12:41:30 2023 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 4QwMqG3fkGz4lJDp; Tue, 4 Jul 2023 12:41:30 +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 4QwMqG2ScDz43fc; Tue, 4 Jul 2023 12:41:30 +0000 (UTC) (envelope-from git@FreeBSD.org) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=freebsd.org; s=dkim; t=1688474490; 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=w/AEwCISP6jF13U7dqdxuqbhkaSUmQaeCVG69fywyHQ=; b=LxH/CacfngqdBFwyReqt/1KKlqCI0wkmSEdeg/qZ4OaCkUn+pVMhQsfrnc149QGOLsuHEA +jR8WUa9EPVQzjq9dlCpeSmDvE0R0vqsucQjOkyOWJXslpZK3nlry23RIKDs5NEjfCZqEH 4vp8udcAYIQxWIsLkrQjAC2pKlnbdSGSvDolY20QngSoYFBApG4zc0J3jxRm1DgV+lRTVR jMx7ICFx4n6rbkc9ABLzBlRMgmJ5pM7Qm6eUBi/0jb/GhAArUZNU2QjhnBYXP1g0U2EBKa 0hzrZRspZagIUS6TjnC+06iEl2B/FwjMbB1VO6CfHH5zMLCp0X7KF+2/W0E/mg== ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=freebsd.org; s=dkim; t=1688474490; 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=w/AEwCISP6jF13U7dqdxuqbhkaSUmQaeCVG69fywyHQ=; b=s9F/ZU8CEWpOC49yfx5x8W+KhU9raEvbeNa8lm3WeCC2CdDpDvyET5CuRpAruMT8KziMad N5TonWSkgdL/H+ms+KG7qgGGcIMcLBsmojyI6IPYjHA/XPI0K2ZIhiFJr8DezJ5ObKMz88 erKeD0qbb8THOoKJp3LZCWc0YHw+WbOSDjHNZS+rsOkp/5RbixukCpZ2/ru2Aikqaav3In k2UaH26SiKe4qrMA1HH+sWOmwsjyvqgfS+vBy/v33Xs1T4CBq5LatiyPGcOcNY8f3Mlt62 EkLvtNjmFQ1SHwzzVC4Gz29wdfzWwmqMpts6pQ8HJfSU0jV4vKrU9Re/Q2rw0A== ARC-Authentication-Results: i=1; mx1.freebsd.org; none ARC-Seal: i=1; s=dkim; d=freebsd.org; t=1688474490; a=rsa-sha256; cv=none; b=mT58ePZvqrgjWZNJPkMMVA1JEwes57CNGAT5kPl/b68/A4Bm3ivWu7Mbsco3Tes7p48OtI bkwngBXJFb4S6A2yZny08xX3W3dX8Dj/bLqujbtEnIy9iSA2vx3M9RSHbUUhwpk0TYrpCq 6g7qVa8n7RxcEBfUfJ09Y2nmdGpon5OAPRIDZFx7B/ktZFEWcpFq+h1MX4UvInu6rnFdd7 DH75nT9ApkvY/PEKQ4qtZ7rXHV/s5X/8MkvsSr62ulp7NPDfD1Rr5Itku2WU8Rhm/GWVUB PwUocwHzowNq+CVjxkoPRSqgOSFFIH5BEqUaOobTpX4/4t65nHU4KHxYPNF6jQ== 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 4QwMqG1WZ8zY02; Tue, 4 Jul 2023 12:41:30 +0000 (UTC) (envelope-from git@FreeBSD.org) Received: from gitrepo.freebsd.org ([127.0.1.44]) by gitrepo.freebsd.org (8.17.1/8.17.1) with ESMTP id 364CfUCG048054; Tue, 4 Jul 2023 12:41:30 GMT (envelope-from git@gitrepo.freebsd.org) Received: (from git@localhost) by gitrepo.freebsd.org (8.17.1/8.17.1/Submit) id 364CfUpx048053; Tue, 4 Jul 2023 12:41:30 GMT (envelope-from git) Date: Tue, 4 Jul 2023 12:41:30 GMT Message-Id: <202307041241.364CfUpx048053@gitrepo.freebsd.org> To: src-committers@FreeBSD.org, dev-commits-src-all@FreeBSD.org, dev-commits-src-branches@FreeBSD.org From: Ka Ho Ng Subject: git: 4c20e26e26ec - stable/13 - syscalls: fix modspecific_t stack content leak 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: khng X-Git-Repository: src X-Git-Refname: refs/heads/stable/13 X-Git-Reftype: branch X-Git-Commit: 4c20e26e26ec33664475900de028c9e77bffd8bf Auto-Submitted: auto-generated X-ThisMailContainsUnwantedMimeParts: N The branch stable/13 has been updated by khng: URL: https://cgit.FreeBSD.org/src/commit/?id=4c20e26e26ec33664475900de028c9e77bffd8bf commit 4c20e26e26ec33664475900de028c9e77bffd8bf Author: Ka Ho Ng AuthorDate: 2023-06-27 19:33:46 +0000 Commit: Ka Ho Ng CommitDate: 2023-07-04 12:41:07 +0000 syscalls: fix modspecific_t stack content leak Zero-initialize the whole modspecific_t so that there would not be kernel stack content leak in the unused part. Sponsored by: Juniper Networks, Inc. Differential Revision: https://reviews.freebsd.org/D40815 (cherry picked from commit 2cab2d43b83bddd44ecc1f267afb5e2725975ac7) --- sys/kern/kern_syscalls.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/sys/kern/kern_syscalls.c b/sys/kern/kern_syscalls.c index b4fec879708a..fa1df225ee3b 100644 --- a/sys/kern/kern_syscalls.c +++ b/sys/kern/kern_syscalls.c @@ -173,7 +173,7 @@ kern_syscall_module_handler(struct sysent *sysents, struct module *mod, int what, void *arg) { struct syscall_module_data *data = arg; - modspecific_t ms; + modspecific_t ms = { 0 }; int error; switch (what) {