Justin Rittenhouse created NIFI-6131:
----------------------------------------

             Summary: MergeContent is not properly storing file permissions 
from tar.permissions
                 Key: NIFI-6131
                 URL: https://issues.apache.org/jira/browse/NIFI-6131
             Project: Apache NiFi
          Issue Type: Bug
          Components: Extensions
    Affects Versions: 1.9.0
            Reporter: Justin Rittenhouse


* GetFile retrieves files, with permissions stored in file.permissions in "rwx" 
format
 * UpdateAttribute converts rwx to digits and stores in tar.permissions via the 
following:
 ** 
${file.permissions:replaceAll('rwx','7'):replaceAll('rw-','6'):replaceAll('r-x','5'):replaceAll('r--','4'):replaceAll('-wx','3'):replaceAll('-w-','2'):replaceAll('–x','1'):replaceAll('—','0')}
 * MergeContent creates tar file, reading tar.permissions
 * Download and extract files from tarball
 * Check permissions against incoming files
 ** Permissions do not match, for example:
 *** -rwxrwx--- becomes -r------wT
 *** -rwxr-xr-x becomes --wxrw–wt
 *** -rw-rw-r-- becomes --w–wx–T
 *** -rw------- becomes ---x-wx–T
 *** -rw-r--r-- becomes --w----r-T
 *** -rwxrwxr-x becomes -r-----rwt
 *** -rwxr-xr-x becomes --wxrw–wt
 * Have tried pre-pending a leading 0, which also does not work.



--
This message was sent by Atlassian JIRA
(v7.6.3#76005)

Reply via email to