summaryrefslogtreecommitdiff
path: root/lib/test_bitmap.c
diff options
context:
space:
mode:
authorJann Horn <jannh@google.com>2018-04-04 21:03:21 +0200
committerGreg Kroah-Hartman <gregkh@linuxfoundation.org>2018-05-22 18:53:57 +0200
commitbca7faea5410d50d2a3be4b11688f02a2fb2ee95 (patch)
tree093b493e04502d500fd1d0aeac804b88abd938ef /lib/test_bitmap.c
parent9a19a93bddb383548a04afaf40cec847de6296f8 (diff)
tee: shm: fix use-after-free via temporarily dropped reference
commit bb765d1c331f62b59049d35607ed2e365802bef9 upstream. Bump the file's refcount before moving the reference into the fd table, not afterwards. The old code could drop the file's refcount to zero for a short moment before calling get_file() via get_dma_buf(). This code can only be triggered on ARM systems that use Linaro's OP-TEE. Fixes: 967c9cca2cc5 ("tee: generic TEE subsystem") Signed-off-by: Jann Horn <jannh@google.com> Signed-off-by: Jens Wiklander <jens.wiklander@linaro.org> Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
Diffstat (limited to 'lib/test_bitmap.c')
0 files changed, 0 insertions, 0 deletions