lkml.org 
[lkml]   [2016]   [Nov]   [13]   [last100]   RSS Feed
Views: [wrap][no wrap]   [headers]  [forward] 
 
Messages in this thread
    Patch in this message
    /
    From
    Date
    Subject[PATCH 3.16 279/346] mips: copy_from_user() must zero the destination on access_ok() failure
    3.16.39-rc1 review patch.  If anyone has any objections, please let me know.

    ------------------

    From: Al Viro <viro@zeniv.linux.org.uk>

    commit e69d700535ac43a18032b3c399c69bf4639e89a2 upstream.

    Signed-off-by: Al Viro <viro@zeniv.linux.org.uk>
    Signed-off-by: Ben Hutchings <ben@decadent.org.uk>
    ---
    arch/mips/include/asm/uaccess.h | 3 +++
    1 file changed, 3 insertions(+)

    --- a/arch/mips/include/asm/uaccess.h
    +++ b/arch/mips/include/asm/uaccess.h
    @@ -14,6 +14,7 @@
    #include <linux/kernel.h>
    #include <linux/errno.h>
    #include <linux/thread_info.h>
    +#include <linux/string.h>
    #include <asm/asm-eva.h>

    /*
    @@ -1139,6 +1140,8 @@ extern size_t __copy_in_user_eva(void *_
    __cu_len = __invoke_copy_from_user(__cu_to, \
    __cu_from, \
    __cu_len); \
    + } else { \
    + memset(__cu_to, 0, __cu_len); \
    } \
    } \
    __cu_len; \
    \
     
     \ /
      Last update: 2016-11-14 03:48    [W:4.136 / U:0.060 seconds]
    ©2003-2020 Jasper Spaans|hosted at Digital Ocean and TransIP|Read the blog|Advertise on this site