Commit 7397906
committed
prlimit: do_prlimit needs to have a speculation check
do_prlimit() adds the user-controlled resource value to a pointer that
will subsequently be dereferenced. In order to help prevent this
codepath from being used as a spectre "gadget" a barrier needs to be
added after checking the range.
Reported-by: Jordy Zomer <[email protected]>
Tested-by: Jordy Zomer <[email protected]>
Suggested-by: Linus Torvalds <[email protected]>
Signed-off-by: Greg Kroah-Hartman <[email protected]>1 parent 9be182d commit 7397906
1 file changed
+2
-0
lines changed| Original file line number | Diff line number | Diff line change | |
|---|---|---|---|
| |||
1442 | 1442 | | |
1443 | 1443 | | |
1444 | 1444 | | |
| 1445 | + | |
| 1446 | + | |
1445 | 1447 | | |
1446 | 1448 | | |
1447 | 1449 | | |
| |||
0 commit comments