mirror of https://gitlab.com/bashrc2/epicyon
Merge branch 'main' of ssh://code.freedombone.net:2222/bashrc/epicyon
commit
bd0ef3abd9
|
|
@ -466,6 +466,8 @@ class PubServer(BaseHTTPRequestHandler):
|
|||
# is this a web crawler? If so the block it
|
||||
agentStrLower = agentStr.lower()
|
||||
if 'bot/' in agentStrLower or 'bot-' in agentStrLower:
|
||||
if self.server.newsInstance:
|
||||
return False
|
||||
print('Blocked Crawler: ' + agentStr)
|
||||
return True
|
||||
# get domain name from User-Agent
|
||||
|
|
|
|||
Loading…
Reference in New Issue