I'm using Google Analytics and I'm using filters to remove referral spams. In my web.config
file, I also use this:
<rule name="buy-cheap-online.info" patternSyntax="Wildcard" stopProcessing="true">
<match url="*" />
<conditions>
<add input="{HTTP_REFERER}" pattern="*.buy-cheap-online.info" />
</conditions>
<action type="AbortRequest" />
</rule>
I have dozens of these rules and I want to add more. There's this file on GitHub that includes a list of spammers: https://github.com/piwik/referrer-spam-blacklist/blob/master/spammers.txt
I could just keep adding rules to the web.config
but it seems messy. What's another way to block referral spam traffic in asp.net so that all the sites in the text file can be blocked and if the file changes I can easily add new sites by reuploading the text file?
Note: I'm not asking for code to be written for me; I just want to know what other options I have.