Skip to content

Commit

Permalink
selinux: remove load size limit
Browse files Browse the repository at this point in the history
Load size was limited to 64MB, this was legacy limitation due to vmalloc()
which was removed a while ago.

Signed-off-by: zhanglin <[email protected]>
[PM: removed comments in the description about 'real world use cases']
Signed-off-by: Paul Moore <[email protected]>
  • Loading branch information
zhanglin authored and pcmoore committed Oct 1, 2019
1 parent 54ecb8f commit e40642d
Showing 1 changed file with 0 additions and 4 deletions.
4 changes: 0 additions & 4 deletions security/selinux/selinuxfs.c
Original file line number Diff line number Diff line change
Expand Up @@ -548,10 +548,6 @@ static ssize_t sel_write_load(struct file *file, const char __user *buf,
if (*ppos != 0)
goto out;

length = -EFBIG;
if (count > 64 * 1024 * 1024)
goto out;

length = -ENOMEM;
data = vmalloc(count);
if (!data)
Expand Down

0 comments on commit e40642d

Please sign in to comment.