Bug 9879 - ls will list files even if it doesn't have permission
Summary: ls will list files even if it doesn't have permission
Alias: None
Product: Red Hat Linux
Classification: Retired
Component: fileutils   
(Show other bugs)
Version: 6.0
Hardware: i386
OS: Linux
Target Milestone: ---
Assignee: Bernhard Rosenkraenzer
QA Contact:
Keywords: Security
Depends On:
TreeView+ depends on / blocked
Reported: 2000-03-01 07:34 UTC by Stephen Rasku
Modified: 2008-05-01 15:37 UTC (History)
0 users

Fixed In Version:
Doc Type: Bug Fix
Doc Text:
Story Points: ---
Clone Of:
Last Closed: 2000-03-01 08:51:11 UTC
Type: ---
Regression: ---
Mount Type: ---
Documentation: ---
Verified Versions:
Category: ---
oVirt Team: ---
RHEL 7.3 requirements from Atomic Host:
Cloudforms Team: ---

Attachments (Terms of Use)

Description Stephen Rasku 2000-03-01 07:34:17 UTC
If a directory doesn't have execute permission it will still list its
contents, complaining about "Permission denied".  On Solaris 7, it will not
list the contents of a directory without execute permission.  This bug
allows a user to determine the files contained in directories that he has
no permission for.

Comment 1 Bernhard Rosenkraenzer 2000-03-01 08:51:59 UTC
Can't reproduce it here:

[bero@locutus bero] ls /root
ls: /root: Permission denied

The only filename I get is the directory I was trying to list, a name I've known

Comment 2 Stephen Rasku 2000-03-01 19:11:59 UTC
This will only occur if you have world read permissions but not world execute
permissions.  This is consistent with Solaris.  However, I am still curious why
you can display the filenames but not the file details (i.e. from ls -l).

Note You need to log in before you can comment on or make changes to this bug.