lkml.org 
[lkml]   [2019]   [Apr]   [5]   [last100]   RSS Feed
Views: [wrap][no wrap]   [headers]  [forward] 
 
Messages in this thread
/
Date
From
SubjectRe: [PATCH 1/3] x86/microcode/intel: Refactor Intel microcode blob loading
On Fri, 5 Apr 2019, Borislav Petkov wrote:

> From: Jann Horn <jannh@google.com>
>
> Change generic_load_microcode() to use the iov_iter API instead of a
> clumsy open-coded version which has to pay attention to __user data
> or kernel data, depending on the loading method. This allows to avoid
> explicit casting between user and kernel pointers.
>
> Because the iov_iter API makes it hard to read the same location twice,
> as a side effect, also fix a double-read of the microcode header (which
> could e.g. lead to out-of-bounds reads in microcode_sanity_check()).
>
> Not that it matters much, only root is allowed to load microcode
> anyway...

Nice!

Reviewed-by: Thomas Gleixner <tglx@linutronix.de>

\
 
 \ /
  Last update: 2019-04-06 00:01    [W:0.066 / U:51.740 seconds]
©2003-2018 Jasper Spaans|hosted at Digital Ocean and TransIP|Read the blog|Advertise on this site