• M
    ima: prevent a file already mmap'ed write to be mmap'ed execute · 2cd4737b
    Mimi Zohar 提交于
    The kernel calls deny_write_access() to prevent a file already opened
    for write from being executed and also prevents files being executed
    from being opened for write.  For some reason this does not extend to
    files being mmap'ed execute.
    
    From an IMA perspective, measuring/appraising the integrity of a file
    being mmap'ed shared execute, without first making sure the file cannot
    be modified, makes no sense.  This patch prevents files, in policy,
    already mmap'ed shared write, from being mmap'ed execute.
    Signed-off-by: NMimi Zohar <zohar@linux.ibm.com>
    2cd4737b
ima_main.c 17.5 KB