• Ryusuke Konishi's avatar
    nilfs2: check size of array structured data exchanged via ioctls · 83aca8f4
    Ryusuke Konishi authored
    Although some ioctls of nilfs2 exchange data in the form of indirectly
    referenced array, some of them lack size check on the array elements.
    
    This inserts the missing checks and rejects requests if data of ioctl
    does not have a valid format.
    
    We usually don't have to check size of structures that we associated
    with ioctl commands because the size is tested implicitly for
    identifying ioctl command; the checks this patch adds are for the
    cases where the implicit check is not applied.
    Signed-off-by: default avatarRyusuke Konishi <konishi.ryusuke@lab.ntt.co.jp>
    83aca8f4
ioctl.c 16.6 KB