From owner-freebsd-questions@freebsd.org Wed Sep 2 19:32:31 2015 Return-Path: Delivered-To: freebsd-questions@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 EF78F9C85C6 for ; Wed, 2 Sep 2015 19:32:30 +0000 (UTC) (envelope-from kozlov.sergey.404@gmail.com) Received: from mail-la0-x22f.google.com (mail-la0-x22f.google.com [IPv6:2a00:1450:4010:c03::22f]) (using TLSv1.2 with cipher ECDHE-RSA-AES128-GCM-SHA256 (128/128 bits)) (Client CN "smtp.gmail.com", Issuer "Google Internet Authority G2" (verified OK)) by mx1.freebsd.org (Postfix) with ESMTPS id 73918F00 for ; Wed, 2 Sep 2015 19:32:30 +0000 (UTC) (envelope-from kozlov.sergey.404@gmail.com) Received: by laeb10 with SMTP id b10so14550715lae.1 for ; Wed, 02 Sep 2015 12:32:28 -0700 (PDT) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=gmail.com; s=20120113; h=subject:to:references:from:message-id:date:user-agent:mime-version :in-reply-to:content-type:content-transfer-encoding; bh=UBNvS3p4OVqdHXkCzlVUglBOFzUyEY9uOud1/nSX7DM=; b=NFoDG2HFdyBjSNVQ/CzvbAhy965N9xgimEm0SnUUUs6yyDAUyKZ2jg9Nf2+7zOf7F6 7mdUQw3fK6O2ez7j3QDEJcjkVlBf0obBoedZRn+q6ClFUhfqLcjV8xdfVakKSkWsA6Zo cTshzmYF0HxpghpWpXWRTSAWDaETF8nbY2wq+8JyA3fNRNmQmGdXOzR0rhWFA0gB97V/ oI7YqWFZmc8ytS2480SdJm1w43MZu8a2CHtSXi5kTtkFSVK8iLp0JY8I39ugImpk6yuq wmj34Fq9XnlJDWKgYDSfnH5MQV+hK4NQGDD0HIKSjiZ0+yi47wfGVgc6UliPE/vxFS74 RogQ== X-Received: by 10.152.178.165 with SMTP id cz5mr11005318lac.29.1441222348423; Wed, 02 Sep 2015 12:32:28 -0700 (PDT) Received: from [192.168.210.11] (89-71-237-249.dynamic.chello.pl. [89.71.237.249]) by smtp.googlemail.com with ESMTPSA id nv3sm5765440lbb.24.2015.09.02.12.32.27 for (version=TLSv1.2 cipher=ECDHE-RSA-AES128-GCM-SHA256 bits=128/128); Wed, 02 Sep 2015 12:32:27 -0700 (PDT) Subject: Re: Jail causes host to reboot To: freebsd-questions@freebsd.org References: <55E6E26A.1040706@kulturflatrate.net> <55E704D4.2050607@kulturflatrate.net> From: Kozlov Sergey X-Enigmail-Draft-Status: N1110 Message-ID: <55E74EC9.1060803@gmail.com> Date: Wed, 2 Sep 2015 21:32:25 +0200 User-Agent: Mozilla/5.0 (Windows NT 6.1; WOW64; rv:38.0) Gecko/20100101 Thunderbird/38.2.0 MIME-Version: 1.0 In-Reply-To: Content-Type: text/plain; charset=windows-1252 Content-Transfer-Encoding: 7bit X-BeenThere: freebsd-questions@freebsd.org X-Mailman-Version: 2.1.20 Precedence: list List-Id: User questions List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Wed, 02 Sep 2015 19:32:31 -0000 Hello Anyways, any userspace program should not be able to crash the kernel, so if you don't use self-modified OS and you're sure that everything is ok with your hardware, you should really consider adding a bug to Regards, Sergey Kozlov On 02.09.2015 17:11, Adam Vande More wrote: > On Wed, Sep 2, 2015 at 9:16 AM, Niklaas Baudet von Gersdorff < > niklaas@kulturflatrate.net> wrote: > >> On 02/09/15 15:56, Adam Vande More wrote: >> >> Thanks for this clarification. >> >> So, in case someone is able to get access to a jail and causes a kernel >> panic, the person can compromise the entire host system? >> > Yes, depending on configuration. It's trivial to make a jail insecure. > The trick is to make a jail secure and fully functional for your needs. > > >> I doubt that it is possible but you saying "depending on configuration" >> brought up the following question: Is there a way to tell the host >> system to only shut down the jail (and maybe send an email to me) in >> case the jail causes a panic and not reboot the entire system? >> > The host and jails use the same kernel, so if there's a panic it all goes > down. A separate monitoring and alerting platform is the only reliable way > I know to get emails if something goes down. > > Am I right that the only way to prevent such failure is virtualising an >> entire operating system instead of using a jail? >> > Yes, but virtualizing is a loaded term. Some people don't consider jails > as virtualization. I do, at least from a certain point of view. > Especially now since independent FS's and network stacks can be involved. > Then you have types like container eg OpenVZ(there was FreeBSD version of > this floating around on 9.x, not sure what happened to it). The guest in > container's have independent kernels so the host would survive in my > original scenario. Same w/ other virtualization types like KVM, bhyve, > VBox, Xen, etc. > >