Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Hiding blocked topics/posts in messageboards? #781

Open
sudara opened this issue Dec 11, 2018 · 7 comments
Open

Hiding blocked topics/posts in messageboards? #781

sudara opened this issue Dec 11, 2018 · 7 comments

Comments

@sudara
Copy link
Contributor

sudara commented Dec 11, 2018

Hi there!

We get daily user signups to our site (despite captchas) posting spam to our thredded forums. We use moderation so they have to be pre-approved and we have multiple moderators — the problem is when I hit "block" I'd love for none of us to have to ever see the post again (except when explicitly going into moderation.) Currently we see all the blocked posts in the list of topics on the messageboard, which clutters the experience for all mods. Is there an easy way to tell the messageboard list not to show these by default?

As an aside: has anyone hooked up akismet that you know of? This would auto-moderate most of the type of spam we are seeing so I'm thinking again about giving this a go.

@glebm
Copy link
Collaborator

glebm commented Dec 12, 2018

Perhaps you can avoid spam by adding invisible_captcha on registration?

Here is how thredded_create_app does it:

https://github.com/thredded/thredded_create_app/blob/master/lib/thredded_create_app/tasks/add_invisible_captcha.rb

It effectively reduced the number of spam signups to 0 for my forums.

@sudara
Copy link
Contributor Author

sudara commented Dec 19, 2018

@glebm Thanks for the recommendation. I'm willing to try anything! Sounds easier to evaluate invisible captcha than to integrate akismet. However, I worry that my spam signups are manual. I guess we'll find out!

I guess that means that between spam and abuse, you don't moderate many posts? In the moment, our forums are basically filled with moderated posts until the daily pruning (manual deletion).

Let's see if invisible captcha renders the problem moot!

@glebm
Copy link
Collaborator

glebm commented Dec 20, 2018

I don't moderate many posts yeah.

Is there an easy way to tell the messageboard list not to show these by default?

You'd need to add and implement a setting to Thredded.
Currently this cannot be done with the permissions system alone as that applies everywhere.

@sudara
Copy link
Contributor Author

sudara commented Dec 20, 2018

Thanks! I enabled the invisible_captcha to registration yesterday, but we still saw user signups and forum spam overnight.

I'm going to go through the data and make sure, but for now I'll close this out. I think the solution is to add akismet to our user signups rather than to anything forum-related. We need to catch people at the gate vs. worry about what people are creating when they get through the gates :)

Thanks for the help again!

@sudara sudara closed this as completed Dec 20, 2018
@sudara
Copy link
Contributor Author

sudara commented Jul 30, 2019

This is still an open issue for us. Despite using various combos of captcha, invisible_captcha, honeypots, anti-spam services and email validation we still see a trickle of spammy users who get through and create forum spam before we can block them.

In threaded, all mods see the blocked threads until they are deleted. So moderation for us involves blocking + manually deleting each post.

I'm thinking of what the simplest solution might be — maybe applying a blocked class or stimulus state to the <article> and then having an option to hide those by default?

image

@sudara sudara reopened this Jul 30, 2019
@sudara
Copy link
Contributor Author

sudara commented Jul 30, 2019

Related — if we spam / delete a user then we basically can't "block" posts anymore.

ActiveRecord::RecordInvalidthredded/moderation#moderate_post
Validation failed: User must exist

Another option for us would be to add "mark user as spam" or "delete user" to the normal moderation actions of "approve" / "block" — some sort of custom moderation action...

@glebm
Copy link
Collaborator

glebm commented Sep 7, 2019

Consider adding a setting to Thredded to hide blocked content.

It can then be applied in topics#index and topics#show:

page_scope = policy_scope(messageboard.topics)

page_scope = policy_scope(topic.posts)

Something like this should do it:

scope = policy_scope(messageboard.topics)
scope = scope.not_blocked unless Thredded.show_blocked_content_to_moderators

The not_blocked scope will need to be added to app/models/concerns/thredded/content_moderation_state.rb:

scope :not_blocked, -> { where.not(moderation_state: moderation_states[:blocked]) }

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
Development

No branches or pull requests

3 participants