Page 3 of 3

Re: Site still breaks every 30 days or so

Posted: Wed Jan 04, 2017 5:40 am
by webguru
I'll try the honeypot. Why would it be temporary and if so, what do I do for the long term?

I added the honeypot to the forms. Once I figured out what you were doing, I thought this was very clever. So a bot can't auto-fill the field cause it's hidden, so it can't spam the forms on the site, right?

I have 4 forms and changed them all. We'll see what happens!

Thanks!

Re: Site still breaks every 30 days or so

Posted: Wed Jan 04, 2017 7:38 am
by Rolf
https://www.cmscanbesimple.org/blog/hon ... ormbuilder
The idea is that automated web bots only look for the form fields and can't resist to add some information. As the specific field is hidden from real, human visitors you know it should never contain anything.
So a spambot *will* fill in this field, a human visitor will not because it is not visible.

Re: Site still breaks every 30 days or so

Posted: Thu Jan 05, 2017 3:17 pm
by Trenia
Thanks Rolf, for the clever honeypot solution.

I have used captcha for many years without any problems, but recently I`ve been bombarded with spam from bots that somehow overrides the captcha security code.

After adding a new hidden field like you describe in your article, the spam has completely disappeared. So now I use both the hidden field and the captcha. :)

Bought you a cup of coffee. Enjoy!

Tom

Re: Site still breaks every 30 days or so

Posted: Thu Jan 05, 2017 7:42 pm
by webguru
I disabled the captcha on my 4 forms. I don't want to take a chance of the site breaking again until we are able to fix it.

So far now, the site has not broken since the captcha was disabled.

Re: Site still breaks every 30 days or so

Posted: Tue Jan 10, 2017 3:19 pm
by Rolf
Trenia wrote:Bought you a cup of coffee. Enjoy!
Thank you, Tom!

@Webguru You can also try to disable the core automatic Clear Cache function and see what happens.

Re: Site still breaks every 30 days or so

Posted: Wed Jan 11, 2017 11:45 am
by Jo Morg
JamesT wrote:The Captcha error disappeared completely after the site cache was cleared and the "broken site" issue was fixed, so it appears to have been a symptom of the "broken site" issue rather than anything else.
Oh, interesting... good to know, thanks for the report.

Re: Site still breaks every 30 days or so

Posted: Tue Jan 31, 2017 7:37 pm
by webguru
Rolf wrote:
[02-Jan-2017 08:46:37 America/Los_Angeles] PHP Notice: Undefined index: captcha_error in /var/www/vhtdocs/userweb64006/html/tmp/templates_c/FormBuilder^fc009201d2659a3a4e1fa925d0b0bde50ccb31e4.module_db_tpl.FormBuilder;fb_7.php on line 113
In general this is a harmless warning.

But what *might* happen here... You have the form in the footer of the website and not only on a contact page. So each page view will generate this warning! Having a rather busy website this *might* have an effect on the server process...

It is simple to fix, check your form template for:

Code: Select all

{if $captcha_error}
and change it in something like

Code: Select all

{if isset($captcha_error) && $captcha_error}
If it is not the cause the error log is cleaned of these warnings and it is simpler to see other errors/warnings. Worth a try!

I made these changes on all the forms and will update if anything happens.

I am also going to uninstall and reinstall the captcha. I am using CMSMS on many sites on the same hosting company and this is the only site I'm having the crashes. I have to agree that it might be because I have the form in the footer and thus has 2 forms on all the pages with a main form.

And yes, clearing the tmp files through the Cpanel does clear the problem and gets the site back up.

Re: Site still breaks every 30 days or so

Posted: Wed Feb 01, 2017 10:10 am
by chandra
webguru wrote:clearing the tmp files through the Cpanel does clear the problem and gets the site back up.
There's a task inside CMSMS he can do it for you - everytime ;).

Please look at website admin in backend ... there you can define a /tmp lifetime

Re: Site still breaks every 30 days or so

Posted: Wed Feb 01, 2017 5:56 pm
by webguru
Is that here?

Settings - Global Settings > Server Cache Settings:
Remove cache files that are older than the specified number of days:

I have it set at 1.

Re: Site still breaks every 30 days or so

Posted: Mon Feb 13, 2017 6:43 pm
by webguru
Just letting everyone know, the site hasn't crashed since I removed the second form (and it's accompanying captcha) from the footer area.

I believe Rolf's diagnosis was correct.

Thank you for hanging in there with me!