From nobody Fri Mar 18 11:20:46 2022 X-Original-To: bugs@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 A87631A32AE2 for ; Fri, 18 Mar 2022 11:20:46 +0000 (UTC) (envelope-from bugzilla-noreply@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 4KKhQQ1x0Fz4XPr for ; Fri, 18 Mar 2022 11:20:46 +0000 (UTC) (envelope-from bugzilla-noreply@freebsd.org) Received: from kenobi.freebsd.org (kenobi.freebsd.org [IPv6:2610:1c1:1:606c::50:1d]) (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 1ED9E1E144 for ; Fri, 18 Mar 2022 11:20:46 +0000 (UTC) (envelope-from bugzilla-noreply@freebsd.org) Received: from kenobi.freebsd.org ([127.0.1.5]) by kenobi.freebsd.org (8.15.2/8.15.2) with ESMTP id 22IBKkW3018503 for ; Fri, 18 Mar 2022 11:20:46 GMT (envelope-from bugzilla-noreply@freebsd.org) Received: (from www@localhost) by kenobi.freebsd.org (8.15.2/8.15.2/Submit) id 22IBKkCv018502 for bugs@FreeBSD.org; Fri, 18 Mar 2022 11:20:46 GMT (envelope-from bugzilla-noreply@freebsd.org) X-Authentication-Warning: kenobi.freebsd.org: www set sender to bugzilla-noreply@freebsd.org using -f From: bugzilla-noreply@freebsd.org To: bugs@FreeBSD.org Subject: [Bug 262633] Missing mtx protecting variable prison->pr_prison_racct Date: Fri, 18 Mar 2022 11:20:46 +0000 X-Bugzilla-Reason: AssignedTo X-Bugzilla-Type: changed X-Bugzilla-Watch-Reason: None X-Bugzilla-Product: Base System X-Bugzilla-Component: kern X-Bugzilla-Version: CURRENT X-Bugzilla-Keywords: X-Bugzilla-Severity: Affects Only Me X-Bugzilla-Who: firk@cantconnect.ru X-Bugzilla-Status: New X-Bugzilla-Resolution: X-Bugzilla-Priority: --- X-Bugzilla-Assigned-To: bugs@FreeBSD.org X-Bugzilla-Flags: X-Bugzilla-Changed-Fields: Message-ID: In-Reply-To: References: Content-Type: text/plain; charset="UTF-8" Content-Transfer-Encoding: quoted-printable X-Bugzilla-URL: https://bugs.freebsd.org/bugzilla/ Auto-Submitted: auto-generated List-Id: Bug reports List-Archive: https://lists.freebsd.org/archives/freebsd-bugs List-Help: List-Post: List-Subscribe: List-Unsubscribe: Sender: owner-freebsd-bugs@freebsd.org MIME-Version: 1.0 ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=freebsd.org; s=dkim; t=1647602446; 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: in-reply-to:in-reply-to:references:references; bh=xlEV1//zfakXTT5P2KVd6DcajR9jZ7NLGp60EJoJNKo=; b=f/XuUuTZ3xhyppskmq+8IAxwB5BZrrn1t6nUZZX90jPAWKytHG+2ZXS3AAGGnvbrnqOOXB xHxv/Q+Cc7QN1U7/TmWr1muEvMGLocBUh5/59A2SOus9XJYP9EShML3/4AZy6RvpJfCeKW aYzbheCjFAe+ZpUWPl9ndAGV1YsvcTG+SReDfmH7DmjZ9Nb4g1Np3X5/CsRU48n0EczD4M 8BdXm6pFGn8wGFk5PT/Vs3x4rL9+hnpuSpo5/MsKLJyPt1eP9Wta4FHd0grpuNSZwxKSv1 1bxyqD8CoLCqOIZE8vWBSmuE7ubLIX7bQB4Bnov4Zyy8lgP+K2UtTuQE2Rs7VA== ARC-Seal: i=1; s=dkim; d=freebsd.org; t=1647602446; a=rsa-sha256; cv=none; b=OADdjca6d2vV9296nwn/RfoUzR6dzVKs7OwFQpPqNgoVGGOZV2fUGOodToTu1P96ops6AA lOdVA4hW5R1FMcvZEvOHfjQSCKWu2At6Njw7ZX4Pm2ja+wr/XZe+kB+Zz0q1MnkL8jQFWu TI1w4UzrsD3nYi+FZKQ0VfYglICsYxFB0iIkvROrN3B2gT3Uxt1o/rQQaSpggY1+aQFPb9 BplormTXQ5o5aR4yh0amyysF84++CAqqZFET7MXj0jfF5GjTkBCF46Yh9+ynujworgyInv dOolPi8zEUvnc13+MLO6kLaLVYtIuN8BY/l/UiYPRq7O6Vi5cay8Rlb4yo+Yrg== ARC-Authentication-Results: i=1; mx1.freebsd.org; none X-ThisMailContainsUnwantedMimeParts: N https://bugs.freebsd.org/bugzilla/show_bug.cgi?id=3D262633 --- Comment #1 from firk@cantconnect.ru --- What can be done: 1) disable racct - obviously not the case 2) rollback commit https://svnweb.freebsd.org/base?view=3Drevision&revision=3D221362 - seems a= lso not the case 3) disable jail renaming when racct enabled - personally I don't see any problems with this (I'm not sure if jail renaming ever used by someone) 4) add protective lock for prison->pr_prison_racct It will works, but I don't think it is good idea. Currently, only protect= ed proc->p_ucred needed to get related jail racct pointer. Requiring any additional locks to do this will make racct code more complicated. 5) very complicated jail-rename procedure, locking all processes inside bef= ore renaming and unlocking them after; this will lead to some performance loss,= but since jail renaming never used, nobody will notice it; I'm not sure if this= is needed --=20 You are receiving this mail because: You are the assignee for the bug.=