Cloudflare IP support

Looking for an Extension? Have an Extension request? Post your request here for help. (Note: This forum is community supported; while there is an Extensions Development Team, said team does not dedicate itself to handling requests in this forum)
Ideas Centre
BigDrago
Registered User
Posts: 361
Joined: Fri Dec 10, 2004 5:16 pm
Location: Norway

Re: Cloudflare IP support

Post by BigDrago »

5.4.38 here..

1nv1s1bl3
Registered User
Posts: 115
Joined: Fri Nov 26, 2010 11:03 am

Re: Cloudflare IP support

Post by 1nv1s1bl3 »

Wouldn't mod_cloudflare resolve this?

https://www.cloudflare.com/resources-do ... cloudflare

Code: Select all

Because CloudFlare acts as a proxy, you will notice changes to the way that your website visitors' IP addresses are displayed both in your server logs and web applications - notably that all access appears to be coming from CloudFlare IP addresses. You can read more about the reasons for this in our knowledge base article.

You can change this behavior and log & display the actual visitor IP addresses by using mod_cloudflare.

Requirements
mod_cloudflare supports Apache httpd 2.2.x and 2.4.x. Installation requires root access to the command line of your server via SSH.

fulgan
Registered User
Posts: 73
Joined: Wed Jun 02, 2004 12:46 pm

Re: Cloudflare IP support

Post by fulgan »

Sure, mod_cloudflare would solve it but not everyone can install and activate apache mod on their hosting

SugarD-x
Registered User
Posts: 45
Joined: Mon Jun 19, 2006 12:42 am
Location: Sacramento, California USA
Contact:

Re: Cloudflare IP support

Post by SugarD-x »

Unfortunately in my case, with IIS 8.5, I have very little options on a server-wide level like Apache and older IIS users do. This includes using the mod_cloudflare module.

Swanny
Registered User
Posts: 452
Joined: Sun Apr 14, 2002 2:11 am
Location: Canada

Re: Cloudflare IP support

Post by Swanny »

Can someone here clarify for version 3.1 of phpBB, if mod_cloudflare is installed on the server is that all we need?

My hosting provider installed it no problems. I just made the DNS switch a few minutes ago, so I will see over the next 24 hours or so if/what benefits there are for CF.

CloudFlare looks promising. Even the free plan just using the CDN for the endless # of .css .gif .jpg etc static files will be nice. It will really take a load off my main VPS account/server.

User avatar
Lumpy Burgertushie
Registered User
Posts: 67412
Joined: Mon May 02, 2005 3:11 am
Contact:

Re: Cloudflare IP support

Post by Lumpy Burgertushie »

all of those files will already be cached in phpbb, why do you think you need to cache them somewhere else as well. I have seen nothing but problems around here related to cloudfare.


robert
I'm baaaaaccckkkk. still doing work on donation basis. PM your needs.

Premium phpBB 3.3 Styles by PlanetStyles.net

If nobody is in the forest, does a tree really fall?

Swanny
Registered User
Posts: 452
Joined: Sun Apr 14, 2002 2:11 am
Location: Canada

Re: Cloudflare IP support

Post by Swanny »

Lumpy Burgertushie wrote:all of those files will already be cached in phpbb, why do you think you need to cache them somewhere else as well.
Because there are loads of files and a CDN is a great benefit to phpBB since v 3.1.x

Look how poor phpBB.com is rated -- https://developers.google.com/speed/pag ... tab=mobile and http://gtmetrix.com/reports/www.phpbb.com/JrvgqDEt -- a CDN would help, as would other tweaks.

Swanny
Registered User
Posts: 452
Joined: Sun Apr 14, 2002 2:11 am
Location: Canada

Re: Cloudflare IP support

Post by Swanny »

Lumpy Burgertushie wrote:...I have seen nothing but problems around here related to cloudfare
I'm trying to improve phpBB and it's CloudFlare compatibility through trial-and-error and asking questions.

fulgan
Registered User
Posts: 73
Joined: Wed Jun 02, 2004 12:46 pm

Re: Cloudflare IP support

Post by fulgan »

Lumpy Burgertushie wrote:all of those files will already be cached in phpbb, why do you think you need to cache them somewhere else as well. I have seen nothing but problems around here related to cloudfare.


robert
Because a local cache is not the same thing as a CDN.
Because a local cache is not the same thing as a WAF.
Because a local cache is not the same thing as a reverse proxy service.

(in order words: I suggest you look at what cloudflare actually is).

User avatar
Mick
Support Team Member
Support Team Member
Posts: 22345
Joined: Fri Aug 29, 2008 9:49 am
Location: Cardiff

