I noticed that the following code set the RID of 3 as the default administrator role:

http://cgit.drupalcode.org/panopoly_admin/tree/panopoly_admin.strongarm.inc

This is fine, assuming you have a RID of 3 AND that role is truly an admin. If you don't meet either criteria, then you are giving non-admins permissions they shouldn't have, such as:

Screenshot

I recommend we either disable this option (set the strongarm value to '0') or we make it a default config that can be changed later. If we disable this option, then the onus for setting appropriate permissions are on the distribution developers. What are your thoughts? I'll be happy to work on a patch with whichever option we choose.

CommentFileSizeAuthor
#5 default_admin_role-2637004-5.patch1.62 KBhumansky
Support from Acquia helps fund testing for Drupal Acquia logo

Comments

humansky created an issue. See original summary.

humansky’s picture

Issue summary: View changes
humansky’s picture

Issue summary: View changes

Fixed screenshot link

dsnopek’s picture

Thanks for creating this issue!

Yeah, I think we probably shouldn't put this in strongarm or defaultconfig at all. We should either set this during installation if the user is installing the Panopoly profile, or maybe in a hook_install() for this module and actually look for a role named "administrator" rather than assuming the 'rid' which is definitely dangerous...

humansky’s picture

Added a patch to address this issue

humansky’s picture

Status: Active » Needs review
dsnopek’s picture

This patch looks awesome! I just need to test it once and then I'll commit it.

  • dsnopek committed 7a8bd0b on 7.x-1.x
    Update Panopoly Admin for Issue #2637004 by humansky: Default admin role
    
dsnopek’s picture

Status: Needs review » Fixed

This worked in manual testing with a new install! Committed. :-)

Status: Fixed » Closed (fixed)

Automatically closed - issue fixed for 2 weeks with no activity.