|
|
@ -31,15 +31,15 @@ class difference_detection_processor():
|
|
|
|
|
|
|
|
|
|
|
|
from requests.structures import CaseInsensitiveDict
|
|
|
|
from requests.structures import CaseInsensitiveDict
|
|
|
|
|
|
|
|
|
|
|
|
# Protect against file:// access
|
|
|
|
url = self.watch.link
|
|
|
|
if re.search(r'^file://', self.watch.get('url', '').strip(), re.IGNORECASE):
|
|
|
|
|
|
|
|
|
|
|
|
# Protect against file:// access, check the real "link" without any meta "source:" etc prepended.
|
|
|
|
|
|
|
|
if re.search(r'^file://', url, re.IGNORECASE):
|
|
|
|
if not strtobool(os.getenv('ALLOW_FILE_URI', 'false')):
|
|
|
|
if not strtobool(os.getenv('ALLOW_FILE_URI', 'false')):
|
|
|
|
raise Exception(
|
|
|
|
raise Exception(
|
|
|
|
"file:// type access is denied for security reasons."
|
|
|
|
"file:// type access is denied for security reasons."
|
|
|
|
)
|
|
|
|
)
|
|
|
|
|
|
|
|
|
|
|
|
url = self.watch.link
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
# Requests, playwright, other browser via wss:// etc, fetch_extra_something
|
|
|
|
# Requests, playwright, other browser via wss:// etc, fetch_extra_something
|
|
|
|
prefer_fetch_backend = self.watch.get('fetch_backend', 'system')
|
|
|
|
prefer_fetch_backend = self.watch.get('fetch_backend', 'system')
|
|
|
|
|
|
|
|
|
|
|
|