mirror of https://github.com/CIRCL/lookyloo
new: config option to make capture private by default, better working on capture page
Related #279pull/280/head
parent
05ab994728
commit
b4771f63a7
|
@ -7,8 +7,9 @@
|
||||||
"website_listen_ip": "0.0.0.0",
|
"website_listen_ip": "0.0.0.0",
|
||||||
"website_listen_port": 5100,
|
"website_listen_port": 5100,
|
||||||
"systemd_service_name": "lookyloo",
|
"systemd_service_name": "lookyloo",
|
||||||
|
"default_public": true,
|
||||||
"splash_url": "http://127.0.0.1:8050",
|
"splash_url": "http://127.0.0.1:8050",
|
||||||
"default_user_agent": "Mozilla/5.0 (Windows NT 10.0; Win64; x64) AppleWebKit/537.36 (KHTML, like Gecko) Chrome/81.0.4044.138 Safari/537.36",
|
"default_user_agent": "Mozilla/5.0 (Windows NT 10.0; Win64; x64) AppleWebKit/537.36 (KHTML, like Gecko) Chrome/94.0.4606.81 Safari/537.36",
|
||||||
"users": {},
|
"users": {},
|
||||||
"time_delta_on_index": {
|
"time_delta_on_index": {
|
||||||
"weeks": 1,
|
"weeks": 1,
|
||||||
|
@ -54,6 +55,7 @@
|
||||||
"website_listen_ip": "IP Flask will listen on. Defaults to 0.0.0.0, meaning all interfaces.",
|
"website_listen_ip": "IP Flask will listen on. Defaults to 0.0.0.0, meaning all interfaces.",
|
||||||
"website_listen_port": "Port Flask will listen on.",
|
"website_listen_port": "Port Flask will listen on.",
|
||||||
"systemd_service_name": "(Optional) Name of the systemd service if your project has one.",
|
"systemd_service_name": "(Optional) Name of the systemd service if your project has one.",
|
||||||
|
"default_public": "If true, the capture is public and will be visible on the index page by default (can be unticked on the capture page)."
|
||||||
"splash_url": "URL to connect to splash",
|
"splash_url": "URL to connect to splash",
|
||||||
"default_user_agent": "Ultimate fallback if the capture form, or the asynchronous submission, doesn't provide a user agent.",
|
"default_user_agent": "Ultimate fallback if the capture form, or the asynchronous submission, doesn't provide a user agent.",
|
||||||
"users": "It is some kind of an admin accounts. Format: {username: password}",
|
"users": "It is some kind of an admin accounts. Format: {username: password}",
|
||||||
|
|
|
@ -805,6 +805,7 @@ def _prepare_capture_template(user_ua: Optional[str], predefined_url: Optional[s
|
||||||
flash('The request will be enqueued, but capturing may take a while and require the administrator to wake up.', 'error')
|
flash('The request will be enqueued, but capturing may take a while and require the administrator to wake up.', 'error')
|
||||||
return render_template('capture.html', user_agents=user_agents, default=default_ua,
|
return render_template('capture.html', user_agents=user_agents, default=default_ua,
|
||||||
max_depth=max_depth, personal_ua=user_ua,
|
max_depth=max_depth, personal_ua=user_ua,
|
||||||
|
default_public=get_config('generic', 'default_public'),
|
||||||
predefined_url_to_capture=predefined_url if predefined_url else '')
|
predefined_url_to_capture=predefined_url if predefined_url else '')
|
||||||
|
|
||||||
|
|
||||||
|
|
|
@ -35,7 +35,7 @@
|
||||||
<div class="form-group row">
|
<div class="form-group row">
|
||||||
<div class="col-sm-10">
|
<div class="col-sm-10">
|
||||||
<div class="form-check">
|
<div class="form-check">
|
||||||
<input class="form-check-input" type="checkbox" name="listing" checked="true"></input>
|
<input class="form-check-input" type="checkbox" name="listing" {% if default_public %}checked="true"{% endif %}></input>
|
||||||
<label for="listing" class="form-check-label">Display results on public page</label>
|
<label for="listing" class="form-check-label">Display results on public page</label>
|
||||||
</div>
|
</div>
|
||||||
</div>
|
</div>
|
||||||
|
@ -89,7 +89,7 @@
|
||||||
<div class="col-sm-10">
|
<div class="col-sm-10">
|
||||||
<div class="form-check">
|
<div class="form-check">
|
||||||
<input class="form-check-input" type="checkbox" name="personal_ua"></input>
|
<input class="form-check-input" type="checkbox" name="personal_ua"></input>
|
||||||
<label for="personal_ua" class="form-check-label">Tick the box to use the current <a href="https://en.wikipedia.org/wiki/User_agent">user-agent</a> of your own browser:</br>
|
<label for="personal_ua" class="form-check-label">Use the current <a href="https://en.wikipedia.org/wiki/User_agent">user-agent</a> of your own browser:</br>
|
||||||
{{ personal_ua }}
|
{{ personal_ua }}
|
||||||
</label>
|
</label>
|
||||||
</div>
|
</div>
|
||||||
|
@ -144,7 +144,13 @@
|
||||||
{% endfor%}
|
{% endfor%}
|
||||||
<div class="dropdown-divider"></div>
|
<div class="dropdown-divider"></div>
|
||||||
<center>
|
<center>
|
||||||
<b>By default, the capture is public. If you do not want that, untick the box at the top of the form.</b>
|
<b>
|
||||||
|
{% if default_public %}
|
||||||
|
By default, the capture is public. If you do not want that, untick the box at the top of the form.
|
||||||
|
{% else %}
|
||||||
|
By default, the capture is private (not visible on the index page). If you want it to be public tick the box at the top of the form.
|
||||||
|
{% endif %}
|
||||||
|
</b>
|
||||||
</br>
|
</br>
|
||||||
</br>
|
</br>
|
||||||
<button type="submit" class="new-capture-button" id="btn-looking">Start looking!</button>
|
<button type="submit" class="new-capture-button" id="btn-looking">Start looking!</button>
|
||||||
|
|
Loading…
Reference in New Issue