Changeset 7087


Ignore:
Timestamp:
08/21/12 17:25:39 (7 years ago)
Author:
eduardow
Message:

Ticket #3053 - Ralizado atualização de permissões IMAP para mover/excluir.

File:
1 edited

Legend:

Unmodified
Added
Removed
  • branches/2.4/expressoMail1_2/inc/class.imap_functions.inc.php

    r7086 r7087  
    21492149                    $acl = $this->getacltouser($folder, isset($params['decoded']));  
    21502150                    /*  
    2151                      * l - lookup - Mailbox is visible in mailbox list. Mailbox can be subscribed to.  
    2152                      * r - read - Mailbox can be opened for reading.  
    2153                      * w - write - Message flags and keywords can be changed, except \Seen and \Deleted  
    2154                      * s - write-seen - \Seen flag can be changed  
    2155                      * t - write-deleted - \Deleted flag can be changed  
    2156                      * i - insert - Messages can be written or copied to the mailbox  
    2157                      * p - post - Messages can be posted to the mailbox by LDA, e.g. from Sieve scripts  
    2158                      * e - expunge - Messages can be expunged  
    2159                      * k - create - Mailboxes can be created (or renamed) directly under this mailbox (but not necessarily under its children, see ACL Inheritance section above) (renaming also requires delete rights)  
    2160                      * x - delete - Mailbox can be deleted  
    2161                      * a - admin - Administration rights to the mailbox (currently: ability to change ACLs for mailbox)   
     2151                     * l - lookup (mailbox is visible to LIST/LSUB commands, SUBSCRIBE mailbox)  
     2152                 * r - read (SELECT the mailbox, perform STATUS)  
     2153                 * s - keep seen/unseen information across sessions (set or clear \SEEN flag via STORE, also set \SEEN during APPEND/COPY/        FETCH BODY[...])  
     2154                 * w - write (set or clear flags other than \SEEN and \DELETED via STORE, also set them during APPEND/COPY)  
     2155                 * i - insert (perform APPEND, COPY into mailbox)  
     2156                 * p - post (send mail to submission address for mailbox, not enforced by IMAP4 itself)  
     2157                 * k - create mailboxes (CREATE new sub-mailboxes in any implementation-defined hierarchy, parent mailbox for the new mailbox name in RENAME)  
     2158                 * x - delete mailbox (DELETE mailbox, old mailbox name in RENAME)  
     2159                 * t - delete messages (set or clear \DELETED flag via STORE, set \DELETED flag during APPEND/COPY)  
     2160                 * e - perform EXPUNGE and expunge as a part of CLOSE  
     2161                 * a - administer (perform SETACL/DELETEACL/GETACL/LISTRIGHTS)  
     2162                 * Os Atributos da ACL para pastas compartilhadas são definidos no arquivo sharemailbox.js, na função setaclfromuser  
     2163                 * Os Atributos da ACL para contas compartilhadas são definidos no arquivo shared_accounts.js, na função setaclfromuser   
    21622164                 */  
    2163                             if (strpos($acl, "x") === false || strpos($acl, "t") === false || strpos($acl, "e") === false){  
     2165                            $acl_share_delete = (stripos($acl,'t') !== false && stripos($acl,'e') !== false);  
     2166                  
     2167                                if (!$acl_share_delete) {   
    21642168                                    $return['status'] = false;  
    21652169                            }  
     
    34103414 
    34113415                //Este bloco tem a finalidade de averiguar as permissoes para pastas compartilhadas 
    3412         if (substr($folder,0,4) == 'user'){ 
    3413                 $acl = $this->getacltouser($folder, isset($params['decoded'])); 
    3414                 /* 
    3415                  * l - lookup - Mailbox is visible in mailbox list. Mailbox can be subscribed to.  
    3416              * r - read - Mailbox can be opened for reading.  
    3417              * w - write - Message flags and keywords can be changed, except \Seen and \Deleted  
    3418              * s - write-seen - \Seen flag can be changed  
    3419              * t - write-deleted - \Deleted flag can be changed  
    3420              * i - insert - Messages can be written or copied to the mailbox  
    3421              * p - post - Messages can be posted to the mailbox by LDA, e.g. from Sieve scripts  
    3422              * e - expunge - Messages can be expunged  
    3423              * k - create - Mailboxes can be created (or renamed) directly under this mailbox (but not necessarily under its children, see ACL Inheritance section above) (renaming also requires delete rights)  
    3424              * x - delete - Mailbox can be deleted  
    3425              * a - admin - Administration rights to the mailbox (currently: ability to change ACLs for mailbox)   
     3416                if (substr($folder,0,4) == 'user'){ 
     3417                        $acl = $this->getacltouser($folder, isset($params['decoded'])); 
     3418 
     3419                        /* 
     3420                         * l - lookup (mailbox is visible to LIST/LSUB commands, SUBSCRIBE mailbox)  
     3421             * r - read (SELECT the mailbox, perform STATUS)  
     3422             * s - keep seen/unseen information across sessions (set or clear \SEEN flag via STORE, also set \SEEN during APPEND/COPY/        FETCH BODY[...])  
     3423             * w - write (set or clear flags other than \SEEN and \DELETED via STORE, also set them during APPEND/COPY)  
     3424             * i - insert (perform APPEND, COPY into mailbox)  
     3425             * p - post (send mail to submission address for mailbox, not enforced by IMAP4 itself)  
     3426             * k - create mailboxes (CREATE new sub-mailboxes in any implementation-defined hierarchy, parent mailbox for the new mailbox name in RENAME)  
     3427             * x - delete mailbox (DELETE mailbox, old mailbox name in RENAME)  
     3428             * t - delete messages (set or clear \DELETED flag via STORE, set \DELETED flag during APPEND/COPY)  
     3429             * e - perform EXPUNGE and expunge as a part of CLOSE  
     3430             * a - administer (perform SETACL/DELETEACL/GETACL/LISTRIGHTS)  
     3431             * Os Atributos da ACL para pastas compartilhadas são definidos no arquivo sharemailbox.js, na função setaclfromuser  
     3432             * Os Atributos da ACL para contas compartilhadas são definidos no arquivo shared_accounts.js, na função setaclfromuser  
    34263433                         */ 
    3427                         if (strpos($acl, "x") === false || strpos($acl, "t") === false || strpos($acl, "e") === false){  
     3434                        $acl_share_delete = (stripos($acl,'t') !== false && stripos($acl,'e') !== false);  
     3435                  
     3436                if (!$acl_share_delete) {   
    34283437                                $return['status'] = false; 
    34293438                                return $return; 
Note: See TracChangeset for help on using the changeset viewer.