From: Chas Williams Date: Sun, 24 Apr 2005 15:03:24 +0000 (+0000) Subject: STABLE14-avoid-leaking-stat-info-20050424 X-Git-Tag: openafs-devel-1_3_82~32 X-Git-Url: https://git.michaelhowe.org/gitweb/?a=commitdiff_plain;h=006b64043f5f2ec9ba2e345ac6b90c246a52a406;p=packages%2Fo%2Fopenafs.git STABLE14-avoid-leaking-stat-info-20050424 otherwise we are effectively giving stat powers to people who shouldn't have it (cherry picked from commit 1ecb15494a769dad02d2278dbe50d34cab0cab05) --- diff --git a/src/afs/VNOPS/afs_vnop_lookup.c b/src/afs/VNOPS/afs_vnop_lookup.c index 229bba463..c82496a47 100644 --- a/src/afs/VNOPS/afs_vnop_lookup.c +++ b/src/afs/VNOPS/afs_vnop_lookup.c @@ -1198,7 +1198,7 @@ afs_lookup(OSI_VC_DECL(adp), char *aname, struct vcache **avcp, struct AFS_UCRED /* Check for read access as well. We need read access in order to * stat files, but not to stat subdirectories. */ - if (!afs_AccessOK(adp, PRSFS_LOOKUP, &treq, CHECK_MODE_BITS)) + if (!afs_AccessOK(adp, PRSFS_READ, &treq, CHECK_MODE_BITS)) no_read_access = 1; /* special case lookup of ".". Can we check for it sooner in this code,