<commit_before><?php
App::uses('Component', 'Controller');

class ACLComponent extends Component
{

    // syntax:
    // $__aclList[$controller][$action] = $permission_rules
    // $controller == '*'                 -  any controller can have this action
    // $action == array()                 -  site admin only has access
    // $action == '*'                     -  any role has access
    // $action == array('OR' => array())  -  any role in the array has access
    // $action == array('AND' => array()) -  roles with all permissions in the array have access
    // If we add any new functionality to MISP and we don't add it to this list, it will only be visible to site admins.
    private $__aclList = array(
            '*' => array(
                    'blackhole' => array(),
                    'checkAction' => array(),
                    'checkAuthUser' => array(),
                    'checkExternalAuthUser' => array(),
                    'cleanModelCaches' => array(),
                    'debugACL' => array(),
                    'generateCount' => array(),
                    'getActions' => array(),
                    'pruneDuplicateUUIDs' => array(),
                    'queryACL' => array(),
                    'removeDuplicateEvents' => array(),
                    'updateDatabase' => array(),
                    'upgrade2324' => array(),
            ),
            'attributes' => array(
                    'add' => array('perm_add'),
                    'add_attachment' => array('perm_add'),
                    'add_threatconnect' => array('perm_add'),
                    'addTag' => array('perm_tagger'),
                    'attributeReplace' => array('perm_add'),
                    'attributeStatistics' => array('*'),
                    'bro' => array('*'),
                    'checkAttachments' => array(),
                    'checkComposites' => array('perm_admin'),
                    'checkOrphanedAttributes' => array(),
                    'delete' => array('perm_add'),
                    'deleteSelected' => array('perm_add'),
                    'describeTypes' => array('*'),
                    'download' => array('*'),
                    'downloadAttachment' => array('*'),
                    'downloadSample' => array('*'),
                    'edit' => array('perm_add'),
                    'editField' => array('perm_add'),
                    'editSelected' => array('perm_add'),
                    'exportSearch' => array('*'),
                    'fetchEditForm' => array('perm_add'),
                    'fetchViewValue' => array('*'),
                    'generateCorrelation' => array(),
                    'hoverEnrichment' => array('perm_add'),
                    'index' => array('*'),
                    'pruneOrphanedAttributes' => array(),
                    'removeTag' => array('perm_tagger'),
                    'reportValidationIssuesAttributes' => array(),
                    'restore' => array('perm_add'),
                    'restSearch' => array('*'),
                    'returnAttributes' => array('*'),
                    'rpz' => array('*'),
                    'search' => array('*'),
                    'searchAlternate' => array('*'),
                    'toggleCorrelation' => array('perm_add'),
                    'text' => array('*'),
                    'toggleToIDS' => array('perm_add'),
                    'updateAttributeValues' => array('perm_add'),
                    'view' => array('*'),
                    'viewPicture' => array('*'),
            ),
            'eventBlacklists' => array(
                    'add' => array(),
                    'delete' => array(),
                    'edit' => array(),
                    'index' => array(),
                    'massDelete' => array()
            ),
            'eventDelegations' => array(
                    'acceptDelegation' => array('perm_add'),
                    'delegateEvent' => array('perm_delegate'),<commit_msg>chg: [ACL] Added new community functions to the ACL component<commit_after><?php
App::uses('Component', 'Controller');

class ACLComponent extends Component
{

    // syntax:
    // $__aclList[$controller][$action] = $permission_rules
    // $controller == '*'                 -  any controller can have this action
    // $action == array()                 -  site admin only has access
    // $action == '*'                     -  any role has access
    // $action == array('OR' => array())  -  any role in the array has access
    // $action == array('AND' => array()) -  roles with all permissions in the array have access
    // If we add any new functionality to MISP and we don't add it to this list, it will only be visible to site admins.
    private $__aclList = array(
            '*' => array(
                    'blackhole' => array(),
                    'checkAction' => array(),
                    'checkAuthUser' => array(),
                    'checkExternalAuthUser' => array(),
                    'cleanModelCaches' => array(),
                    'debugACL' => array(),
                    'generateCount' => array(),
                    'getActions' => array(),
                    'pruneDuplicateUUIDs' => array(),
                    'queryACL' => array(),
                    'removeDuplicateEvents' => array(),
                    'updateDatabase' => array(),
                    'upgrade2324' => array(),
            ),
            'attributes' => array(
                    'add' => array('perm_add'),
                    'add_attachment' => array('perm_add'),
                    'add_threatconnect' => array('perm_add'),
                    'addTag' => array('perm_tagger'),
                    'attributeReplace' => array('perm_add'),
                    'attributeStatistics' => array('*'),
                    'bro' => array('*'),
                    'checkAttachments' => array(),
                    'checkComposites' => array('perm_admin'),
                    'checkOrphanedAttributes' => array(),
                    'delete' => array('perm_add'),
                    'deleteSelected' => array('perm_add'),
                    'describeTypes' => array('*'),
                    'download' => array('*'),
                    'downloadAttachment' => array('*'),
                    'downloadSample' => array('*'),
                    'edit' => array('perm_add'),
                    'editField' => array('perm_add'),
                    'editSelected' => array('perm_add'),
                    'exportSearch' => array('*'),
                    'fetchEditForm' => array('perm_add'),
                    'fetchViewValue' => array('*'),
                    'generateCorrelation' => array(),
                    'hoverEnrichment' => array('perm_add'),
                    'index' => array('*'),
                    'pruneOrphanedAttributes' => array(),
                    'removeTag' => array('perm_tagger'),
                    'reportValidationIssuesAttributes' => array(),
                    'restore' => array('perm_add'),
                    'restSearch' => array('*'),
                    'returnAttributes' => array('*'),
                    'rpz' => array('*'),
                    'search' => array('*'),
                    'searchAlternate' => array('*'),
                    'toggleCorrelation' => array('perm_add'),
                    'text' => array('*'),
                    'toggleToIDS' => array('perm_add'),
                    'updateAttributeValues' => array('perm_add'),
                    'view' => array('*'),
                    'viewPicture' => array('*'),
            ),
            'communities' => array(
                    'index' => array(),
                    'requestAccess' => array(),
                    'view' => array()
            ),
            'eventBlacklists' => array(
                    'add' => array(),
                    'delete' => array(),
                    'edit' => array(),
                    'index' => array(),
                    'massDelete' => array()
            ),
            'eventDelegations' => array(
                    'acceptDelegation' => array('perm_add'),
                    'delegateEvent' => array('perm_delegate'),
{'fraction_non_alphanumeric': 0.15621588841722256, 'fraction_numerical': 0.0009702850212249849, 'mean_word_length': 1.352639087018545, 'pattern_counts': {'":': 0, '<': 5, '<?xml version=': 0, '>': 139, 'https://': 0, 'lorem ipsum': 0, 'www.': 0, 'xml': 0}, 'pii_count': 0, 'substrings_counts': 0, 'word_list_counts': {'cursed_substrings.json': 6, 'profanity_word_list.json': 0, 'sexual_word_list.json': 0, 'zh_pornsignals.json': 0}}
{'dir': 'git-commits-cleaned', 'id': '6633964', 'n_tokens_mistral': 2040, 'n_tokens_neox': 1913, 'n_words': 426}