Fork me on GitHub
Current Releases are 2.1 stable (major release) and 2.0.18.11 (security patch for 2.0)
We've also rebooted our GitHub repo, docs, and more!

Default Administrator vs. Admin Role

renerene New
edited January 2011 in Questions
There is a difference.

As a user with an Admin role I can't change settings for some of my plugins. For example the Spoof plugin and the FileUpload plugin settings can only be changed by the original Administrator. A user with an Admin role gets a permission problem.

Why is this? And can I fix it?

Comments

  • LincLinc Community Instigator Detroit Vanilla Staff
    edited January 2011
    That means there's a permission setup problem. You may need to grant them the correct permission in the Dashboard, or there may be a bug in the plugin.

    There is an 'Admin' column in the user table (which has nothing to do with the Administrator role). If that is set to '1' (like for the original user), then every permission check evaluates to true. Otherwise, they need to be correctly configured.

    Sr Developer at Vanilla Forums [GitHub, Twitter] and humble servant of Lord Brackos.

  • renerene New
    edited January 2011
    @Lincoln: thanks for your reply.

    The 'Admin' column did the trick. But I think this is not the official way? :P

    Strange thing is that the content of the "Permissions" column is the same for the real Admin as the user with Admin Role.

    In the Dashboard, my Admin role permissions are all checked. Since I can't see any other permission settings for the Admin role my guess is that the plugins don't use the right way to deal with permissions. Although the FileUpload plugin is approved and designed by the vanilla staff.

    Would this be a logical conclusion? Or could there be something wrong in my vanilla install?
  • LincLinc Community Instigator Detroit Vanilla Staff
    edited January 2011
    In the case of the FileUpload plugin, that's the way @Tim designed it. If you look in the file, you'll find:

    'SettingsPermission' => 'Garden.AdminUser.Only',

    so the behavior you're seeing wasn't by accident.

    I would assume Spoof has a similar setup or perhaps does have a permission error; I'm not familiar with it.

    //edit: FYI, the 'Garden.AdminUser.Only' doesn't technically exist. Specifying a nonexistent permission like this one actually causes it to do exactly as this arbitrary name says: cause only users with the 'Admin' flag to be able to pass it.

    Sr Developer at Vanilla Forums [GitHub, Twitter] and humble servant of Lord Brackos.

  • LincLinc Community Instigator Detroit Vanilla Staff
    As an aside, there's no way in Vanilla to set that 'Admin' flag via the software, so the "not official way" is the only way for now.

    Sr Developer at Vanilla Forums [GitHub, Twitter] and humble servant of Lord Brackos.

  • TimTim Lord of Servers Vanilla Staff
    @rene @Lincoln

    In the past we had designed plugins such as FileUpload (which directly impact the server in a non-trivial way) to be configured only by the root admin. Most of the time this was 'ok' since the forum was usually directly controlled and configured by that person - the root admin. Increasingly, however, we've been seeing cases where those tasks have been delegated to others, so we're moving towards a less restrictive way of doing things.

    I'll likely lessen the restrictions on FileUpload's configuration mode in a future release, or possibly create a new vanilla-wide permission like Garden.Plugins.Manage or something similar, which will allow people to configure plugins.

    Thoughts?

    Vanilla Forums Senior Developer [GitHub, Twitter, About.me]

  • LincLinc Community Instigator Detroit Vanilla Staff
    @Tim Garden.Plugins.Manage sounds good to me.

    Sr Developer at Vanilla Forums [GitHub, Twitter] and humble servant of Lord Brackos.

  • Yeah, Looks like a good idea to create a vanilla-wide solution. It would also be more transparent for other plugin developers. Thanks for your replies!
Sign In or Register to comment.