understanding spamblock bee plugin...

Creating and modifying plugins.
Don Chambers
Regular
Posts: 3652
Joined: Mon Feb 13, 2006 2:40 am
Location: Chicago, IL, USA
Contact:

understanding spamblock bee plugin...

Post by Don Chambers »

Finally found the time to try out this plugin. This is the first event plugin in my queue. I have it configured as follows:
Use honeypot: yes
Use hidden captchas: reject comments
spam log type: don't log
Answer retrieval method: JSON
type of question: math problems
I see a field labeled "Phone". This seems to be the "honeypot" field, completion of which by a bot should reject the comment. Why do I see it at all? I see it has the class .comment_phone_input .. Do I need to style this myself, or should the plugin be emitting the appropriate css to hide it?

Next, I see the "hidden captcha". It's not hidden either. I see the math question, and depending on the answer retrieval method, the answer may, or may not be shown in the input field. Again, I am led to believe these things should not be seen by actual visitors, but rather are means against bot spam. Do I simply hide them myself via css, or is there an option I need to enable to emit the proper css?

EDIT: After more than a dozen or so previews, the two label/input pairs are now hidden. What happened? Also, no comment is allowed to be submitted due to this error: "Spam Prevention: Wrong Captcha."
=Don=
yellowled
Regular
Posts: 7111
Joined: Fri Jan 13, 2006 11:46 am
Location: Eutin, Germany
Contact:

Re: understanding spamblock bee plugin...

Post by yellowled »

Don Chambers wrote:

Code: Select all

Use honeypot: yes
Use hidden captchas: reject comments
spam log type: don't log
Answer retrieval method: JSON
type of question: math problems
First of all, I would set hidden captchas to moderate while you're still testing this. Also try setting retrieval method to standard (that's what I use right now).
Don Chambers wrote:EDIT: After more than a dozen or so previews, the two label/input pairs are now hidden. What happened?
Probably an issue with caching. The plugin usually adds the required CSS to your style.css, unless you (like I) don't use that file at all. In that case, you'd have to add the required styles yourself.
Don Chambers wrote: Also, no comment is allowed to be submitted due to this error: "Spam Prevention: Wrong Captcha."
Can't really state as to why this is happening, but some people have reported issue with the JS part of Spam Bee as far as I know.

You're right about the way all of this is supposed to work. Usually, phone gets left empty and the hidden captcha is solved by JS. Both are usually hidden for "normal" visitors or screen readers, but spam bots will "see" both fields (since they don't interpret CSS or JS) and a) fill out the phone field and b) fail to solve the math question. "Normal" visitors will leave the phone field empty, JS will solve the math question and they will pass the test.

I assume this is due to your settings and caching. Just in case, have you tried this in different browsers? Have you cleaned out templates_c?

YL
Don Chambers
Regular
Posts: 3652
Joined: Mon Feb 13, 2006 2:40 am
Location: Chicago, IL, USA
Contact:

Re: understanding spamblock bee plugin...

Post by Don Chambers »

the hidden/showing issue could have been a caching issue... my bigger concern now is that I cannot really get this to work at all in firefox. It always thinks the captcha is incorrect regardless of the retrieval method. I even tried submitting a comment on Grischa's blog entry and that was also rejected as spam.

I was successful at submitting comments using IE9 on my test site, but my comments on Grischa's site are also rejected with IE9. Could this be cookie related? Maybe once rejected, always rejected?
=Don=
yellowled
Regular
Posts: 7111
Joined: Fri Jan 13, 2006 11:46 am
Location: Eutin, Germany
Contact:

Re: understanding spamblock bee plugin...

Post by yellowled »

No idea. I'll notify Grischa via Twitter to get his ass over here. :mrgreen:

YL
Timbalu
Regular
Posts: 4598
Joined: Sun May 02, 2004 3:04 pm

Re: understanding spamblock bee plugin...

Post by Timbalu »

Well, its not an answer...
But I remember having this "caching" issue too, which needed some few reloads to pass by and leaving me feel uneasy about it....

After then it seemed to work and I left it as is to gather some experiences. The log was swelling with all these really happy bots now trying to hook-in into an uncaptchered comment form and getting well rejected for some weeks.

