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
Disable spamlist in configuration #15743
Comments
@john357smith just out of curiosity: your ads are shown on sites that are marked as referrerspam? Or why wouldn't they show up with the list active? Maybe there are some false positives on the list then 🤔 |
And that's the problem with this blacklist - everyone can add to it any site he wants. I'm using popads.net and yes this site is blacklisted because somebody was browsing whatever he wanted, saw this domain as an ads provider and put it here with no other reason. And no, you can't be spammed without buying traffic for your domain and verify it's really your domain ... |
@john357smith feel free to create an issue or PR for the referrer spam blacklist to remove it here: https://github.com/matomo-org/referrer-spam-blacklist |
That would be totally useless. The only correct solution is to have option to disable it. |
BTW @john357smith I know it's not a real workaround but if may work depending on your server. Like you could have a cronjob to empty the file containing the spammers every minute until someone works on this issue. In case you are familiar with PHP feel free to issue a PR with a setting for this 👍 |
I'm familiar with PHP that's why I have already modified code according the proposed change in my first comment so for me I have not only workaound but final solution. But I don't want to fix it after every update. So it seems I have to create a PR anyway ... |
fixed with #15744 |
Spam blacklist stored in spammers.txt can't be disabled by any configuration parameters nor this functionality is not mentioned anywhere in administration section. I spent couple of hours with finding why my properly bought ads are not counted in Matomo statistics!
Solution is simple. Replace core/Tracker/VisitExcluded.php code:
if (!$excluded) { $excluded = $this->isReferrerSpamExcluded(); if ($excluded) { Common::printDebug("Referrer URL is blacklisted as spam."); } }
with:
$generalConfig = Config::getInstance()->General; if (!$generalConfig['disable_spam_excluding']) { if (!$excluded) { $excluded = $this->isReferrerSpamExcluded(); if ($excluded) { Common::printDebug("Referrer URL is blacklisted as spam."); } } } else Common::printDebug("Spam blacklist is disabled.");
(and of course add use
Piwik\Config;
to import definition).The text was updated successfully, but these errors were encountered: