diff options
author | Mimi Zohar <zohar@linux.vnet.ibm.com> | 2017-01-17 11:45:41 (GMT) |
---|---|---|
committer | Greg Kroah-Hartman <gregkh@linuxfoundation.org> | 2017-03-12 05:41:44 (GMT) |
commit | d9cc31683a16f5619217d80c3d8e608c23c41afc (patch) | |
tree | 68115d5b3adbcaf99f291bc20efe5906ae44ed9e /drivers/pnp/driver.c | |
parent | 270e84a1e6effd6c0c6e9b13b196b5fdaa392954 (diff) | |
download | linux-d9cc31683a16f5619217d80c3d8e608c23c41afc.tar.xz |
ima: fix ima_d_path() possible race with rename
commit bc15ed663e7e53ee4dc3e60f8d09c93a0528c694 upstream.
On failure to return a pathname from ima_d_path(), a pointer to
dname is returned, which is subsequently used in the IMA measurement
list, the IMA audit records, and other audit logging. Saving the
pointer to dname for later use has the potential to race with rename.
Intead of returning a pointer to dname on failure, this patch returns
a pointer to a copy of the filename.
Reported-by: Al Viro <viro@zeniv.linux.org.uk>
Signed-off-by: Mimi Zohar <zohar@linux.vnet.ibm.com>
Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
Diffstat (limited to 'drivers/pnp/driver.c')
0 files changed, 0 insertions, 0 deletions