Hello again,
I have pinpointed what causes the issue, is not the use of CloudFlare in general (that is why you did not experience this issue while using them), but the use of its Flexible SSL option to encrypt communication to and from a website using SSL. Using this option a site does not have to be SSL enabled. Pages from my site are served by CloudFlare over HTTPS while they communicate with the origin server through plain HTTP.
I looked at LiteSpeed plugin code and discovered that you are making this call when someone requests a key from your image server (litespeed-cache/admin/admin-api.class.php, function _request_key() line 201)
$json = $this->_post( self::IAPI_ACTION_REQUEST_KEY, home_url() ) ;
Unfortunately the home_url()
call returns the plain HTTP version of my site’s homepage since the server is not HTTPS enabled. Nevertheless if your image server tries to contact my site’s homepage (any any page for that matter) over plain HTTP, CloudFlare redirects them to the HTTPS version of it automatically.
I managed to get over this issue by replacing the call to home_url()
with home_url('/','https')
but this is only to validate my point.
I would really like you to apply a patch to one of the following updates of the plugin so as to address this issue and be able to support this kind of setup since a vast amount of sites utilize CloudFlare’s Flexible SSL feature.
Looking forward to your feedback.
Best regards,
Byron