Support » Plugin: Advanced Access Manager » Limited access to roles

  • Resolved ajcke

    (@ajcke)


    I just installed the AAM plugin. I’m giving it a try over Role Scoper on a MultiSite. I only have access to modify settings for the subscriber role and users that have the subscriber role.

Viewing 3 replies - 1 through 3 (of 3 total)
  • Seems to be a missing check for superadmin user when it filters user roles available.
    Adding this code at the beginning of \AAM_Service_UserLevelFilter::filterRoles() at application/Service/UserLevelFilter.php:129 fixed the issue for me:

    if (is_super_admin()) {
        return $roles;
    }

    As a temporary workaround, you can try assigning yourself to the site explicitly as administrator. But you will likely need to deactivate the plugin while adding your user record to the site as it will restrict “administrator” role while active.

    • This reply was modified 1 month, 1 week ago by pumka.

    PS. Also required me to disable “User Level Filter” option in plugin settings as it still not allowed me to edit user roles. Actually disabling the option alone fixes the issue, though I believe the option’s implementation should exclude superadmins.

    Plugin Author AAM Plugin

    (@vasyltech)

    @pumka,

    Thank you for digging into the code. You are determined 🙂

    The “User Level Filter” service filters out all the users and roles that have a lower user level. This helps to protect from more privileged users from being altered or even removed.

    AAM also does not differentiate between roles. The administrator role is treated the same way as the subscriber role. On the large scale websites, there can be multiple super admins, however only one can be able to manage access. That is a quite common requirement that we get and that is the reason we try to avoid any sort of exceptions.

    @ajcke you can simply disable mentioned above service and this will do the trick.

    Regards,
    Vasyl

Viewing 3 replies - 1 through 3 (of 3 total)
  • You must be logged in to reply to this topic.