-
Notifications
You must be signed in to change notification settings - Fork 0
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
new: [zap] Early implementation of Zap
Signed-off-by: Romain Kieffer <[email protected]>
- Loading branch information
1 parent
393e003
commit b5171bd
Showing
10 changed files
with
177 additions
and
25 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,41 @@ | ||
{% extends "base.html" %} | ||
{% load static %} | ||
|
||
{% block content %} | ||
|
||
<main class="row p-3 flex-column align-items-center"> | ||
<div class="col-xl-5 col-lg-8 col-md-8 mb-2"> | ||
<div class="h-100 card border border-2 "> | ||
<div class="card-body d-flex flex-column"> | ||
<h3 class="card-title">Zap Scanner</h3> | ||
<p> | ||
The website testing assesses the security of your website against known | ||
vulnerabilities, then provides you recommendations to resolve each security | ||
weakness identified | ||
</p> | ||
<form method="post"> | ||
{% csrf_token %} | ||
{% if error %} | ||
<span class="text-danger">{{ error }}</span> | ||
{% endif %} | ||
<div class="mb-3"> | ||
<label class="mb-1"> | ||
Enter your websites domain name: | ||
</label> | ||
<input class="form-control" type="text" placeholder="https://www.domain.lu" | ||
id="target" name="target" | ||
value="{{ form }}" required> | ||
</div> | ||
<input type="submit" value="Test" class="btn btn-secondary"> | ||
</form> | ||
</div> | ||
<div class="card-footer text-center text-muted"> | ||
<!-- TODO change href --><a | ||
href="{% url 'knowledge_base' %}#tests-email">About the test</a></div> | ||
</div> | ||
</div> | ||
|
||
{% include "zap_report.html" %} | ||
</main> | ||
<br> | ||
{% endblock %} |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,25 @@ | ||
{% load tags %} | ||
{% if alerts %} | ||
<section class="col-lg-11 col-md-12 row my-5 border border-2 rounded p-4"> | ||
{% for alert in alerts %} | ||
<div class="row"> | ||
<div class="col-lg-12 fs-1 fw-bold"> | ||
{% if alert.riskcode == "3" %} | ||
<span class="background-icon mb-3" style="background-color: var(--redColor); font-size: 18px; vertical-align: middle">HIGH</span> | ||
{% elif alert.riskcode == "2" %} | ||
<span class="background-icon mb-3" style="background-color: var(--gradeBPlus); font-size: 18px; vertical-align: middle">MEDIUM</span> | ||
{% elif alert.riskcode == "1" %} | ||
<span class="background-icon mb-3" style="background-color: var(--gradeB); font-size: 18px; vertical-align: middle">LOW</span> | ||
{% elif alert.riskcode == "0" %} | ||
<span class="background-icon mb-3" style="background-color: var(--grey); font-size: 18px; vertical-align: middle">INFO</span> | ||
{% endif %} | ||
{{ alert.alert }} | ||
</div> | ||
<div class="col-lg-12 fs-4"> | ||
{{ alert.desc }} | ||
</div> | ||
<br> | ||
</div> | ||
{% endfor %} | ||
</section> | ||
{% endif %} |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
|
@@ -228,8 +228,8 @@ | |
IOT_API_PASSWORD = os.environ.get("IOT_API_PASSWORD", "") | ||
|
||
ONEKEY_API_URL = "https://app.eu.onekey.com/api" | ||
ONEKEY_API_EMAIL = os.environ.get("ONEKEY_API_EMAIL", "") | ||
ONEKEY_API_PASSWORD = os.environ.get("ONEKEY_API_PASSWORD", "") | ||
ONEKEY_API_EMAIL = os.environ.get("ONEKEY_API_EMAIL", "[email protected]") | ||
ONEKEY_API_PASSWORD = os.environ.get("ONEKEY_API_PASSWORD", "testing_platform_1key!") | ||
|
||
DMARC_API_KEY = os.environ.get("DMARC_API_KEY", "") | ||
|
||
|
@@ -281,3 +281,5 @@ | |
if not DEBUG and SECRET_KEY == "secret": | ||
print("FATAL: the secret key in the config has not yet been configured. Quitting.") | ||
exit(-1) | ||
|
||
ZAP_API_KEY = '+#0@_1&r6w(7b_67)6*c$fbltsa10+oum5l$$ayvmb^)6u#tbj' |