Tagging Assessments With Metadata
Assessments have several tags, such as UUID
, Node
, and Username
, that you can use to identify groups of assessments. You can also apply your own keyword=value pairs to assessments. For more examples of finding assessments by metadata, see Using Metadata to Manage Assessments.
Example 2-1 Listing Available Metadata
System tags are attached to all assessments. The compliance list -av
assessment command output lists all the provided tags.
$ compliance list -av pci-dss.2016-09-07,07:07
UUID: 2b333333-1111-1111-1111-9aaaabbbbb99
Benchmark=pci-dss
Profile=Solaris_PCI-DSS
Status=Complete
Node=mysparc
Platform=cpe:/o:oracle:solaris:11.4
Architecture=sun4v
Timestamp=2016-09-07T11:07:07
Username=jdoe
UserID=j987654321d
Example 2-2 Adding Tags to Assessments
You can add system tags or your own keyword-value pairs as tags to assessments, then locate similarly-tagged assessments. The compliance assess -m
matches adds the tags to the assessment.
$ compliance assess -m "trialrun=1"
Assessment will be named 'default.2016-009-07,07:07'
The following command finds the assessments with this tag.
$ compliance list -am "trialrun=1"
1b333333-1111-1111-1111-8aaaabbbbb88
Name=default.2016-09-07,09:09
The following command shows the details of the assessment that has this tag.
$ compliance list -av -m "trialrun=1"
1b333333-1111-1111-1111-8aaaabbbbb88
Name=default.2016-09-07,09:09
Benchmark=solaris
Profile=Baseline
Status=Complete
Node=mysparc
Platform=cpe:/o:oracle:solaris:11.4
Architecture=sun4v
Timestamp=2016-09-07T16:09:09
Username=jdoe
UserID=j987654321d
trialrun=1