scanSbom method
Scans a provided CycloneDX 1.5 SBOM and reports on any vulnerabilities discovered in that SBOM. You can generate compatible SBOMs for your resources using the Amazon Inspector SBOM generator.
May throw AccessDeniedException.
May throw InternalServerException.
May throw ThrottlingException.
May throw ValidationException.
Parameter sbom :
The JSON file for the SBOM you want to scan. The SBOM must be in CycloneDX
1.5 format. This format limits you to passing 2000 components before
throwing a ValidException error.
Parameter outputFormat :
The output format for the vulnerability report.
Implementation
Future<ScanSbomResponse> scanSbom({
required Object sbom,
OutputFormat? outputFormat,
}) async {
final $payload = <String, dynamic>{
'sbom': sbom,
if (outputFormat != null) 'outputFormat': outputFormat.value,
};
final response = await _protocol.send(
payload: $payload,
method: 'POST',
requestUri: '/scan/sbom',
exceptionFnMap: _exceptionFns,
);
return ScanSbomResponse.fromJson(response);
}