From nobody Tue Jul 04 12:53:08 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 4QwN4j0RxWz4lPf4; Tue, 4 Jul 2023 12:53:09 +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 4QwN4h6DGpz463p; Tue, 4 Jul 2023 12:53:08 +0000 (UTC) (envelope-from git@FreeBSD.org) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=freebsd.org; s=dkim; t=1688475188; 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=B68Mbnr3RJTqbeEcP4ClHgbAaPhYyHipyd60bcS/Ufo=; b=PUMrwiGcDLbe/WvbtQ9qu29XZvSvhwTwt7EsKnlvi9PRuR/fGRDMO/uCL4XhKj7wjcIDAO XyGip9Y6wSj/mSCfuBnwHWNmY8R/V/EE8T8fY4MnxtdoizpapodzwpVC4t16tAI3KFrOtu Sj5P5eafhy6ItxK+INp7w/RyTXwEI4pWnE/lat0DsvOjgXfHTajTY/zGrv6k6BHg8pAz6I 8QKyHFbLIuvTtg7ycdPBm9WeFp6rfoWFboSIySjx9TbbzAFwISR4lNntBAyovD2ybB3Gnw St1stuGaFIz5MxqvBGwZYe9ITx5IG7tuLIoT8x269i7AaIpSG8+E5AADbmgyTA== ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=freebsd.org; s=dkim; t=1688475188; 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=B68Mbnr3RJTqbeEcP4ClHgbAaPhYyHipyd60bcS/Ufo=; b=AHiuWlZlTWOCwRvV56D/QBdJ15YphInrm8Ho/1rpp6Zjn9aum3+YdeM/4SZkeRekoY1150 GOE7J6PF7HNgaxD7Sk2heXDNW5vNjiSSFrdE1Xv1MC4r9YqXPPALdOSw5il2bjam/DvTOn zpdhgZWB3JWHXQOaurov2NOLACWIfWN6T3p96WKnaOfuRhuuYri1lvQG0X03UaVhwobG1n VMorVM/XXbnCf6CNI25IFAkvRSj6xtK8nUc3J5nO7brnsWpfKOUoKASNckgL46IidK2lNY 25yheCwt6NNegr+cjtqHc4Mn4aAEBngOTAMJK17xysLIPOS0/yvpQY6EvuPnTw== ARC-Authentication-Results: i=1; mx1.freebsd.org; none ARC-Seal: i=1; s=dkim; d=freebsd.org; t=1688475188; a=rsa-sha256; cv=none; b=GuCIXcBKPtSJYJRds58zX3v6GtIrj7zgYTU2f7+sF23iHUKld9ayIkxY1GHblk93DflaB6 C+u0IatWdTCZP8kRnbqLjSiZrJGuzBPlzq7iSCrg/ibxZZUNAaAV9JCYER2g8fC570JvJn Jxf1XnwbZOz4jDEY+v/c+JoS9Vg9oiDA9qXjE+tVctFy5UnfTnWWdfvrfMzxXUeNmMTBMD G53WBX2VKHSYOmUXh0g8ERaobOCWTrEPHk3xgnN5p/gIcKK01vAK1a7iWNEHGBnEjCyiAZ q0O0OiN7Oe9tkdgSlHF4ZdkjFTBE2hA+azG7MBpAHSbH4l92W0m86ddm0xy0dw== 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 4QwN4h5J9nzY8D; Tue, 4 Jul 2023 12:53:08 +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 364Cr88K067007; Tue, 4 Jul 2023 12:53:08 GMT (envelope-from git@gitrepo.freebsd.org) Received: (from git@localhost) by gitrepo.freebsd.org (8.17.1/8.17.1/Submit) id 364Cr82H067006; Tue, 4 Jul 2023 12:53:08 GMT (envelope-from git) Date: Tue, 4 Jul 2023 12:53:08 GMT Message-Id: <202307041253.364Cr82H067006@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: 2d148ce84d29 - stable/12 - 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/12 X-Git-Reftype: branch X-Git-Commit: 2d148ce84d29321f5f1a0ccb405c5238f5859005 Auto-Submitted: auto-generated X-ThisMailContainsUnwantedMimeParts: N The branch stable/12 has been updated by khng: URL: https://cgit.FreeBSD.org/src/commit/?id=2d148ce84d29321f5f1a0ccb405c5238f5859005 commit 2d148ce84d29321f5f1a0ccb405c5238f5859005 Author: Ka Ho Ng AuthorDate: 2023-06-27 19:33:46 +0000 Commit: Ka Ho Ng CommitDate: 2023-07-04 12:52:50 +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 035e169bbe0e..0af8e18890c8 100644 --- a/sys/kern/kern_syscalls.c +++ b/sys/kern/kern_syscalls.c @@ -164,7 +164,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) {