Return-Path: Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S1757601AbYCUBRB (ORCPT ); Thu, 20 Mar 2008 21:17:01 -0400 Received: (majordomo@vger.kernel.org) by vger.kernel.org id S1752475AbYCUBQv (ORCPT ); Thu, 20 Mar 2008 21:16:51 -0400 Received: from x346.tv-sign.ru ([89.108.83.215]:46349 "EHLO mail.screens.ru" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S1752267AbYCUBQu (ORCPT ); Thu, 20 Mar 2008 21:16:50 -0400 Date: Fri, 21 Mar 2008 04:15:54 +0300 From: Oleg Nesterov To: Pavel Machek Cc: Andrew Morton , Davide Libenzi , "Eric W. Biederman" , Ingo Molnar , Laurent Riffard , Pavel Emelyanov , Roland McGrath , linux-kernel@vger.kernel.org Subject: Re: [PATCH 5/5] ptrace: it is fun to strace /sbin/init Message-ID: <20080321011554.GA121@tv-sign.ru> References: <20080316155455.GA20848@tv-sign.ru> <20080320162718.GA4397@ucw.cz> <20080320165756.GA11197@tv-sign.ru> <20080320232503.GG17431@elf.ucw.cz> Mime-Version: 1.0 Content-Type: text/plain; charset=us-ascii Content-Disposition: inline In-Reply-To: <20080320232503.GG17431@elf.ucw.cz> User-Agent: Mutt/1.5.11 Sender: linux-kernel-owner@vger.kernel.org List-ID: X-Mailing-List: linux-kernel@vger.kernel.org Content-Length: 1619 Lines: 46 On 03/21, Pavel Machek wrote: > > On Thu 2008-03-20 19:57:56, Oleg Nesterov wrote: > > On 03/20, Pavel Machek wrote: > > > > > > > Ptracing of /sbin/init is not allowed. Of course, this is very dangerous, but > > > > may be useful. Introduce the kernel boot parameter to allow this. > > > ... > > > > @@ -803,6 +803,8 @@ and is between 256 and 4096 characters. > > > > Run specified binary instead of /sbin/init as init > > > > process. > > > > > > > > + init_ptrace [KNL] Allows to ptrace init. Very dangerous. Don't use. > > > > + > > > > > > I don't know what ptracing init is good for, and I believe people > > > wanting to do this kind of special stuff can patch their own kernel... > > > > Yes sure. But could you explain why this can be bad given that ptracing > > init needs the explicit boot parameter? IOW, could you explain why you > > don't like this small and trivial change which adds a minimal impact? > > "It can't be bad, its optional". > > It is bad exactly _because_ it is optional. Anything that adds boot > parameter is *not* trivial... You are right. I'd prefer to make /sbin/init ptraceable unconditionally, the root should know what it does. But this will change the historical behaviour. > Why not add > > please_randomly_corrupt_memory boot parameter? It may be useful for > something... > Pavel Nice argument. Oleg. -- To unsubscribe from this list: send the line "unsubscribe linux-kernel" in the body of a message to majordomo@vger.kernel.org More majordomo info at http://vger.kernel.org/majordomo-info.html Please read the FAQ at http://www.tux.org/lkml/