lists.openwall.net   lists  /  announce  owl-users  owl-dev  john-users  john-dev  passwdqc-users  yescrypt  popa3d-users  /  oss-security  kernel-hardening  musl  sabotage  tlsify  passwords  /  crypt-dev  xvendor  /  Bugtraq  Full-Disclosure  linux-kernel  linux-netdev  linux-ext4  linux-hardening  linux-cve-announce  PHC 
Open Source and information security mailing list archives
 
Hash Suite: Windows password security audit tool. GUI, reports in PDF.
[<prev] [next>] [<thread-prev] [thread-next>] [day] [month] [year] [list]
Message-ID: <4ED3B118.50502@parallels.com>
Date:	Mon, 28 Nov 2011 20:04:40 +0400
From:	Pavel Emelyanov <xemul@...allels.com>
To:	Tejun Heo <tj@...nel.org>
CC:	Oleg Nesterov <oleg@...hat.com>,
	Andrew Morton <akpm@...ux-foundation.org>,
	Linux Kernel Mailing List <linux-kernel@...r.kernel.org>,
	Cyrill Gorcunov <gorcunov@...nvz.org>
Subject: Re: [PATCH] sysctl: Add the kernel.ns_last_pid control

On 11/28/2011 07:53 PM, Tejun Heo wrote:
> On Mon, Nov 28, 2011 at 07:21:25PM +0400, Pavel Emelyanov wrote:
>> +static int pid_ns_ctl_handler(struct ctl_table *table, int write,
>> +		void __user *buffer, size_t *lenp, loff_t *ppos)
>> +{
>> +	struct ctl_table tmp = *table;
>> +
>> +	if (write && !capable(CAP_SYS_ADMIN))
>> +		return -EPERM;
>> +
>> +	/*
>> +	 * Writing directly to ns' last_pid field is OK, since this field
>> +	 * is volatile in a living namespace anyway and a code writing to
>> +	 * it should synchronize its usage with external means.
>> +	 */
> 
> I would still prefer using set_last_pid() but if you insist to update
> last_pid directly, please note the direct update in the comment on top
> of set_last_pid() too.

It's already there in this patch.

> Other than that,
> 
>   Acked-by: Tejun Heo <tj@...nel.org>

Thanks!

> Thanks.
> 

--
To unsubscribe from this list: send the line "unsubscribe linux-kernel" in
the body of a message to majordomo@...r.kernel.org
More majordomo info at  http://vger.kernel.org/majordomo-info.html
Please read the FAQ at  http://www.tux.org/lkml/

Powered by blists - more mailing lists

Powered by Openwall GNU/*/Linux Powered by OpenVZ