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] [day] [month] [year] [list]
Date:   Thu, 2 Feb 2017 13:12:27 -0500
From:   Chris Metcalf <cmetcalf@...lanox.com>
To:     Eugene Syromiatnikov <esyr@...hat.com>,
        <linux-kernel@...r.kernel.org>
CC:     Frederic Weisbecker <fweisbec@...il.com>
Subject: Re: [PATCH v15 04/13] task_isolation: add initial support

On 2/2/2017 11:13 AM, Eugene Syromiatnikov wrote:
>>   	case PR_GET_FP_MODE:
>>   		error = GET_FP_MODE(me);
>>   		break;
>> +#ifdef CONFIG_TASK_ISOLATION
>> +	case PR_SET_TASK_ISOLATION:
>> +		error = task_isolation_set(arg2);
>> +		break;
>> +	case PR_GET_TASK_ISOLATION:
>> +		error = me->task_isolation_flags;
>> +		break;
>> +#endif
>>   	default:
>>   		error = -EINVAL;
>>   		break;
> It is not a very good idea to ignore the values of unused arguments; it
> prevents future their usage, as user space can pass some garbage values
> here. Check out the code for newer prctl handlers, like
> PR_SET_NO_NEW_PRIVS, PR_SET_THP_DISABLE, or PR_MPX_ENABLE_MANAGEMENT
> (PR_[SG]_FP_MODE is an unfortunate recent omission).
>
> The other thing is the usage of #ifdef's, which is generally avoided
> there. Also, the patch for man-pages, describing the new prctl calls, is
> missing.

Thanks, I appreciate the feedback.  I'll fold this into the next spin of the series!

-- 
Chris Metcalf, Mellanox Technologies
http://www.mellanox.com

Powered by blists - more mailing lists

Powered by Openwall GNU/*/Linux Powered by OpenVZ