From nobody Mon Jan 24 14:21:02 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 90959198FEFD; Mon, 24 Jan 2022 14:21:02 +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 4JjBwt3g56z3Gvq; Mon, 24 Jan 2022 14:21:02 +0000 (UTC) (envelope-from git@FreeBSD.org) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=freebsd.org; s=dkim; t=1643034062; 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=HnpCQPUzhjGq5SXVqWxfCwVfzQ+Vg/kyUw0NrNVQzMc=; b=mKYxlleiRWVprMV5Zg25Miuq42X80ktjL50hfaA6M4nmIj8FNrPDzvqki6lF9ih7X6xLjE R9OfqELDNKGarmikFwRqoZ7BCxD5qsAvRyBM0f3hjSmwJrjRDkViy+iyigGf2CIWADBrjA zuISNokistJYoNlB3ejsDlg9ghcQ4cjKoIFNRgEl1hSri56EYSgBk2+dRQDaRrlmSWbt4G nR3ndzeHlxo1lhyuIyhbpJNTLxqKeS8w851vyapTLPiSrIGZr9gSIWyQdj3ZFZMcwHHWfm FY4vCXGTzSI0CVSJCrzQ+fj+vEny26LWKni345DkCgZyM2VeGZaRayJPWOZfqg== 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 5DBBB17A03; Mon, 24 Jan 2022 14:21:02 +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 20OEL2OB042242; Mon, 24 Jan 2022 14:21:02 GMT (envelope-from git@gitrepo.freebsd.org) Received: (from git@localhost) by gitrepo.freebsd.org (8.16.1/8.16.1/Submit) id 20OEL2rG042241; Mon, 24 Jan 2022 14:21:02 GMT (envelope-from git) Date: Mon, 24 Jan 2022 14:21:02 GMT Message-Id: <202201241421.20OEL2rG042241@gitrepo.freebsd.org> To: src-committers@FreeBSD.org, dev-commits-src-all@FreeBSD.org, dev-commits-src-branches@FreeBSD.org From: Mark Johnston Subject: git: 9795d85d2e73 - stable/13 - posixshm: Report output buffer truncation from kern.ipc.posix_shm_list 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: markj X-Git-Repository: src X-Git-Refname: refs/heads/stable/13 X-Git-Reftype: branch X-Git-Commit: 9795d85d2e73472e65d48b27a3c684f130722009 Auto-Submitted: auto-generated ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=freebsd.org; s=dkim; t=1643034062; 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=HnpCQPUzhjGq5SXVqWxfCwVfzQ+Vg/kyUw0NrNVQzMc=; b=ti5J2uPmUPmlUSFcFXgwHCVeeSkmegh2JzHg6q83bJ44Hin9cesqCrSIBC1grCZx11a/ru jU8BmUsvcRU1MZvi7R9EvEkS7GOhSLLR7N5t43mrAxQmL9oPQvpQc7//bkMOY3XI/SUA0Q /TsSnv9l2DRuBe7OtSOaUiGeDAWi6c/IE90q/a+mp/Yfb1mmQNdBwynYeVJ26v8N4Qmlfw GZ288t3utnIWld+jmFCfYI+yTfA+9gNeCkUc/BFcxsf3cpiXjWb6/iOMt0j5qEaDwMTZDg 5OEDzKHZwgEO1+0pjmk4b0WyMu6OIQ+FIhb7gEqD9hrENGZkVKWPX6n59SwTSg== ARC-Seal: i=1; s=dkim; d=freebsd.org; t=1643034062; a=rsa-sha256; cv=none; b=dKzT1GlPL1UAykGO/OLhyshmbFjUQuZfT4chqK8mjuMIgV2iei6G+KeOQRAfpVAduAMOTf a6/J+WTGEjBOrT29m3/exXXXF9LSGxmSIUtp0lRYE9TFuDk6FtiMjUTZjSQmbzPccDCCxn /z+OSyjQmIepLl/9/2QNaX8WhVznrI83IQdRfjxXq50G0Ef7BN0/5CV9S3IJYrZwUtRD41 SacWFor0UTtO1fLACMCgGKqCuf5SbEIwyOtrp3auuzS/lGVB6LiqhwQCgfO/zd2AynrYPA CHEAInZEZr7BB6p/+LhuSsfms+VAwt51KNwQy2Uh/qjdB4xOC6zSnWgZYsfoKg== ARC-Authentication-Results: i=1; mx1.freebsd.org; none X-ThisMailContainsUnwantedMimeParts: N The branch stable/13 has been updated by markj: URL: https://cgit.FreeBSD.org/src/commit/?id=9795d85d2e73472e65d48b27a3c684f130722009 commit 9795d85d2e73472e65d48b27a3c684f130722009 Author: Mark Johnston AuthorDate: 2022-01-17 13:33:05 +0000 Commit: Mark Johnston CommitDate: 2022-01-24 14:16:37 +0000 posixshm: Report output buffer truncation from kern.ipc.posix_shm_list PR: 240573 Reviewed by: kib Sponsored by: The FreeBSD Foundation (cherry picked from commit dc7526170d4cc62f35bafb25dd026399c612ed5b) --- sys/kern/uipc_shm.c | 3 --- 1 file changed, 3 deletions(-) diff --git a/sys/kern/uipc_shm.c b/sys/kern/uipc_shm.c index 7823e92378b0..2c9cf92fe5ad 100644 --- a/sys/kern/uipc_shm.c +++ b/sys/kern/uipc_shm.c @@ -1934,9 +1934,6 @@ sysctl_posix_shm_list(SYSCTL_HANDLER_ARGS) if (error != 0) break; pack_kinfo(&kif); - if (req->oldptr != NULL && - kif.kf_structsize + curlen > req->oldlen) - break; error = sbuf_bcat(&sb, &kif, kif.kf_structsize) == 0 ? 0 : ENOMEM; if (error != 0)