]> rtime.felk.cvut.cz Git - linux-imx.git/commit
nfsd: fix auth_domain reference leak on nlm operations
authorJ. Bruce Fields <bfields@redhat.com>
Fri, 25 Mar 2011 02:51:14 +0000 (22:51 -0400)
committerAndi Kleen <ak@linux.intel.com>
Thu, 28 Apr 2011 15:21:00 +0000 (08:21 -0700)
commit6e7fd0751dea4c3472f0a1f7b58d0b1ea53fbd84
tree41561dacb156c2aa8d6eaf1b0e1b96ec5830754f
parent091bfbbc8a7da176d4553bff8e7d29736599017e
nfsd: fix auth_domain reference leak on nlm operations

commit 954032d2527f2fce7355ba70709b5e143d6b686f upstream.

This was noticed by users who performed more than 2^32 lock operations
and hence made this counter overflow (eventually leading to
use-after-free's).  Setting rq_client to NULL here means that it won't
later get auth_domain_put() when it should be.

Appears to have been introduced in 2.5.42 by "[PATCH] kNFSd: Move auth
domain lookup into svcauth" which moved most of the rq_client handling
to common svcauth code, but left behind this one line.

Cc: Neil Brown <neilb@suse.de>
Signed-off-by: J. Bruce Fields <bfields@redhat.com>
Signed-off-by: Greg Kroah-Hartman <gregkh@suse.de>
Signed-off-by: Andi Kleen <ak@linux.intel.com>
fs/nfsd/lockd.c