{# SBOM Export options (show_sbom_export / SBOM_EXPORT_RECIPES). Shared by the configure modal (pages/prerun.html: pfx="pre", sx=state) and the card back (components/_card_config.html: pfx="cardcfg", sx=eff, plus is_ov for the inherit markers). command-center.js (_wireSbomExport) filters the encoding list by standard from `sbom_encodings` (VALID_ENCODINGS) and drives the signing mode; the server re-validates every combination with SbomOptions.validate(web=True) on submit. Signing is key-based only: a key path or KMS URI on the machine running fs-report. There is deliberately no password or token field — an encrypted key reads COSIGN_PASSWORD from the server's environment. sbom_sign_mode (none|cosign|embedded) is persisted and kept in run history; the key path never is (no card / Settings / history copy), so the card back shows a note instead of a key field and every launch, replays included, asks for it. sign_embedded is derived server-side from the mode. #} {% set _ov = is_ov is defined %} {% set _std = sx.get('sbom_standard') or 'cyclonedx-1.6' %} {% if _std not in sbom_encodings %}{% set _std = 'cyclonedx-1.6' %}{% endif %} {% set _encs = sbom_encodings[_std] %} {% set _enc = sx.get('sbom_encoding') or _encs[0] %} {% set _mode = sx.get('sbom_sign_mode') or 'none' %} {% if _mode not in ('none', 'cosign', 'embedded') %}{% set _mode = 'none' %}{% endif %} {% set _emb_ok = _std.startswith('cyclonedx-') and _enc in ('json', 'xml') %} {% set _labels = {'cyclonedx-1.6': 'CycloneDX 1.6', 'cyclonedx-1.7': 'CycloneDX 1.7', 'spdx-2.3': 'SPDX 2.3', 'spdx-3.0': 'SPDX 3.0'} %}