From: David Howells Date: Mon, 5 Jan 2009 17:19:37 +0000 (+0000) Subject: CRED: Fix NFSD regression X-Git-Tag: v2.6.29-rc1~177^2~11 X-Git-Url: http://git.openpandora.org/cgi-bin/gitweb.cgi?a=commitdiff_plain;h=f05ef8db1abe68e3f6fc272efee51bc54ce528c5;p=pandora-kernel.git CRED: Fix NFSD regression Fix a regression in NFSD's permission checking introduced by the credentials patches. There are two parts to the problem, both in nfsd_setuser(): (1) The return value of set_groups() is -ve if in error, not 0, and should be checked appropriately. 0 indicates success. (2) The UID to use for fs accesses is in new->fsuid, not new->uid (which is 0). This causes CAP_DAC_OVERRIDE to always be set, rather than being cleared if the UID is anything other than 0 after squashing. Reported-by: J. Bruce Fields Signed-off-by: David Howells Acked-by: James Morris Signed-off-by: J. Bruce Fields --- Reading git-diff-tree failed