Constant logging out on every action

MODX 2.8.6, PHP 7.4

I’ve been working inside MODX for a site for the last 3 weeks without a problem. It’s been on maintenance mode for the last 4 days. Today I see a new problem when I logged in and nearly every action I do in MODX I get logged out with a dialog box for logging in again.

This happens in the privacy tab as well as in other browsers.

I have no clue what’s causing it.

Also the server it’s on has other websites with MODX versions that do work.

Has anyone experienced this?

My next step would be to try using PHP 8.x

Thanks

John

Update.

I upgraded to PHP 8.1. Same problem for a bit. Then I decided to take it off of maintenance mode. Worked fine!. Then I put it back on maintenance mode. Continued to work fine.

So this is the point where I’m at. Maintenance mode on, no issues.

Still, I don’t know what caused that.

So this morning, same problem with maintenance mode ON. So I turned it off again, and no prompts for login.

So what exactly do you mean by “maintenance mode”?
Is this when you change the system setting site_status?

Yes, turning site status off gives me no more of those login issues. However, it worked before so still not sure what’s going on. I’ll do an upgrade to 2.8.8 later and see if that makes a difference.

It’s also unclear to me, what causes the issue.

The only thing that changes when site_status is set to No is, that the function checkSiteStatus() now also checks the state of the session and the view_offline permission:

But this function gets only executed for requests to the frontend.

The requests in the MODX manager should always work the same, whether site_status is set or not.

Yeah that is weird. Is the function unchanged between 2.8.6 and 2.8.8?

Yes. According to the ‘blame’ functionality on Github, the function hasn’t changed in 9 years. (And the latest version of MODX 3 also still uses the same function.)

My first thought is that it’s something to do with session cookies. Just a guess.