How to clean up a board hit by spam
Description: This explains how to remove multiple spambot accounts and posts
In Categories: Administration
- Link to this article: Select All
[url=https://www.phpbb.com/support/docs/en/3.3/kb/article/how-to-clean-up-a-board-hit-by-spam/]Knowledge Base - How to clean up a board hit by spam[/url]
What is spam?
Spam is when undesirable topics or posts are made on your board from accounts trying to advertise products. These take various forms but are often for cheap phones, kitchens, tablets, porn sites etc. Most of the time they are made by automated scripts called spambots. These register on your board, just like a normal person would, and then proceed to post as quickly as they can to advertise their product. Alternatively they can lie dormant for days or weeks and be activated later on to post. A rarer alternative is that people are paid to sit and make the accounts. They can also appear to be legitimate posts (often copied from earlier in the topic) but have spam linked in their signature.
First of all, let's get some terminology right. If you have multiple spam accounts registering on your board you are NOT being hacked. Another misconception is that they are somehow bypassing the registration page. This is highly unlikely and is almost always due to a second, long forgotten phpBB installation using the same database, an incorrectly added or partially removed integrated registration system, such as WP-United or JFusion, or poorly chosen, and thus ineffective, antispam protection on the registration page.
If it's a board that's been left for several months without any Team interaction, it might not be worth keeping at all. Your real users would have left a long time ago.
Cleaning up after an attack
If you've been unfortunate enough to be hit by a spam attack you'll need to clean the board up again.
Multiple accounts and their posts can be removed in
Administration Control Panel > Users and Groups > Prune Users
You can choose to remove accounts after a certain date or you can select multiple specific accounts by clicking the 'Find a Member' link below the Prune Users entry box. You also have the option to delete their posts and the accounts as well at the same time.
NOTE: Deleting large numbers of accounts and/or multiple posts at the same time can often cause the server to time out. This usually means the accounts and post contents will be deleted but topic titles will be left 'orphaned' on the forum view pages. This means that when you try and open the topic you get a message that it does not exist. This can be fixed though.
Open the forum in question and click the Moderator Control Panel link at the top of the page. You can then tick each of the offending spam topics on the right of the screen and then select 'delete' from the drop list at the bottom of the page and submit. If you have a lot of topics to remove you can increase the number of topics per page in
General > Post Settings > Topics per page
Setting it to 500 should be fine.
Saving only some posts
If the board is new or for some other reason only has a few topics or posts you want to keep it may be quicker to:
- Create a new forum
ACP > FORUMS > Manage forums > forum name > Create new forum
- Split the topics containing the posts to be saved
- Move the new topics to be kept to the new forum
- Delete the other forums choosing the default option to delete existing posts
ACP > FORUMS > Manage forums > name of forum to be deleted >
- Recreate the board structure of categories and forums
- Move the saved topics back to the required location(s)
How can I stop them getting in again?
Read this topic for the latest tips on stopping spam.