We launched new forums in March 2019—join us there. In a hurry for help with your website? Get Help Now!
    • 36551
    • 416 Posts
    I've got a site that I cloned and moved to a new VPS server on Arvixe Hosting. The site came up perfectly, the manager was working, all good. I started modifying the CSS and a few templates etc for the new design for the site. This has been working for three days.

    Suddenly today, I get "Permission denied" when I try to login to the manager. This is happening for the other site admin too. Both of us are Sudo Users. My understanding is that a Sudo User has no permission restrictions.

    I've not made any ACL changes. I looked at the DB using PhpMyAdmin and confirmed we are Sudo Uers, we have 0 blocked logins, etc. I've manually cleared the cache on the server, cleared my browser cache and all cookies related to this site and tried other browsers I never used to access this site.

    What's weird is that if I try to login with a user id that doesn't exist, I still get "Permission Denied". I should get the message that says: "The username or password you entered is incorrect. . . "

    I can't think of anything I could do that would cause this behavior. I've searched the forum and didn't find anything that sounded like this.

    Any ideas?
      • 3749
      • 24,544 Posts
      I don't think your message is coming from MODX, unless you've done something recently that would have changed the admins' permissions. I think it's more likely from the server due to a file or directory permission, ownership problem, or a security change in .htaccess.

      A faulty plugin attached to onManagerLogin could also do it.

      It could also conceivably be mod_security, though I think that's less likely.

        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
        • 36551
        • 416 Posts
        Even though the message appears within the modx login box? [ed. note: terrybarth last edited this post 9 years ago.]
        • There's a lot of AJAX requests going on in the background of that login form. If one of those is returning a server "permission denied" message, that would be displayed in the login box.
            Studying MODX in the desert - http://sottwell.com
            Tips and Tricks from the MODX Forums and Slack Channels - http://modxcookbook.com
            Join the Slack Community - http://modx.org
            • 36551
            • 416 Posts
            Interesting, any suggestions on how to track this down?
              • 3749
              • 24,544 Posts
              Use Chrome Dev. tools or Firefox. Press (Ctrl-shift-i).

              Click on the "Network" tab and watch as you try to log in. You may get a clue about what file can't be read, if that's the problem. You may have to drill down to see the actual URL if it's going through the connector.
                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
              • You can also check your core/cache/logs to see if MODX is logging anything, as well as your server's PHP error logs and access logs. The access logs will probably tell you exactly what is being denied.

                For example, on my localhost MAMP installation, every time I access my localhost htdocs folder and get the index list of the subdirectories where I have my MODX installations, I get this:
                [Tue Apr 14 12:54:25 2015] [error] [client ::1] client denied by server configuration: /Applications/MAMP/htdocs/.DS_Store
                

                For non-Mac users, that .DS_Store is a metadata file that every directory gets, and is considered a hidden system file. It's not allowed to be displayed in a web server's index listing. Of course, a production server would have that index listing disabled to begin with, but for a localhost dev environment it's useful.
                [ed. note: sottwell last edited this post 9 years ago.]
                  Studying MODX in the desert - http://sottwell.com
                  Tips and Tricks from the MODX Forums and Slack Channels - http://modxcookbook.com
                  Join the Slack Community - http://modx.org
                  • 36551
                  • 416 Posts
                  Surprisingly, this has been resolved.

                  Since this site was cloned from another, we looked for differences between the two. Aside from the Modx upgrade, I had installed my new favorite extra, Updater.

                  We edited the database directly and deactivated the two plugins related to Updater. After we cleared the cache, we were able to login to the manager.
                    • 52634
                    • 60 Posts
                    Can confirm that this can happen. The workaround is indeed deactivating the plugin (only "Updater Notifier" plugin seems to be affected).
                    Unfortunately it is a critical bug and so I advice to deactivate the plugin in advance even if you have not run into this error yet.