We launched new forums in March 2019—join us there. In a hurry for help with your website? Get Help Now!
    • 39583
    • 103 Posts
    Setting up correct policies for users isn't as easy as I thought.

    I want to have 4 levels of users.

    1. Administrators like the default user
    2. Editors - that can do all that the admins can except touching Elements.
    3. Writers - who can do anything with the resources. But nothing else.
    4. Contributors - Who can create documents and change them. But not publish them or anything else.

    For writes as an example, I have created a usergroup with the same name. Added the users I want under users. But for Context access I can only select administrator in access policy for the manager.

    Then for the editor in resource group access where I want admin rights I can only set member 9999 in access policy.

    Any help or a good tutorial. Because this is a little bit messy for me as a beginner.

    Thanks!
    André

    This question has been answered by BobRay. See the first response.

    [ed. note: phacer last edited this post 13 years, 11 months ago.]
      --
      André
      • 3109 ☆ A M B ☆
      • 894 Posts
      Phacer MODX ACLs are confusing and complicated at first take a look at my ACL tutorial and see if that helps you and make sure to read all the ACL documentation and see the security video so you can get a better understanding of how security works in MODX.

      Good luck.
        Benjamin Marte
        Interactive Media Developer
        Follow Me on Twitter | Visit my site | Learn MODX
        • 39583
        • 103 Posts
        Thanks for your answer. It clears some things for me. But I've been sitting with this every night since I posted this question and I can not get a simple resource user to work.

        It all seems the be because of the access policy in that user group. If I put anything lower then administrator the user can't login to the manager. For Web I use context, and mgr administrator only because thats the only way to success fully login.

        The other thing is I can't even select the resource context access policy from the "Add context" popup. I select mgr, Mini Role Member 9999 and in Access policy Resources doesn't even show up as an option. And if I create a new access policy based on an administrator and deselect everything the user shouldn't able to use then it doesn't work again.

        By doesn't work I mean trying to login with the member user in a different browser after flushing permissions and sessions. Modx recognises that the password is correct and just goes back to the login screen.

        Kind of frustrating, when it feels like I've tried every possible combination of resource groups, access policies and user roles.

        Any tips or ideas of how I can fix this?
          --
          André
        • discuss.answer
          • 3749
          • 24,544 Posts
          If I'm understanding you, you should be able to accomplish what you want without any Resource Groups.

          Create three new Policies based on the Administrator Policy Template.

          Editors: uncheck element_tree and access_permissions
          Writers: uncheck element_tree, file_tree, and any other things you don't want them to do (access_permissions, etc.)

          Contributors: element_tree, file_tree, access_permissions, and all the document permissions you don't want them to have (publish_document, delete_document, duplicate_document, etc.).

          In Security -> Access Controls -> User Group tab -- right-click on each user group and, on the Context Access tab, add an ACL entry with a context of 'mgr', a minimum role that the users have, and the appropriate policy.

          On the Security menu, flush permissions and flush all sessions before testing. It's a good idea to test from another browser where you're not logged in to the Manager.


          ------------------------------------------------------------------------------------------
          PLEASE, PLEASE specify the version of MODX you are using.
          MODX info for everyone: http://bobsguides.com/modx.html

          [ed. note: BobRay last edited this post 13 years, 11 months ago.]
            Did I help you? Buy me a beer
            Get my Book: MODX:The Official Guide
            MODX info for everyone: http://bobsguides.com/modx.html
            My MODX Extras
            Bob's Guides is now hosted at A2 MODX Hosting
            • 39583
            • 103 Posts
            Thanks BobRay, your solution works!
              --
              André
              • 3749
              • 24,544 Posts
              I'm glad I could help. smiley


              ------------------------------------------------------------------------------------------
              PLEASE, PLEASE specify the version of MODX you are using.
              MODX info for everyone: http://bobsguides.com/modx.html
                Did I help you? Buy me a beer
                Get my Book: MODX:The Official Guide
                MODX info for everyone: http://bobsguides.com/modx.html
                My MODX Extras
                Bob's Guides is now hosted at A2 MODX Hosting