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: <CAMzpN2joOga7x+wF7EzOVYq_OLr6JmKm-K8f4koLrTZAQ7pY1A@mail.gmail.com>
Date:	Thu, 16 Jul 2015 12:02:06 -0400
From:	Brian Gerst <brgerst@...il.com>
To:	Andy Lutomirski <luto@...capital.net>
Cc:	X86 ML <x86@...nel.org>,
	"linux-kernel@...r.kernel.org" <linux-kernel@...r.kernel.org>,
	Ingo Molnar <mingo@...nel.org>,
	"H. Peter Anvin" <hpa@...or.com>,
	Denys Vlasenko <dvlasenk@...hat.com>,
	Linus Torvalds <torvalds@...ux-foundation.org>
Subject: Re: [PATCH 3/7] x86/vm86: Move userspace accesses to do_sys_vm86()

On Thu, Jul 16, 2015 at 11:42 AM, Andy Lutomirski <luto@...capital.net> wrote:
> On Thu, Jul 16, 2015 at 4:46 AM, Brian Gerst <brgerst@...il.com> wrote:
>> Move the userspace accesses down into the common function in
>> preparation for the next set of patches.
>
> Nice!
>
> Could you improve the changelog a bit? You're really changing the way
> it works (in a good way).
>
>
>> -       set_flags(regs->pt.flags, VEFLAGS, X86_EFLAGS_VIF | current->thread.v86mask);
>> -       tmp = copy_vm86_regs_to_user(&current->thread.vm86_info->regs, regs);
>> -       tmp += put_user(current->thread.screen_bitmap, &current->thread.vm86_info->screen_bitmap);
>> -       if (tmp) {
>> +       set_flags(regs->pt.flags, VEFLAGS, X86_EFLAGS_VIF | tsk->thread.v86mask);
>> +       user = tsk->thread.vm86_info;
>> +       put_user_try {
>
> I think that put_user_try/put_user_ex requires access_ok.
>
>
>> +       get_user_try {
>> +               unsigned short seg;
>
> This also needs access_ok, I think.

Good catch.  I modeled this off restore_sigcontext(), but the
access_ok() is actually in the caller.

--
Brian Gerst
--
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