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, 9 Jan 2020 16:45:22 +0800
From:   "Wangshaobo (bobo)" <bobo.shaobowang@...wei.com>
To:     Dominik Brodowski <linux@...inikbrodowski.net>
CC:     <mark.rutland@....com>, <hch@...radead.org>,
        <cj.chengjian@...wei.com>, <huawei.libin@...wei.com>,
        <xiexiuqi@...wei.com>, <yangyingliang@...wei.com>,
        <guohanjun@...wei.com>, <wcohen@...hat.com>,
        <linux-kernel@...r.kernel.org>, <mtk.manpages@...il.com>,
        <wezhang@...hat.com>
Subject: Re: [PATCH] sys_personality: Add a optional arch hook
 arch_check_personality() for common sys_personality()

Thanks for your reply, I wiil send it in version 2

Thanks,

             wangshaobo

在 2020/1/9 14:54, Dominik Brodowski 写道:
> On Thu, Jan 09, 2020 at 09:38:46AM +0800, Wang ShaoBo wrote:
>> currently arm64 use __arm64_sys_arm64_personality() as its default
>> syscall. But using a normal hook arch_check_personality() can reject
>> personality settings for special case of different archs.
> Thanks for your patch!
>
>>   SYSCALL_DEFINE1(personality, unsigned int, personality)
>>   {
>> -	unsigned int old = current->personality;
>> +	int check;
>>   
>> -	if (personality != 0xffffffff)
>> -		set_personality(personality);
>> +	check = arch_check_personality(personality);
>> +	if (check)
>> +		return check;
>>   
>> -	return old;
>> +	return ksys_personality(personality);
>>   }
> Please leave the default check and call to set_personality()
> in here and remove the now-unneeded ksys_personality() from
> include/linux/syscalls.h
>
> Thanks,
> 	Dominik
>
> .

Powered by blists - more mailing lists

Powered by Openwall GNU/*/Linux Powered by OpenVZ