NetLabel: fix a cache race condition
Testing revealed a problem with the NetLabel cache where a cached entry could be freed while in use by the LSM layer causing an oops and other problems. This patch fixes that problem by introducing a reference counter to the cache entry so that it is only freed when it is no longer in use. Signed-off-by:Paul Moore <paul.moore@hp.com> Signed-off-by:
James Morris <jmorris@namei.org>
Showing
- include/net/netlabel.h 47 additions, 15 deletionsinclude/net/netlabel.h
- net/ipv4/cipso_ipv4.c 10 additions, 8 deletionsnet/ipv4/cipso_ipv4.c
- net/netlabel/netlabel_kapi.c 1 addition, 1 deletionnet/netlabel/netlabel_kapi.c
- security/selinux/ss/services.c 21 additions, 16 deletionssecurity/selinux/ss/services.c
Loading
Please register or sign in to comment