evidence
Creates, updates, deletes, gets or lists an evidence resource.
Overview
| Name | evidence |
| Type | Resource |
| Id | azure_extras.app_compliance_automation.evidence |
Fields
The following fields are returned by SELECT queries:
- get
- list_by_report
| Name | Datatype | Description |
|---|---|---|
id | string | Fully qualified resource ID for the resource. Ex - /subscriptions/{subscriptionId}/resourceGroups/{resourceGroupName}/providers/{resourceProviderNamespace}/{resourceType}/{resourceName}. # pylint: disable=line-too-long |
name | string | The name of the resource. |
controlId | string | Control id. |
evidenceType | string | Evidence type. Known values are: "File", "AutoCollectedEvidence", and "Data". |
extraData | string | Extra data considered as evidence. |
filePath | string | The path of the file in storage. Required. |
provisioningState | string | Azure lifecycle management. Known values are: "Succeeded", "Failed", "Canceled", "Creating", "Deleting", "Fixing", "Verifying", and "Updating". |
responsibilityId | string | Responsibility id. |
systemData | object | Azure Resource Manager metadata containing createdBy and modifiedBy information. |
type | string | The type of the resource. E.g. "Microsoft.Compute/virtualMachines" or "Microsoft.Storage/storageAccounts". |
| Name | Datatype | Description |
|---|---|---|
id | string | Fully qualified resource ID for the resource. Ex - /subscriptions/{subscriptionId}/resourceGroups/{resourceGroupName}/providers/{resourceProviderNamespace}/{resourceType}/{resourceName}. # pylint: disable=line-too-long |
name | string | The name of the resource. |
controlId | string | Control id. |
evidenceType | string | Evidence type. Known values are: "File", "AutoCollectedEvidence", and "Data". |
extraData | string | Extra data considered as evidence. |
filePath | string | The path of the file in storage. Required. |
provisioningState | string | Azure lifecycle management. Known values are: "Succeeded", "Failed", "Canceled", "Creating", "Deleting", "Fixing", "Verifying", and "Updating". |
responsibilityId | string | Responsibility id. |
systemData | object | Azure Resource Manager metadata containing createdBy and modifiedBy information. |
type | string | The type of the resource. E.g. "Microsoft.Compute/virtualMachines" or "Microsoft.Storage/storageAccounts". |
Methods
The following methods are available for this resource:
| Name | Accessible by | Required Params | Optional Params | Description |
|---|---|---|---|---|
get | select | report_name, evidence_name | Get the evidence metadata. | |
list_by_report | select | report_name | $skipToken, $top, $select, $filter, $orderby, offerGuid, reportCreatorTenantId | Returns a paginated list of evidences for a specified report. |
create_or_update | insert | report_name, evidence_name, properties | offerGuid, reportCreatorTenantId | Create or Update an evidence a specified report. |
create_or_update | replace | report_name, evidence_name, properties | offerGuid, reportCreatorTenantId | Create or Update an evidence a specified report. |
delete | delete | report_name, evidence_name | Delete an existent evidence from a specified report. | |
download | exec | report_name, evidence_name | Download evidence file. |
Parameters
Parameters can be passed in the WHERE clause of a query. Check the Methods section to see which parameters are required or optional for each operation.
| Name | Datatype | Description |
|---|---|---|
evidence_name | string | The evidence name. Required. |
report_name | string | Report Name. Required. |
$filter | string | The filter to apply on the operation. Default value is None. |
$orderby | string | OData order by query option. Default value is None. |
$select | string | OData Select statement. Limits the properties on each entry to just those requested, e.g. ?$select=reportName,id. Default value is None. |
$skipToken | string | Skip over when retrieving results. Default value is None. |
$top | integer | Number of elements to return when retrieving results. Default value is None. |
offerGuid | string | The offerGuid which mapping to the reports. Default value is None. |
reportCreatorTenantId | string | The tenant id of the report creator. Default value is None. |
SELECT examples
- get
- list_by_report
Get the evidence metadata.
SELECT
id,
name,
controlId,
evidenceType,
extraData,
filePath,
provisioningState,
responsibilityId,
systemData,
type
FROM azure_extras.app_compliance_automation.evidence
WHERE report_name = '{{ report_name }}' -- required
AND evidence_name = '{{ evidence_name }}' -- required
;
Returns a paginated list of evidences for a specified report.
SELECT
id,
name,
controlId,
evidenceType,
extraData,
filePath,
provisioningState,
responsibilityId,
systemData,
type
FROM azure_extras.app_compliance_automation.evidence
WHERE report_name = '{{ report_name }}' -- required
AND $skipToken = '{{ $skipToken }}'
AND $top = '{{ $top }}'
AND $select = '{{ $select }}'
AND $filter = '{{ $filter }}'
AND $orderby = '{{ $orderby }}'
AND offerGuid = '{{ offerGuid }}'
AND reportCreatorTenantId = '{{ reportCreatorTenantId }}'
;
INSERT examples
- create_or_update
- Manifest
Create or Update an evidence a specified report.
INSERT INTO azure_extras.app_compliance_automation.evidence (
properties,
report_name,
evidence_name,
offerGuid,
reportCreatorTenantId
)
SELECT
'{{ properties }}' /* required */,
'{{ report_name }}',
'{{ evidence_name }}',
'{{ offerGuid }}',
'{{ reportCreatorTenantId }}'
RETURNING
id,
name,
properties,
systemData,
type
;
# Description fields are for documentation purposes
- name: evidence
props:
- name: report_name
value: "{{ report_name }}"
description: Required parameter for the evidence resource.
- name: evidence_name
value: "{{ evidence_name }}"
description: Required parameter for the evidence resource.
- name: properties
description: |
Evidence property. Required.
value:
evidenceType: "{{ evidenceType }}"
filePath: "{{ filePath }}"
extraData: "{{ extraData }}"
controlId: "{{ controlId }}"
responsibilityId: "{{ responsibilityId }}"
provisioningState: "{{ provisioningState }}"
- name: offerGuid
value: "{{ offerGuid }}"
description: The offerGuid which mapping to the reports. Default value is None.
description: The offerGuid which mapping to the reports. Default value is None.
- name: reportCreatorTenantId
value: "{{ reportCreatorTenantId }}"
description: The tenant id of the report creator. Default value is None.
description: The tenant id of the report creator. Default value is None.
REPLACE examples
- create_or_update
Create or Update an evidence a specified report.
REPLACE azure_extras.app_compliance_automation.evidence
SET
properties = '{{ properties }}'
WHERE
report_name = '{{ report_name }}' --required
AND evidence_name = '{{ evidence_name }}' --required
AND properties = '{{ properties }}' --required
AND offerGuid = '{{ offerGuid}}'
AND reportCreatorTenantId = '{{ reportCreatorTenantId}}'
RETURNING
id,
name,
properties,
systemData,
type;
DELETE examples
- delete
Delete an existent evidence from a specified report.
DELETE FROM azure_extras.app_compliance_automation.evidence
WHERE report_name = '{{ report_name }}' --required
AND evidence_name = '{{ evidence_name }}' --required
;
Lifecycle Methods
- download
Download evidence file.
EXEC azure_extras.app_compliance_automation.evidence.download
@report_name='{{ report_name }}' --required,
@evidence_name='{{ evidence_name }}' --required
@@json=
'{
"reportCreatorTenantId": "{{ reportCreatorTenantId }}",
"offerGuid": "{{ offerGuid }}"
}'
;