simple error display, should make it conditional

This commit is contained in:
Joost Agterhoek 2025-02-19 21:16:03 +01:00
parent 9a8acda499
commit c33c7a57f7
2 changed files with 28 additions and 5 deletions

View File

@ -96,6 +96,14 @@ body {
border-radius: 3px; border-radius: 3px;
} }
.errors-container {
display: flex;
justify-content: center;
padding: 10px 10px;
border-radius: 3px;
}
.results-table { .results-table {
padding: 50px 50px; padding: 50px 50px;
border-radius: 3px; border-radius: 3px;

View File

@ -1,6 +1,13 @@
<script src="https://ajax.googleapis.com/ajax/libs/jquery/3.5.1/jquery.min.js"></script> <script src="https://ajax.googleapis.com/ajax/libs/jquery/3.5.1/jquery.min.js"></script>
<script src="static/javascript.js"></script> <script src="static/javascript.js"></script>
<div class="errors-container">
<p>
<i>
You may have mistyped: </i><b>{{errors|join(',')}}</b><i>. Try again!</i>
</i>
</div>
<div class="table-container"> <div class="table-container">
<div class="results-table-new"> <div class="results-table-new">
<table id="data" class="table table-striped"> <table id="data" class="table table-striped">
@ -30,13 +37,23 @@
<tr> <tr>
<td colspan="7" id="info"> <td colspan="7" id="info">
<p> <p>
<b>VirusTotal</b>Vendor marked this host as malicious or suspicious: <b>VirusTotal</b>
<br>
{% if host.vt['score'] > 0 %}
Vendor marked this host as malicious or suspicious:
{{host.vt['vendors']|join(', ')}} {{host.vt['vendors']|join(', ')}}
{{host.vt['score']}}
{% else %}
No vendors marked this host as malicious or suspicious.
{% endif %}
<br>
<b>AbuseIPDB</b>
<br> <br>
IP address is: {{host.abuseipdb['IP_address']}}<br> IP address is: {{host.abuseipdb['IP_address']}}<br>
Is this Tor: {{host.abuseipdb['Tor']}}<br> Is this Tor: {{host.abuseipdb['Tor']}}<br>
Usage: {{host.abuseipdb['usage']}}<br> Usage: {{host.abuseipdb['usage']}}<br>
<br>
<!--Display some of the metadata info-->
</p> </p>
</td> </td>
</tr> </tr>
@ -46,9 +63,7 @@
</div> </div>
</div> </div>
{% for error in errors %}
{{error}}
{% endfor %}
{% block scripts %} {% block scripts %}