Files
NeuroSploit/legacy/backend_fastapi/schemas/report.py
T
CyberSecurityUP a5badefc29 v3.3.0 GUI dashboard + reports + model expansion + root fix
Engine:
- Fix: inject IS_SANDBOX=1 so Claude Code's --dangerously-skip-permissions
  works under root (real backend runs were exiting rc=1 immediately)
- models: expand to 40 models / 13 providers, tagged CLI vs API
  (NVIDIA NIM, DeepSeek, Mistral, Qwen/DashScope, Groq, Together, OpenRouter,
  Ollama, Gemini) — Qwen/DeepSeek/Llama usable via API
- backends: on_start callback surfaces the exact argv ("what runs behind it")
- orchestrator: require a Playwright screenshot per confirmed finding; collect
  results/activity.json; auto-generate reports after a run
- report.py: HTML always + PDF via Typst engine (.typ source emitted too)

Web dashboard (webgui/, stdlib only — no npm/build):
- Sidebar dashboard (PentAGI-style): Run / Agents / Insights / Reports / Settings
- Multi-target runs; live execution console + per-task activity; finding cards
  with screenshots; backend+provider+model pickers (CLI & API)
- Agents tab: browse 213 + add new .md agents from the UI
- Insights: interactive RL-weight + severity charts
- Reports: download/preview PDF + HTML
- Settings/API: execution mode, per-provider API keys, orchestrator, verbosity
- Endpoints: /api/agents (GET/POST), /api/rl, /api/config, /api/reports,
  /reports/* + /shots/* static serving

Cleanup: retire replaced web stack (frontend React, FastAPI backend, core
orchestration, old test) to legacy/. Active engine + GUI are fully standalone.

Co-Authored-By: Claude Opus 4.8 (1M context) <noreply@anthropic.com>
2026-06-14 23:26:11 -03:00

41 lines
1.4 KiB
Python
Executable File

"""
NeuroSploit v3 - Report Schemas
"""
from datetime import datetime
from typing import Optional, List
from pydantic import BaseModel, Field
class ReportGenerate(BaseModel):
"""Schema for generating a report"""
scan_id: str = Field(..., description="Scan ID to generate report for")
format: str = Field("html", description="Report format: html, pdf, json")
title: Optional[str] = Field(None, description="Custom report title")
include_executive_summary: bool = Field(True, description="Include executive summary")
include_poc: bool = Field(True, description="Include proof of concept")
include_remediation: bool = Field(True, description="Include remediation steps")
preferred_provider: Optional[str] = Field(None, description="Preferred LLM provider for AI report generation")
preferred_model: Optional[str] = Field(None, description="Preferred model for AI report generation")
class ReportResponse(BaseModel):
"""Schema for report response"""
id: str
scan_id: str
title: Optional[str]
format: str
file_path: Optional[str]
executive_summary: Optional[str]
auto_generated: bool = False
is_partial: bool = False
generated_at: datetime
class Config:
from_attributes = True
class ReportListResponse(BaseModel):
"""Schema for list of reports"""
reports: List[ReportResponse]
total: int