diff --git a/config/generic.json.sample b/config/generic.json.sample index 8d5eebf..507fa01 100644 --- a/config/generic.json.sample +++ b/config/generic.json.sample @@ -13,6 +13,7 @@ }, "max_depth": 1, "use_user_agents_users": false, + "enable_default_blur_screenshot": false, "enable_mail_notification": false, "email": { "from": "Lookyloo ", @@ -33,6 +34,7 @@ "time_delta_on_index": "Time interval of the capture displayed on the index", "max_depth": "Maximum depth for scraping. Anything > 1 will be exponentially bigger.", "use_user_agents_users": "Only usable for medium/high use instances: use the user agents of the users of the platform", + "enable_default_blur_screenshot": "If true, blur the screenshot by default (useful on public instances)", "enable_mail_notification": "Enable email notification or not", "email": "Configuration for sending email notifications." } diff --git a/website/web/__init__.py b/website/web/__init__.py index c52a53e..14da5e2 100644 --- a/website/web/__init__.py +++ b/website/web/__init__.py @@ -44,6 +44,7 @@ lookyloo: Lookyloo = Lookyloo() user = lookyloo.get_config('cache_clean_user') time_delta_on_index = lookyloo.get_config('time_delta_on_index') +blur_screenshot = lookyloo.get_config('enable_default_blur_screenshot') logging.basicConfig(level=lookyloo.get_config('loglevel')) @@ -419,6 +420,7 @@ def tree(tree_uuid: str, urlnode_uuid: Optional[str]=None): return render_template('tree.html', tree_json=tree_json, start_time=start_time, user_agent=user_agent, root_url=root_url, tree_uuid=tree_uuid, meta=meta, enable_mail_notification=enable_mail_notification, + blur_screenshot=blur_screenshot, urlnode_uuid=urlnode_uuid, has_redirects=True if cache['redirects'] else False) except NoValidHarFile as e: diff --git a/website/web/static/tree.css b/website/web/static/tree.css index 6c4fe9b..4f0a8d0 100644 --- a/website/web/static/tree.css +++ b/website/web/static/tree.css @@ -56,14 +56,8 @@ background: #fff; } -#screenshot { - position: fixed; - top: 5px; - right: 5px; - background: white; - border: 2px solid; - height: 1030px; - overflow: hidden; +.blur { + filter: blur(10px); } #legend_container { diff --git a/website/web/templates/tree.html b/website/web/templates/tree.html index 93e5414..018c450 100644 --- a/website/web/templates/tree.html +++ b/website/web/templates/tree.html @@ -240,7 +240,15 @@