Skip to content

A modern platform for visual, flexible, and extensible graph-based investigations. For cybersecurity analysts and investigators.

feat: import in try block

dextmorgn773e95f2f3c0
diff --git a/flowsint-api/Dockerfile b/flowsint-api/Dockerfile
index e59c81ea..48c8bfa5 100644
--- a/flowsint-api/Dockerfile
+++ b/flowsint-api/Dockerfile
@@ -4,7 +4,7 @@ WORKDIR /app
COPY . .
-RUN pip install --no-cache-dir -r requirements.txt git+https://github.com/soxoj/maigret
+RUN pip install --no-cache-dir -r requirements.txt git+https://github.com/soxoj/maigret ghunt
RUN apt-get update && \
apt-get install -y git whois dnsutils curl && \
diff --git a/flowsint-api/app/scanners/emails/ghunt_gmail_scanner.py b/flowsint-api/app/scanners/emails/ghunt_gmail_scanner.py
index 3a9be84c..37c0adeb 100644
--- a/flowsint-api/app/scanners/emails/ghunt_gmail_scanner.py
+++ b/flowsint-api/app/scanners/emails/ghunt_gmail_scanner.py
@@ -3,7 +3,6 @@ import json
import uuid
from typing import Dict, Any
from pathlib import Path
-from ghunt.modules import email as email_module
from app.scanners.base import Scanner
@@ -23,6 +22,7 @@ class GHuntGmailScanner(Scanner):
report_id = str(uuid.uuid4())
output_file = Path(f"/tmp/ghunt_{email}_email.json")
try:
+ from ghunt.modules import email as email_module
asyncio.run(email_module.hunt(None, email, output_file))
if not output_file.exists():
return {