Uploaded image for project: 'Apache Arrow'
  1. Apache Arrow
  2. ARROW-16753

[C++] LocalFileSystem cannot list Linux directory recursively when permission to subdirectory contents are denied

Add voteWatch issue
    XMLWordPrintableJSON

Details

    • Bug
    • Status: In Progress
    • Major
    • Resolution: Unresolved
    • 6.0.1
    • None
    • C++
    • Ubuntu 20.04 LTS

    Description

      The following code to list my root directory fails:

       

      FileSelector file_selector;
      file_selector.base_dir = "/";
      file_selector.allow_not_found = true;
      file_selector.recursive = true;
      auto result = fs.GetFileInfo(file_selector);

      The result.ok() value returns false, and then result.status().message() returns Cannot list directory '/var/run/wpa_supplicant'.

      An examination of the /run directory (which /var/run symlinks to) shows:

       

      $ ls -al /run
      drwxr-xr-x 35 root              root  1040 Jun  6 06:11 .
      drwxr-xr-x 20 root              root  4096 May 20 12:42 ..
      ...
      drwxr-x---  2 root              root    60 Jun  4 12:14 wpa_supplicant

      And then attempting to list this directory reveals:

       

      $ ls -al /run/wpa_supplicant/
      ls: cannot open directory '/run/wpa_supplicant/': Permission denied

       

      As a user of LocalFileSystem, I should be able to list all of the files that I have access to.

       

       

      Attachments

        Issue Links

          Activity

            People

              Unassigned Unassigned
              drauschenbach David Rauschenbach

              Dates

                Created:
                Updated:

                Time Tracking

                  Estimated:
                  Original Estimate - Not Specified
                  Not Specified
                  Remaining:
                  Remaining Estimate - 0h
                  0h
                  Logged:
                  Time Spent - 50m
                  50m

                  Slack

                    Issue deployment