Page 1 of 1

[SOLVED] Admin extensions - DDoS protection by Cloudflare and auto page refreshes

Posted: Sat Apr 04, 2020 3:48 pm
by jrunique
Version 3.0.3.2

Today I am seeing a message "DDoS protection by Cloudflare" in admin extensions, and the page is automatically refreshing every 5-10 seconds. This is happening on both of my websites that are hosted on the same account.
I'm not using cloudfare so I'm confused why I am seeing this message today. I'm concerned about hacking.

Re: Admin extensions - DDoS protection by Cloudflare and auto page refreshes

Posted: Sat Apr 04, 2020 3:53 pm
by letxobnav
I am assuming that is where normally the OC advertisement goes.

Re: Admin extensions - DDoS protection by Cloudflare and auto page refreshes

Posted: Sat Apr 04, 2020 4:16 pm
by jrunique
Thanks for the fast reply. Yes, I remember the OC banner was in that location. I guess it's just a temporary glitch so I will ignore it for now. :)

Re: Admin extensions - DDoS protection by Cloudflare and auto page refreshes

Posted: Sat Apr 04, 2020 7:45 pm
by jonathanbb
I am having the same issue. Bit of a pain as there isnt enough time to open the module I want to edit.

Re: Admin extensions - DDoS protection by Cloudflare and auto page refreshes

Posted: Sat Apr 04, 2020 8:10 pm
by OSWorX
jonathanbb wrote:
Sat Apr 04, 2020 7:45 pm
I am having the same issue. Bit of a pain as there isnt enough time to open the module I want to edit.
Options you have:
1. tell that CloudFlare
2. tell that OpenCart Dev Team (to move away from them)
3. disable this check (do it by yourself)

Re: Admin extensions - DDoS protection by Cloudflare and auto page refreshes

Posted: Sat Apr 04, 2020 10:39 pm
by mr.who
i have same issue ! i never use cloudflare, or any module have a relation to it !! so how can we stop it !????

Re: Admin extensions - DDoS protection by Cloudflare and auto page refreshes

Posted: Sat Apr 04, 2020 11:07 pm
by OSWorX
mr.who wrote:
Sat Apr 04, 2020 10:39 pm
i have same issue ! i never use cloudflare, or any module have a relation to it !! so how can we stop it !????
Everyone who is using OpenCart 3.x and opened the Extensions page in the backend exactly in that timeframe, had (and maybe will have) this problem.
So, this has nothing todo with you, me our my dog.
And the solution is already posted above.

Re: Admin extensions - DDoS protection by Cloudflare and auto page refreshes

Posted: Sat Apr 04, 2020 11:20 pm
by letxobnav
just add

Code: Select all

return;
after

Code: Select all

public function index() {
in admin/controller/extension/extension/promotion.php

Re: Admin extensions - DDoS protection by Cloudflare and auto page refreshes

Posted: Sat Apr 04, 2020 11:34 pm
by mr.who
:-\ what a solution ....
simple permenant fix :
go to : public_html/admin/controller/extension/extension/promotion.php
replace line 18 with :

Code: Select all

return '';
that's it

Re: Admin extensions - DDoS protection by Cloudflare and auto page refreshes

Posted: Sun Apr 05, 2020 5:27 pm
by JNeuhoff
OSWorX wrote:
Sat Apr 04, 2020 8:10 pm
jonathanbb wrote:
Sat Apr 04, 2020 7:45 pm
I am having the same issue. Bit of a pain as there isnt enough time to open the module I want to edit.
Options you have:
1. tell that CloudFlare
2. tell that OpenCart Dev Team (to move away from them)
3. disable this check (do it by yourself)
4. Or don't use CloudFlare

In our experience CloudFlare tends to slow things down anyway, despite its claim of being a performance-boosting CDN.

Re: Admin extensions - DDoS protection by Cloudflare and auto page refreshes

Posted: Sun Apr 05, 2020 6:43 pm
by OSWorX
JNeuhoff wrote:
Sun Apr 05, 2020 5:27 pm
4. Or don't use CloudFlare

In our experience CloudFlare tends to slow things down anyway, despite its claim of being a performance-boosting CDN.
True (forgot that ..) - thx Juergen.
But finally, we have to talk with Daniel - OpenCart use CF and make troubles sometimes in the backend!

Re: [SOLVED] Admin extensions - DDoS protection by Cloudflare and auto page refreshes

Posted: Fri Apr 10, 2020 5:21 am
by haxcop
Simpler solution is:
go to /admin
config.php
comment the line

Code: Select all

// OpenCart API
define('OPENCART_SERVER', 'https://www.opencart.com/');
for

Code: Select all

// OpenCart API
//define('OPENCART_SERVER', 'https://www.opencart.com/');

Re: [SOLVED] Admin extensions - DDoS protection by Cloudflare and auto page refreshes

Posted: Fri Apr 10, 2020 8:14 am
by letxobnav
that is a bad idea.

Re: Admin extensions - DDoS protection by Cloudflare and auto page refreshes

Posted: Tue Oct 27, 2020 9:12 pm
by jvandemerwe
mr.who wrote:
Sat Apr 04, 2020 11:34 pm
:-\ what a solution ....
simple permenant fix :
go to : public_html/admin/controller/extension/extension/promotion.php
replace line 18 with :

Code: Select all

return '';
that's it
I would put the return here:

Code: Select all

class ControllerExtensionExtensionPromotion extends Controller {
	public function index() {
	     return '';
This avoids the curl init and execution.

Re: [SOLVED] Admin extensions - DDoS protection by Cloudflare and auto page refreshes

Posted: Thu Feb 04, 2021 11:41 am
by devwerkslab
Line 18 just worked great! thanks!

Re: [SOLVED] Admin extensions - DDoS protection by Cloudflare and auto page refreshes

Posted: Thu Feb 04, 2021 3:46 pm
by tingwing
the solution works perfectly

Re: [SOLVED] Admin extensions - DDoS protection by Cloudflare and auto page refreshes

Posted: Tue Mar 16, 2021 4:44 am
by Ozfarmer
Perefect :)

mr.who wrote: ↑
Sat Apr 04, 2020 11:34 pm
:-\ what a solution ....
simple permenant fix :
go to : public_html/admin/controller/extension/extension/promotion.php
replace line 18 with :
Code: Select all

return '';
that's it

Re: [SOLVED] Admin extensions - DDoS protection by Cloudflare and auto page refreshes

Posted: Fri Apr 29, 2022 5:51 pm
by Capogr
Thank you!