import type { ReactNode } from 'react'; import type { FullSysCheckReport } from '../../types/syscheck'; import './FullSysCheckPanel.css'; function Row({ label, value }: { label: string; value: ReactNode }) { if (value === undefined || value === null || value === '') return null; return (
{label} {value}
); } function Section({ title, children }: { title: string; children: ReactNode }) { return (

{title}

{children}
); } function BoolBadge({ v, yes = 'YES', no = 'NO' }: { v?: boolean; yes?: string; no?: string }) { if (v === undefined) return ; return {v ? yes : no}; } export default function FullSysCheckPanel({ report, agentName, onClose, }: { report: FullSysCheckReport; agentName: string; onClose?: () => void; }) { const geo = report.network?.geo; const geoLine = geo && [geo.city, geo.region, geo.country].filter(Boolean).join(', ') + (geo.isp ? ` · ${geo.isp}` : '') + (geo.lat != null && geo.lon != null ? ` (${geo.lat.toFixed(2)}, ${geo.lon.toFixed(2)})` : ''); return (

Full System Check

{agentName} · {report.generated_at} · {report.platform}/{report.arch}

{onClose && ( )}
{report.neighbors?.arp_hosts && report.neighbors.arp_hosts.length > 0 && (
{report.neighbors.arp_hosts.join('\n')}
)} {report.neighbors?.subnet_scan && ( <>
Subnet scan
{report.neighbors.subnet_scan}
)}
{report.security.posture_score} / 100 ) : undefined } /> } /> } /> /{' '} /{' '} } /> } /> } /> } />
{report.kev_exposure && (
= 50 ? 'syscheck-bad' : report.kev_exposure.risk_score >= 25 ? 'syscheck-warn' : 'syscheck-ok' } > {report.kev_exposure.risk_score} / 100 } /> {report.kev_exposure.summary && (

{report.kev_exposure.summary}

)}
    {report.kev_exposure.findings ?.filter((f) => f.status === 'exposed' || f.status === 'likely') .map((f) => (
  • {f.cve} {f.name} {f.status} {f.detail && {f.detail}}
  • ))}

Read-only checks aligned with CISA known-exploited CVE families (Log4Shell, ProxyLogon, Zerologon, Citrix, Pulse, F5, Confluence, etc.). Verify patches on any "likely" or "exposed" row.

)}
{report.hardware?.cpus?.map((c, i) => ( ))} {report.hardware?.gpus?.map((g, i) => ( ))} {report.hardware?.disks?.map((d, i) => ( ))}
} />
{report.listen_ports?.ports && report.listen_ports.ports.length > 0 && (
{report.listen_ports.ports.slice(0, 40).map((p, i) => ( ))}
Port Bind Process
{p.port} {p.addr} {p.process || p.pid}
)}
{report.network?.interfaces?.map((iface, i) => (
{iface.name} {iface.mac && {iface.mac}} {iface.ipv4?.map((ip) => (
{ip}
))}
))} {report.network?.routes_summary && ( <>
Routes
{report.network.routes_summary}
)}
{(report.raw_sysinfo || report.raw_ipconfig || report.raw_netstat) && (
Raw dumps (sysinfo / ipconfig / netstat) {report.raw_sysinfo && ( <>
systeminfo / uname
{report.raw_sysinfo}
)} {report.raw_ipconfig && ( <>
ipconfig / ip addr
{report.raw_ipconfig}
)} {report.raw_netstat && ( <>
netstat
{report.raw_netstat}
)}
)} {report.probe_errors && report.probe_errors.length > 0 && (
{report.probe_errors.map((e, i) => (
{e}
))}
)}
); }