Last week I suddenly had 50 spam comments (those ones posting blog entries and comments from all over the internet - all including these funny spelling errors and non converted utf-8 marks) in my mail folder, which seemed to have passed the bee-honeypot. I then learned bayes with them, which did stop this hopefully - but I am not sure about that.

It would be nice to have bayes only learn these funny error and non-converted-utf-8 words, while 98%++ of these post are common text as also valid users would write into a comment. Also it would make sense to have a backend infomation and verification screen for those spam-bee log entries, to really know what is going on.
Regards,
Ian

Serendipity Styx Edition and additional_plugins @ https://ophian.github.io/ @ https://github.com/ophian
Don Chambers
Regular
Posts: 3652
Joined: Mon Feb 13, 2006 2:40 am
Location: Chicago, IL, USA
Contact:

Re: understanding spamblock bee plugin...

Post by Don Chambers »

After over a dozen rejections, and turning the hidden captcha on and off several times, it finally started working.. I have no explanation.

Something else I have noticed - when first activated, it takes several page views before the css is emitted to hide both the honeypot and the hidden captcha..... and this is browser independent.
=Don=
blog.brockha.us
Regular
Posts: 695
Joined: Tue Jul 03, 2007 3:34 am
Location: Berlin, Germany
Contact:

Re: understanding spamblock bee plugin...

Post by blog.brockha.us »

About the caching: The CSS classes are emitted with the normal serendipity.css. This file seems to be heavily cached. I had the same problem when I started the Bee. I had to do Ctrl-R (full page reload) several times, to have the correct css. This could be worked around by not having the Bee CSS in the main CSS but in an separate CSS file (what would work on blogs like Yellowleds w/o a main CSS, too).

Reading my SPAM logs it starts to get interesting. First you commented using this browser:
Mozilla/5.0 (Windows NT 6.1; WOW64; rv:15.0) Gecko/20100101 Firefox/15.0.1
So: Firefox 15. The Spam Bee had no problem with your comment, but the Bayes reported it as Spam (as it was English and 99.9% of the English comments are SPAM in my blog and Bayes learned that).

Then you used this one:
Mozilla/5.0 (compatible; MSIE 9.0; Windows NT 6.1; WOW64; Trident/5.0)

This seems to be an Internet Explorer, right? IE9? These comments were moderated by the Bee (as the number was answered wrong!) and rejected after by the Bayes.

So this looks like a problem with IE9 and the SpamBee, perhaps. Or was there perhaps a cache acting bad on that tries? I'm not sure. I don't use the IE, so I can't test this atm.
- Grischa Brockhaus - http://blog.brockha.us
- Want to make me happy? http://wishes.brockha.us/
blog.brockha.us
Regular
Posts: 695
Joined: Tue Jul 03, 2007 3:34 am
Location: Berlin, Germany
Contact:

Re: understanding spamblock bee plugin...

Post by blog.brockha.us »

Timbalu wrote:Also it would make sense to have a backend infomation and verification screen for those spam-bee log entries, to really know what is going on.
You have. Set the bee to moderate and you can see the comments at your moderation screen. In my case there is the problem, that the Bee moderates and the Bayes denies the same comment. So I'll find the Bee moderated comments in the Bayes trash always ..

And put the logging to database. I use this and can see there, why and with what browser a comment was moderated by the Bee (and other AntiSpam plugins).
- Grischa Brockhaus - http://blog.brockha.us
- Want to make me happy? http://wishes.brockha.us/
Don Chambers
Regular
Posts: 3652
Joined: Mon Feb 13, 2006 2:40 am
Location: Chicago, IL, USA
Contact:

Re: understanding spamblock bee plugin...

Post by Don Chambers »

Thanks for checking into this Grischa. If you can emit your css some other way, then that might be a good idea. Another reason for doing so is that embedded blogs don't use serendipity.css either.

I do not know why IE9 would have been showing the wrong number. Would you like me to try it again?

