import demistomock as demisto # noqa: F401 from CommonServerPython import * # noqa: F401 import re import traceback from datetime import datetime, UTC from html import escape from typing import Any # The Validate tab renders the Tenzai verdict as a self-contained "results panel" styled in # theme-adaptive native Unity chrome — it inherits the console shell, so it reads on both the light # and dark XSIAM themes: a compact Tenzai brand header + action links, a classification chip row, # a monospace stat-card grid matching the Figma design (Result | Status | Findings | Started at | # Credit usage), a per-severity badge row, and an expandable per-finding list. Each finding is a # native
disclosure: collapsed it shows a severity chip + title; expanded it reveals # Impact, Description, Reproduction, and Fix guidance subsections, with fenced code (the coding-agent # prompt / fix config / reproduction) rendered inline as monospace blocks. There is no separate # findings grid — a layout widget has a size cap and cannot run JavaScript. Exposure validation # confirms one vulnerability (1-2 findings, not a full-scan flood), so the per-section budgets are # generous and trim only unusually long sections; the full untruncated detail opens in Tenzai (linked). # # HTML-entry constraints: only inline `style=` attributes render reliably in a layout widget. # `