From owner-freebsd-security@freebsd.org Wed Aug 16 13:46:19 2017 Return-Path: Delivered-To: freebsd-security@mailman.ysv.freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2001:1900:2254:206a::19:1]) by mailman.ysv.freebsd.org (Postfix) with ESMTP id 9BA1ADDCAB8 for ; Wed, 16 Aug 2017 13:46:19 +0000 (UTC) (envelope-from freebsd.lists@whitewinterwolf.com) Received: from relay3-d.mail.gandi.net (relay3-d.mail.gandi.net [IPv6:2001:4b98:c:538::195]) (using TLSv1.2 with cipher ECDHE-RSA-AES256-GCM-SHA384 (256/256 bits)) (Client did not present a certificate) by mx1.freebsd.org (Postfix) with ESMTPS id 6BA9D84025 for ; Wed, 16 Aug 2017 13:46:19 +0000 (UTC) (envelope-from freebsd.lists@whitewinterwolf.com) X-Originating-IP: 93.26.153.77 Received: from [10.137.2.15] (77.153.26.93.rev.sfr.net [93.26.153.77]) (Authenticated sender: lists@whitewinterwolf.com) by relay3-d.mail.gandi.net (Postfix) with ESMTPSA id 3955FA80D3 for ; Wed, 16 Aug 2017 15:46:18 +0200 (CEST) To: freebsd-security@freebsd.org From: "WhiteWinterWolf (Simon)" Subject: FreeBSD <= 10.3 jail SHM hole Message-ID: Date: Wed, 16 Aug 2017 15:46:16 +0200 User-Agent: Mozilla/5.0 (X11; Linux x86_64; rv:52.0) Gecko/20100101 Thunderbird/52.2.1 MIME-Version: 1.0 Content-Type: text/plain; charset=utf-8; format=flowed Content-Language: en-US Content-Transfer-Encoding: 7bit X-BeenThere: freebsd-security@freebsd.org X-Mailman-Version: 2.1.23 Precedence: list List-Id: "Security issues \[members-only posting\]" List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Wed, 16 Aug 2017 13:46:19 -0000 AFFECTED PRODUCTS This issue affects FreeBSD from 7.0 to 10.3 included. DESCRIPTION FreeBSD jail incompletely protects the access to the IPC primitives. The 'allow.sysvipc' setting only affects IPC queues, leaving other IPC objects unprotected, making them reachable system-wide independently of the system configuration. This creates two main weaknesses: - An attacker able to execute commands in one jail can attack processes located outside of the jail by directly accessing their IPC objects. - An attacker can create a bi-directional covert-channel between two otherwise isolated jails. MITIGATION There is no mitigation measure available on vulnerable systems. This issue is fixed in FreeBSD 11.0, the fix is also planned in the upcoming FreeBSD 10.4 (the fix is already committed to the FreeBSD STABLE branch, the release is currently scheduled for October, 2017). There is no fix planned for FreeBSD 10.3. If you are relying on FreeBSD jail for security purposes, I recommend to upgrade to a fixed version. REFERENCES Details + POC: https://www.whitewinterwolf.com/posts/2017/08/02/freebsd-jail-shm-hole/