We launched new forums in March 2019—join us there. In a hurry for help with your website? Get Help Now!
    • 35715
    • 59 Posts
    All I know is that it happens just about every time I login on any client site, BUT I don't think it has ever happened to me on modxcloud (but my brain isn't what it used to be). So it could be just cpanel sites only. Only actual fact I know is that one client still on 2.2.6 never has the issue.
      • 9102 ☆ A M B ☆
      • 318 Posts
      OK, here's an interesting clue:

      I just logged in later than usual this morning, after other users are probably logged in. I tried to download the Error Log report, which is currently too large to display (this has nothing to do with this problem, it's correctly logging debugging messages from a custom add-on) so it has a download link.

      When I click the download button, it takes me to this URL:

      /connectors/system/errorlog.php?action=download&HTTP_MODAUTH=0

      The content of the URL is a JSON array like this:
      {"success":false,"message":"Access denied.","total":0,"data":[],"object":{"code":401}} 
      

      in other words, it's giving me an access denied error in raw form.

      Notice the HTTP_MODAUTH=0 in the URL.

      If I view the source of the report log manager page, there is a script with this line:
      MODx.load({xtype: "modx-layout",accordionPanels: MODx.accordionPanels || [],auth: "0"});
      

      I don't know a lot about the way the scripts for these manager pages are generated, but I'm guessing the line above is the problem? It should be hard-coding my actual auth token into the page, right?

      So, I tried flushing my permissions, logging out and back in, and sure enough now there's a real auth token on that line instead of 0, and I can download the log.

      For those familiar with the manager, I'm probably just stating the very obvious. I don't have time to investigate further right now. When I have time I'll look more deeply into it.
        • 9648 ☆ A M B ☆
        • 91 Posts
        Quote from: esnyder at Sep 25, 2013, 10:47 AM
        OK, here's an interesting clue:
        MODx.load({xtype: "modx-layout",accordionPanels: MODx.accordionPanels || [],auth: "0"});
        

        I don't know a lot about the way the scripts for these manager pages are generated, but I'm guessing the line above is the problem? It should be hard-coding my actual auth token into the page, right?

        So, I tried flushing my permissions, logging out and back in, and sure enough now there's a real auth token on that line instead of 0, and I can download the log.

        For those familiar with the manager, I'm probably just stating the very obvious. I don't have time to investigate further right now. When I have time I'll look more deeply into it.

        I wrote about all of this many time ago.
        * And read comments after.
          MODX Revolution expert
          Follow ME on Twitter | Feel free ask any question on MODX-club
          • 9102 ☆ A M B ☆
          • 318 Posts
          Like I said, probably obvious but I thought it better to over-share.
            • 9648 ☆ A M B ☆
            • 91 Posts
            Quote from: esnyder at Sep 25, 2013, 11:24 AM
            Like I said, probably obvious but I thought it better to over-share.
            There a said not problem only, but and solution too here and here.

            Jason not agree with me, but i know what i`m doing.
            And yes, it`s hardcode, but while we dont got official path and if you tried to do relogin, it`s may help you.
              MODX Revolution expert
              Follow ME on Twitter | Feel free ask any question on MODX-club
              • 9102 ☆ A M B ☆
              • 318 Posts
              No worries, we can cope with the problem until we get an official fix. I'm just trying to find the source of the problem and I thought I should document my efforts to do so. I'll probably have more obvious and/or redundant observations to share later ;-)
                • 35715
                • 59 Posts
                Strike that - just happened in the cloud too smiley

                Quote from: phil_w at Sep 25, 2013, 01:57 AM
                All I know is that it happens just about every time I login on any client site, BUT I don't think it has ever happened to me on modxcloud (but my brain isn't what it used to be). So it could be just cpanel sites only. Only actual fact I know is that one client still on 2.2.6 never has the issue.
                  • 21257 MODX Staff
                  • 730 Posts
                  Hi Phil,

                  Would you mind sending an email to [email protected] with the name of the cloud in question if you don't mind us spinning up a snapshot of it for testing? If we can reproduce this in the MODX Cloud environment, it'll be much easier to understand and solve.

                    Mike Schell
                    Lead Developer, MODX Cloud
                    Email: [email protected]
                    GitHub: https://github.com/netProphET/
                    Twitter: @mkschell
                    • 35715
                    • 59 Posts
                    Email sent, Mike

                    Quote from: netProphET at Sep 30, 2013, 01:09 PM
                    Hi Phil,

                    Would you mind sending an email to [email protected] with the name of the cloud in question if you don't mind us spinning up a snapshot of it for testing? If we can reproduce this in the MODX Cloud environment, it'll be much easier to understand and solve.

                      • 22303 MODX Staff
                      • 10,725 Posts
                      Can those of you experiencing this confirm or deny that this occurs when you are viewing a Resource in the front-end within the same browser session as using the Manager? I stepped through this with someone experiencing the problem yesterday, and turning off sessions in the front-end Context( s ) or viewing the front-end in an incognito window prevented the problem from reoccurring.