apache-ultimate-bad-bot-blocker icon indicating copy to clipboard operation
apache-ultimate-bad-bot-blocker copied to clipboard

Why is the regex format different between files?

Open s22-tech opened this issue 4 years ago • 1 comments

Hey Mitchell,

I'm just curious why the format of the regex is different between the globalblacklist.conf and the blacklist-user-agents.conf

In globalblacklist.conf they are formatted as:

BrowserMatchNoCase "(?:\b)Scrapy(?:\b)" bad_bot

while in blacklist-user-agents.conf, they're formatted as:

BrowserMatchNoCase "^(.*?)(\bScrapy\b)(.*)$" bad_bot

Can either format be used? The reason I ask is that I prefer the format in globalblacklist.conf because when using a text editor like BBEdit, when double-clicking the agent, you only get the agent, i.e. Scrapy. But when selecting it in the other one, you end up with bScrapy selected.

Thanks, Marc

s22-tech avatar May 04 '21 18:05 s22-tech

I think I just forgot to update the include files, first regex is better

mitchellkrogza avatar Jun 14 '21 09:06 mitchellkrogza