What I found most confusing was on my own test site, the comments were being rejected by the plugin even when the math answer was correct. I eventually cleared it by enabling the option, and disabling it several times. Eventually it just worked.
=Don=
Timbalu
Regular
Posts: 4598
Joined: Sun May 02, 2004 3:04 pm

Re: understanding spamblock bee plugin...

Post by Timbalu »

blog.brockha.us wrote:
Timbalu wrote:Also it would make sense to have a backend infomation and verification screen for those spam-bee log entries, to really know what is going on.
You have. Set the bee to moderate and you can see the comments at your moderation screen. In my case there is the problem, that the Bee moderates and the Bayes denies the same comment. So I'll find the Bee moderated comments in the Bayes trash always ..

And put the logging to database. I use this and can see there, why and with what browser a comment was moderated by the Bee (and other AntiSpam plugins).
Hi Grischa

Yes, I also do log to the database. That saying and controlling with PhpMyAdmin, I wished I could see that in Backend... and even get some better consumption which kind of bot sends how much, by which date and time, does it change over time, is it a dummy or flexible bot, etc. The point is, to learn from a honeypot..., which leads to finetune things.
The first does not make sense to me, as I do not want to moderate obviously Spam attacks, to say 100 a day... But from time to time I would like to have a controlling, what kind of Bots stick to the bee...
Fishing set moderate comments out of bayes trash isn't good either...
Regards,
Ian

Serendipity Styx Edition and additional_plugins @ https://ophian.github.io/ @ https://github.com/ophian
Timbalu
Regular
Posts: 4598
Joined: Sun May 02, 2004 3:04 pm

Re: understanding spamblock bee plugin...

Post by Timbalu »

Hi Grischa

Matthias just installed a testblog, which alerted with an error in entryproperties, but in his log I found spambee's config settings appear like this:

Code: Select all

                    [/header_desc] =>
                    [/do_honeypot] => 1
                    [/do_hiddencaptcha] => MODERATE
                    [/spamlogtype] => none
                    [/spamlogfile] => /var/www/virtual/xxxxx/sub.domain.tld/spamblock.log
                    [/plugin_path] => /plugins/serendipity_event_spamblock_bee/
                    [/advanced_cc_desc] =>
                    [/answer_retrieval_method] => default
                    [/question_type] => math
                    [/questions] => Frage1
Frage2
                    [/answers] => Antwort1
Antwort2
                    [/use_regexp] =>
in the Serendipity array. This looks somehow weird! Could you check that, please?! All other plugins have the plugin name with the instance in front.
Regards,
Ian

Serendipity Styx Edition and additional_plugins @ https://ophian.github.io/ @ https://github.com/ophian
yellowled
Regular
Posts: 7111
Joined: Fri Jan 13, 2006 11:46 am
Location: Eutin, Germany
Contact:

Re: understanding spamblock bee plugin...

Post by yellowled »

You should probably report that on GitHub in the additional_plugins issues. It's more likely Grischa will notice it there.

YL
Timbalu
Regular
Posts: 4598
Joined: Sun May 02, 2004 3:04 pm

Re: understanding spamblock bee plugin...

Post by Timbalu »

Or you could give him another twitter "Stubs" to come back! :wink:
Regards,
Ian

Serendipity Styx Edition and additional_plugins @ https://ophian.github.io/ @ https://github.com/ophian
yellowled
Regular
Posts: 7111
Joined: Fri Jan 13, 2006 11:46 am
Location: Eutin, Germany
Contact:

Re: understanding spamblock bee plugin...

Post by yellowled »

That's not very likely to work much faster. Plus, it's less work for me. :mrgreen:

YL
blog.brockha.us
Regular
Posts: 695
Joined: Tue Jul 03, 2007 3:34 am
Location: Berlin, Germany
Contact:

Re: understanding spamblock bee plugin...

Post by blog.brockha.us »

Hmm.. That's strange and I can reproduce it.
Did Matthias installed the Bee's sidebar plugin once?

Edit: Forget the question. I can reproduce this even when saving the normal plugins config. It saves statically not per instance. I'll investigate this.
- Grischa Brockhaus - http://blog.brockha.us
- Want to make me happy? http://wishes.brockha.us/
Post Reply