@if(session('success'))
{{ session('success') }}
@endif
{{-- ══ 掃描工具選擇卡片 ══ --}}
@php
$allScannerDefs = [
'nuclei' => [
'label' => 'Nuclei',
'sub' => 'ProjectDiscovery',
'color' => 'danger',
'icon' => 'bi-crosshair',
'desc' => '開源模板引擎,5000+ 漏洞模板',
'tags' => ['CVE', 'OWASP', '設定錯誤'],
'ready' => true,
'badge' => '已安裝',
'badge_c' => 'success',
'engine' => 'Nuclei '.$engineVersion.' · '.$templateTotal.' 模板',
],
'zap' => [
'label' => 'OWASP ZAP',
'sub' => 'Checkmarx / OWASP',
'color' => 'primary',
'icon' => 'bi-bug-fill',
'desc' => 'OWASP 官方認可,主動 DAST 掃描',
'tags' => ['XSS', 'CSP', 'OWASP Top 10'],
'ready' => true,
'badge' => 'Docker',
'badge_c' => 'primary',
'engine' => 'ghcr.io/zaproxy/zaproxy:stable',
],
'nessus' => [
'label' => 'Nessus',
'sub' => 'Tenable',
'color' => 'warning',
'icon' => 'bi-activity',
'desc' => '業界最具公信力,企業合規標準',
'tags' => ['CVE', 'CVSS', 'PCI-DSS'],
'ready' => \App\Services\NessusService::isConfigured(),
'badge' => \App\Services\NessusService::isConfigured() ? '已設定' : '需設定',
'badge_c' => \App\Services\NessusService::isConfigured() ? 'success' : 'secondary',
'engine' => config('services.nessus.base_url', '—'),
],
'garak' => [
'label' => 'Garak',
'sub' => 'NVIDIA / LLM Security',
'color' => 'success',
'icon' => 'bi-cpu',
'desc' => 'LLM 安全評估,OWASP LLM Top 10 2025',
'tags' => ['提示注入', '越獄', 'LLM01–LLM10'],
'ready' => true,
'badge' => 'LLM 專用',
'badge_c' => 'success',
'engine' => 'garak v0.15 · OpenAI-compatible API',
],
];
$scanners = array_filter($allScannerDefs, fn($_, $k) => in_array($k, $enabledScanners), ARRAY_FILTER_USE_BOTH);
@endphp
@foreach($scanners as $key => $s)
@php
$cnt = $scannerCounts[$key] ?? null;
$total = $cnt['total'] ?? 0;
$done = $cnt['done'] ?? 0;
$active = $scannerFilter === $key;
@endphp
{{-- 卡片頂部色條 --}}
{{-- 標題列 --}}
{{ $s['label'] }}
{{ $s['badge'] }}
{{ $s['sub'] }}
{{-- 掃描數統計 --}}
{{-- 說明 --}}
{{ $s['desc'] }}
{{-- 標籤 --}}
@foreach($s['tags'] as $tag)
{{ $tag }}
@endforeach
{{-- 引擎資訊 --}}
{{ $s['engine'] }}
@endforeach
{{-- ══ 掃描記錄列表 ══ --}}
| 目標 URL |
工具 / 模式 |
共享 |
狀態 |
C |
H |
M |
L |
I |
@if($isAdmin) 建立者 | @endif
時間 |
|
@forelse($scans as $scan)
@php $bySev = $scan->summary['by_severity'] ?? []; @endphp
|
{{ $scan->target_url }}
@if($scan->host)
{{ $scan->host->name }}
@endif
|
{{ $scan->scannerLabel() }}
{{ $scan->scanner_type === 'nuclei' ? $scan->profile : ($scan->scan_mode ?? '') }}
|
@if($scan->is_shared)
@else
@endif
|
@if($scan->status === 'done')
完成
@elseif($scan->status === 'running')
執行中
@elseif($scan->status === 'failed')
失敗
@else
待執行
@endif
|
{{ ($bySev['critical']??0) ?: '·' }} |
{{ ($bySev['high']??0) ?: '·' }} |
{{ ($bySev['medium']??0) ?: '·' }} |
{{ ($bySev['low']??0) ?: '·' }} |
{{ ($bySev['info']??0) ?: '·' }} |
@if($isAdmin)
{{ $scan->creator?->name ?? '—' }}
|
@endif
{{ $scan->created_at->format('m-d H:i') }} |
@if($scan->status === 'done')
@endif
|
@empty
|
@if($search)
找不到「{{ $search }}」的掃描記錄
@else
尚無掃描記錄
@if($scannerFilter)
,立即新增 {{ $scanners[$scannerFilter]['label'] }} 掃描
@else
,請點選上方工具卡片開始掃描
@endif
@endif
|
@endforelse
{{-- end table-responsive --}}
{{-- 寄送報告 Modal --}}
@include('partials.send-report-modal')
@endsection
@push('scripts')
@endpush