Skip to main content

assessments

Creates, updates, deletes, gets or lists a assessments resource.

Overview

Nameassessments
TypeResource
Idazure.security.assessments

Fields

NameDatatypeDescription
idtextResource Id
nametextResource name
additional_datatextfield from the properties object
assessmentNametextfield from the properties object
display_nametextfield from the properties object
linkstextfield from the properties object
metadatatextfield from the properties object
partners_datatextfield from the properties object
resourceIdtextfield from the properties object
resource_detailstextfield from the properties object
scopetextfield from the properties object
statustextfield from the properties object
typetextResource type

Methods

NameAccessible byRequired ParamsDescription
getSELECTassessmentName, resourceIdGet a security assessment on your scanned resource
listSELECTscopeGet security assessments on all your scanned resources inside a scope
create_or_updateINSERTassessmentName, resourceIdCreate a security assessment on your resource. An assessment metadata that describes this assessment must be predefined with the same name before inserting the assessment result
deleteDELETEassessmentName, resourceIdDelete a security assessment on your resource. An assessment metadata that describes this assessment must be predefined with the same name before inserting the assessment result

SELECT examples

Get security assessments on all your scanned resources inside a scope

SELECT
id,
name,
additional_data,
assessmentName,
display_name,
links,
metadata,
partners_data,
resourceId,
resource_details,
scope,
status,
type
FROM azure.security.vw_assessments
WHERE scope = '{{ scope }}';

INSERT example

Use the following StackQL query and manifest file to create a new assessments resource.

/*+ create */
INSERT INTO azure.security.assessments (
assessmentName,
resourceId,
properties
)
SELECT
'{{ assessmentName }}',
'{{ resourceId }}',
'{{ properties }}'
;

DELETE example

Deletes the specified assessments resource.

/*+ delete */
DELETE FROM azure.security.assessments
WHERE assessmentName = '{{ assessmentName }}'
AND resourceId = '{{ resourceId }}';