LiteSpeed Cache for XF2 - Community

LiteSpeed Cache for XF2 - Community 2.3.0

No permission to download
@Michael A. If you don't check the Keep Me Logged In, you get the issue with the cached page being shown to logged in users. @MattW

Also just now I got a report from a member:

Trying to log-in, "Oops! Error Occured; refresh page and try later"

Still the same after following instructions, but although main page not showing as "logged in", any other paged does show I'm logged-in and I can write a post.

I can confirm there are issues. Login without clicking "keep me logged in" results in all kinds of weird semi-logged in behavior.
 
Last edited:
@Michael A. If you don't check the Keep Me Logged In, you get the issue with the cached page being shown to logged in users. @MattW

Also just now I got a report from a member:



I can confirm there are issues. Login without clicking "keep me logged in" results in all kinds of weird semi-logged in behavior.

Hey dethfire,

I saw the ticket you submitted on this issue as well. The behavior definitely sounds like something we've already tested for and confirmed working. I'll do some more testing on our end but could I ask you to confirm that you have LiteSpeed and your .htaccess file setup correctly? (specifically the cache policy settings in LSWS)



Thanks,
-Micahel
 
If your cookie prefix is xf_ that should be okay. The {$prefix}_user cookie should get created during login.

If you are using a custom cookie prefix through

Pardon my ignorance, where would I find whether or not I have a custom prefix? If I have not edited config.php do I presume it is default xf_user?
 
Pardon my ignorance, where would I find whether or not I have a custom prefix? If I have not edited config.php do I presume it is default xf_user?

That would be correct, xf_ is the default prefix. If this was changed, you could find it in your installations config file as $config['cookie']['prefix'].
 
Last edited:
I have a Xenforo in stallion in a sub directory. There is a Wordpress installation in the root, do I still edit the root .htaccess?

And what if I use a litespeed plugin for the Wordpress?
 
Last edited:
I have a Xenforo in stallion in a sub directory. There is a Wordpress installation in the root, do I still edit the root .htaccess?

And what if I use a litespeed plugin for the Wordpress?

You would need to edit the .htaccess in your XenForo root, .htaccess files above that can be left alone. Also, you should have no problems using our WordPress cache plugin as well.


Any guidance on estimate time to fix, should I disable the addon for now?

You can disable for now as it could cause some issues with your visitors, as I've confirmed that these visitors will always get the cached logged out page if that page is currently cached. I'm looking into it more today and would say I should have something by Monday latest.

Regards,
- Michael
 
Any guidance on estimate time to fix, should I disable the addon for now?

Hey @dethfire ,

Sorry for the delay, I ended up deciding that I wanted to try and squeeze a little more into this release. I've got everything tested and working at this point and am working on the packaging now. I should be set to release v2.2 of the plugin sometime tomorrow morning.

Regards,
-Michael
 
Michael A. updated LiteSpeed Cache for XF2 - Community with a new update entry:

LiteSpeed Cache for XF2 Community - 2.2.0

[Improvement] Improved login state detection to prevent forum members who sign in with "Stay logged in" unchecked from being served by cache. (Rewrite rule update required)
[Improvement] No longer cache "install" pages. (Rewrite rule update required)
[Improvement] Improved return code checking to prevent caching non HTTP status 200 and 404 pages. (500 errors may still run into issues)

Read the rest of this update entry...
 
Hi guys,

With the release of v2.2.0 I'd ask that you please update your related rewrite rules to the following:

Apache config:
# LiteSpeed XenForo cache
<IfModule litespeed>
    CacheLookup public on
    RewriteEngine On
     # cache
     RewriteCond %{HTTP_COOKIE} !(xf_lscxf_logged_in|xf_user|xf_session_admin) [NC]
     RewriteCond %{REQUEST_URI} !/install/ [NC]
     RewriteRule .* - [E=Cache-Control:max-age=360]
     # no cache
     RewriteCond %{HTTP_COOKIE} (xf_lscxf_logged_in|xf_user|xf_session_admin) [NC]
     RewriteRule .* - [E=Cache-Control:vary=loggedin,E=Cache-Control:no-cache]
</IfModule>

Thanks!
 
Top Bottom