Groups | Search | Server Info | Keyboard shortcuts | Login | Register [http] [https] [nntp] [nntps]
Groups > linux.kernel > #1210664
| From | "H. Peter Anvin" <hpa@zytor.com> |
|---|---|
| Newsgroups | linux.kernel |
| Subject | Re: [x86] copy_from{to}_user question |
| Date | 2015-08-20 20:30 +0200 |
| Message-ID | <pZCL8-4sw-19@gated-at.bofh.it> (permalink) |
| References | (1 earlier) <pWB8R-1df-5@gated-at.bofh.it> <pWXCq-7m-3@gated-at.bofh.it> <pX3Rw-w6-7@gated-at.bofh.it> <pYjhw-3w8-7@gated-at.bofh.it> <pYk3U-4GK-3@gated-at.bofh.it> |
| Organization | linux.* mail to news gateway |
On 08/16/2015 09:16 PM, Borislav Petkov wrote:
> On Mon, Aug 17, 2015 at 11:27:01AM +0800, yalin wang wrote:
>> i just want the x86 copy_from{to,in}_user() function have
>> the same behaviour as other platforms.
>
> Back to the original question from 2 mails ago:
>
> How else would we be able to use the same function in copy_to and
> copy_from variants?
>
>> and can disclose potential BUGs in kernel, if do like this.
>
> Back to my other question:
>
> Do you have any real life examples where you can trigger such bugs or is
> this only "potential"?
>
> IOW, what I *think* you're trying to do sounds to me like unnecessary
> complication with no apparent gain *at* *all*. So show me why you want
> to do it: code it up, trigger a bug and show me why your version is
> better. No "but but it might be a good idea", no "potentially maybe",
> none of that maybe stuff. Write it, send it with instructions how
> someone else can apply it and trigger the issue. Ok?
>
There is a valid reason to do this, which is that currently
copy_{to,from}_user() effectively bypass SMAP as they don't verify that
the kernel pointer is actually a kernel pointer.
The /proc/kcore issue is a completely different ball of wax, however.
-hpa
--
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/
Back to linux.kernel | Previous | Next — Next in thread | Find similar | Unroll thread
Re: [x86] copy_from{to}_user question "H. Peter Anvin" <hpa@zytor.com> - 2015-08-20 20:30 +0200
Re: [x86] copy_from{to}_user question Borislav Petkov <bp@suse.de> - 2015-08-21 06:40 +0200
Re: [x86] copy_from{to}_user question "H. Peter Anvin" <hpa@zytor.com> - 2015-08-21 23:10 +0200
Re: [x86] copy_from{to}_user question Borislav Petkov <bp@suse.de> - 2015-08-22 11:10 +0200
Re: [x86] copy_from{to}_user question yalin wang <yalin.wang2010@gmail.com> - 2015-08-24 10:00 +0200
Re: [x86] copy_from{to}_user question Jeff Epler <jepler@unpythonic.net> - 2015-08-24 14:10 +0200
csiph-web