Uploaded image for project: 'Hadoop Common'
  1. Hadoop Common
  2. HADOOP-14820

Wasb mkdirs security checks inconsistent with HDFS

    XMLWordPrintableJSON

Details

    Description

      No authorization checks should be made when a user tries to create (mkdirs -p) an existing folder hierarchy.

      For example, if we start with /home/hdiuser/prefix pre-created, and do the following operations, the results should be as shown below.

      hdiuser@hn0-0d2f67:~$ sudo chown root:root prefix
      hdiuser@hn0-0d2f67:~$ sudo chmod 555 prefix
      
      hdiuser@hn0-0d2f67:~$ ls -l
      dr-xr-xr-x 3 root    root      4096 Aug 29 08:25 prefix
      
      hdiuser@hn0-0d2f67:~$ mkdir -p /home
      hdiuser@hn0-0d2f67:~$ mkdir -p /home/hdiuser
      hdiuser@hn0-0d2f67:~$ mkdir -p /home/hdiuser/prefix
      hdiuser@hn0-0d2f67:~$ mkdir -p /home/hdiuser/prefix/1
      mkdir: cannot create directory â/home/hdiuser/prefix/1â: Permission denied
      The first three mkdirs succeed, because the ancestor is already present. The fourth one fails because of a permission check against the (shorter) ancestor (as compared to the path being created).
      

      Attachments

        1. HADOOP-14820.001.patch
          5 kB
          Sivaguru Sankaridurg
        2. HADOOP-14820.002.patch
          5 kB
          Sivaguru Sankaridurg
        3. HADOOP-14820.003.patch
          5 kB
          Sivaguru Sankaridurg
        4. HADOOP-14820.004.patch
          5 kB
          Sivaguru Sankaridurg
        5. HADOOP-14820.005.patch
          6 kB
          Sivaguru Sankaridurg
        6. HADOOP-14820-006.patch
          6 kB
          Steve Loughran
        7. HADOOP-14820-007.patch
          6 kB
          Steve Loughran
        8. HADOOP-14820-branch-2-001.patch.txt
          6 kB
          Sivaguru Sankaridurg

        Activity

          People

            sisankar@microsoft.com Sivaguru Sankaridurg
            sisankar@microsoft.com Sivaguru Sankaridurg
            Votes:
            0 Vote for this issue
            Watchers:
            5 Start watching this issue

            Dates

              Created:
              Updated:
              Resolved: