[BUG] fs/notify/mark: A potential use after free in fsnotify_put_mark_wake

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

 



Hi,
    My static analyzer tool reported a use after free in fsnotify_put_mark_wake
of the file: fs/notify/mark.c.

In fsnotify_put_mark_wake, it calls fsnotify_put_mark(mark). Inside the function
fsnotify_put_mark(), if conn is NULL, it will call fsnotify_final_mark_destroy(mark)
to free mark->group by fsnotify_put_group(group) and return. I also had inspected
the implementation of fsnotify_put_group() and found that there is no cleanup operation
about group->user_waits.

But after fsnotify_put_mark_wake() returned, mark->group is still used by 
if (atomic_dec_and_test(&group->user_waits) && group->shutdown) and later.

Is this an issue?

Thanks.








[Index of Archives]     [Linux Ext4 Filesystem]     [Union Filesystem]     [Filesystem Testing]     [Ceph Users]     [Ecryptfs]     [AutoFS]     [Kernel Newbies]     [Share Photos]     [Security]     [Netfilter]     [Bugtraq]     [Yosemite News]     [MIPS Linux]     [ARM Linux]     [Linux Security]     [Linux Cachefs]     [Reiser Filesystem]     [Linux RAID]     [Samba]     [Device Mapper]     [CEPH Development]

  Powered by Linux