Skip to content
Open
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension


Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
5 changes: 1 addition & 4 deletions iot_inspector/admin.py
Original file line number Diff line number Diff line change
Expand Up @@ -10,7 +10,6 @@
client_generate_report,
client_get_report_link,
client_login,
client_upload_firmware,
get_default_product_group,
)
from .models import AnalysisRequest, IOTUser
Expand All @@ -35,9 +34,7 @@ def validate_status(self, request, queryset):
if not analysis_request.firmware_uuid:
client = client_login(iot_user)
default_product_group = get_default_product_group(client)
firmware = client_upload_firmware(
client, analysis_request, default_product_group
)
firmware = {"id": "ONEKEY removed"} # TODO: Find a replacement for ONKEY firmware analisys
firmware_uuid = firmware["id"]
analysis_request.firmware_uuid = firmware_uuid
analysis_request.status = True
Expand Down
13 changes: 0 additions & 13 deletions iot_inspector/helpers.py
Original file line number Diff line number Diff line change
Expand Up @@ -7,7 +7,6 @@
from decouple import config
from django.core.files.storage import FileSystemStorage
from django.core.signing import Signer
from onekey_client import Client, FirmwareMetadata

from testing_platform import settings

Expand Down Expand Up @@ -111,18 +110,6 @@ def get_default_product_group(client):
return default_product_group


def client_upload_firmware(client, analysis_request, default_product_group):
metadata = FirmwareMetadata(
name=analysis_request.name,
vendor_name=analysis_request.vendor_name,
product_name=analysis_request.product_name,
product_group_id=default_product_group["id"],
)
firmware_path = Path(analysis_request.file.path)
res = client.upload_firmware(metadata, firmware_path, enable_monitoring=True)
return res


def client_get_or_generate_report_config(client):
GET_ALL_REPORT_CONFIGS = """
query {
Expand Down
13 changes: 0 additions & 13 deletions iot_inspector/helpers_old.py
Original file line number Diff line number Diff line change
Expand Up @@ -7,7 +7,6 @@
from decouple import config
from django.core.files.storage import FileSystemStorage
from django.core.signing import Signer
from onekey_client import Client, FirmwareMetadata

from testing_platform import settings

Expand Down Expand Up @@ -111,18 +110,6 @@ def get_default_product_group(client):
return default_product_group


def client_upload_firmware(client, analysis_request, default_product_group):
metadata = FirmwareMetadata(
name=analysis_request.name,
vendor_name=analysis_request.vendor_name,
product_name=analysis_request.product_name,
product_group_id=default_product_group["id"],
)
firmware_path = Path(analysis_request.file.path)
res = client.upload_firmware(metadata, firmware_path, enable_monitoring=True)
return res


def client_get_or_generate_report_config(client):
GET_ALL_REPORT_CONFIGS = """
query {
Expand Down
8 changes: 0 additions & 8 deletions landing_page/templates/dashboard.html
Original file line number Diff line number Diff line change
Expand Up @@ -61,14 +61,6 @@ <h3 class="text-primary-primary-blue">Toolbox</h3>
<span class="font-size-20 fw-bold lh-sm text-blue-gradient mb-2">E-Mail Policy Generator</span>
<span class="font-size-16 lh-sm text-muted">Create DMARC and/or SPF policies which help you to enhance your e-mail security!</span>
</div>

<div class="card-link rounded-box-20 d-flex flex-1 align-items-start flex-column box-shadow multi-purpose-gray-200_border multi-purpose-gray-50_background-hover" data-href="/iot-testing/">
<span class="background-icon primary-primary-blue_background mb-3">
<svg xmlns="http://www.w3.org/2000/svg" height="24px" viewBox="0 -960 960 960" width="24px" fill="#e8eaed"><path d="M221-240q42 0 71-29t29-71q0-24-11-47t-33-37l-36-24v-252q0-9-5.5-14.5T221-720q-9 0-14.5 5.5T201-700v252l-36 24q-22 15-33 37t-11 47q0 42 29 71t71 29Zm0 80q-75 0-127.5-52T41-340q0-48 22-86t58-62v-212q0-42 29-71t71-29q42 0 71 29t29 71v212q36 24 58 62t22 86q0 75-52.5 127.5T221-160Zm327-200q-48-33-78-85t-30-115q0-100 70-170t170-70q100 0 170 70t70 170q0 63-30 115t-78 85H548Zm28-80h212q27-24 39.5-54t12.5-66q0-66-47-113t-113-47q-66 0-113 47t-47 113q0 36 14.5 66t41.5 54Zm104 280q-24 0-42-18t-18-42h120q0 24-18 42t-42 18Zm-120-80v-80h240v80H560ZM221-340Zm459-240Z"/></svg>
</span>
<span class="font-size-20 fw-bold lh-sm text-blue-gradient mb-2">IOT Firmware Testing</span>
<span class="font-size-16 lh-sm text-muted">Check your IOT firmware binary!</span>
</div>
<div class="card-link rounded-box-20 d-flex flex-1 align-items-start flex-column box-shadow multi-purpose-gray-200_border multi-purpose-gray-50_background-hover" data-href="/infra-testing/file-test">
<span class="background-icon primary-primary-blue_background mb-3">
<svg xmlns="http://www.w3.org/2000/svg" height="24px" viewBox="0 -960 960 960" width="24px" fill="#e8eaed"><path d="M420-360h120l-23-129q20-10 31.5-29t11.5-42q0-33-23.5-56.5T480-640q-33 0-56.5 23.5T400-560q0 23 11.5 42t31.5 29l-23 129Zm60 280q-139-35-229.5-159.5T160-516v-244l320-120 320 120v244q0 152-90.5 276.5T480-80Zm0-84q104-33 172-132t68-220v-189l-240-90-240 90v189q0 121 68 220t172 132Zm0-316Z"/></svg>
Expand Down
Empty file removed onekey/__init__.py
Empty file.
39 changes: 0 additions & 39 deletions onekey/admin.py

This file was deleted.

6 changes: 0 additions & 6 deletions onekey/apps.py

This file was deleted.

19 changes: 0 additions & 19 deletions onekey/forms.py

This file was deleted.

198 changes: 0 additions & 198 deletions onekey/helpers.py

This file was deleted.

Loading
Loading