Re: Cloudflare IP support

Post by Mick »

fulgan wrote:Because a local cache is not the same thing as a CDN.
Because a local cache is not the same thing as a WAF.
Because a local cache is not the same thing as a reverse proxy service.
That's as maybe but what I don't get is there's obviously an issue with Cloudflare and IP's etc. It's reported all over the place here. Why aren't Cloudflare sorting this out?
"The more connected we get the more alone we become" - Kyle Broflovski

Please read: “Am I In The Right Place?” before posting.

fulgan
Registered User
Posts: 73
Joined: Wed Jun 02, 2004 12:46 pm

Re: Cloudflare IP support

Post by fulgan »

That's as maybe but what I don't get is there's obviously an issue with Cloudflare and IP's etc. It's reported all over the place here. Why aren't Cloudflare sorting this out?
You would have to ask them, really.

However, I suspect they would answer to you that:

- PHPBB support for reverse proxy system is really, really bad and the PHPBB team, if you believe the code comments, knows it.
- That it doesn't HAVE to be that bad since designing a system that properly (and optionally) supports reverse proxy is pretty a pretty well understood problem (and not such a complex one).
- That the PHPBB team is in a much better position than them to fix it.
- That they provide a number of - working - alternatives for a code fix (which, unfortunately will not work with shared or PaaS hosting).

Now, if you ask "How do I configure cloudflare for PHPBB", I'd answer:
- Perform the code change I suggested
- Set caching level to "no query string"
- Turn off rocket loader
- If you want to use HTTPS, then make yure you enable it on the server first (i.e. make sure it works without cloudflare before activating it in cloudflare)
- In PHPBB "General" -> "Board configuration" -> "Security settings", set "Session IP validation" to "none" and "Validate X_FORWARDED_FOR header" to "no"

User avatar
Volksdevil
Registered User
Posts: 2414
Joined: Sun Oct 03, 2010 2:03 pm
Location: Lancashire, UK
Name: Neil
Contact:

Re: Cloudflare IP support

Post by Volksdevil »

I have absolutely no issues using cloudflare, with pretty much everything enabled inc rocketloader. There was an issue at one time, but cloudflare made changes.

I could never have got results like this without cloudflare >> http://gtmetrix.com/reports/www.corradog60.com/ffzwZpAF :shock: :D
My phpBB Extensions
Finally found great Website Hosting from Image KUALO!
Do NOT use 123-reg.co.uk - Incapable of running phpBB!
:ugeek: TekNeil - Streamer on Mixer | My Volkswagen Corrado G60

Swanny
Registered User
Posts: 452
Joined: Sun Apr 14, 2002 2:11 am
Location: Canada

Re: Cloudflare IP support

Post by Swanny »

fulgan wrote:Now, if you ask "How do I configure cloudflare for PHPBB", I'd answer:...
Thanks man!

I just switched a 3.1.4 forum over last night to CloudFlare, I'm still evaluating which of those steps are required. I have mod_cloudflare installed on the server so I shouldn't need to make that code change.

I did not change the query string caching setting. Rocketloader is off. I'm not using SSL, and I have not modified the Session IP validation setting yet. I think I probably should change that setting right now...

FYI fulgan, Rocketloader should be OK to run if you are not using AdSense. Are you using AdSense?
Last edited by Swanny on Tue Jun 02, 2015 12:57 am, edited 1 time in total.

Swanny
Registered User
Posts: 452
Joined: Sun Apr 14, 2002 2:11 am
Location: Canada

Re: Cloudflare IP support

Post by Swanny »

Volksdevil wrote:I have absolutely no issues using cloudflare, with pretty much everything enabled inc rocketloader. There was an issue at one time, but cloudflare made changes.

I could never have got results like this without cloudflare >> http://gtmetrix.com/reports/www.corradog60.com/ffzwZpAF :shock: :D
Wow those are some great scores, almost unheard of for phpBB installations.

As far as I can tell, you're fine to run Rocketloader as long as you don't have AdSense on the page. Since you don't, you're OK. I have AdSense on my forum so I have to have Rocketloader off. I just wanted to clarify that point as it was mentioned by the other fella to turn RL off.

fulgan
Registered User
Posts: 73
Joined: Wed Jun 02, 2004 12:46 pm

Re: Cloudflare IP support

Post by fulgan »

Actually, the rocket loader and the caching parameter stuff depends a lot on the theme and CSS you use. I'm using (mostly) PBWoW and these were necessary because of all the javascript that collection of themes uses.

I don't think you can go wrong with the setting I've suggested but if you can enable more acceleration option without any bug, good for you :)

Post Reply

Return to “Extension Requests”