Latest Dynatrace Preview
The Dynatrace integration with Harbor allows you to unify and contextualize vulnerability findings across DevSecOps tools and products, enabling central prioritization, visualization, and automation of security findings.
Harbor is a container registry that allows scanning the stored container images with various tools, such as Trivy. It serves the generated vulnerability findings from container images. The Dynatrace platform observes the corresponding runtime entities (the running containers) associated with those images. Ingesting and mapping vulnerability findings to the runtime entities helps users to better focus on the top risks that affect their production applications.
Dynatrace integration with Harbor is an extension running on Dynatrace ActiveGate. Once you enable and configure the Dynatrace Harbor extension
It periodically reaches out to Harbor products and fetches the new vulnerability findings, scans, and audit logs.
The fetched data is ingested into Dynatrace and mapped to the Dynatrace semantic conventions.
Data is stored in a bucket called default_security_custom_events
(for details, see Built-in Grail buckets).
See below for the Harbor and Dynatrace requirements.
We recommend using a robot account for fine-grained authorization. Make sure to
Store the generated secret for the robot account, as it won't be recoverable after creation
Refresh the expiry period in due time
Edit the robot account to enable the following permissions:
List
for the Audit log, Project, and Security Hub resourcesList
for the Artifact resource for all the projects you want to monitorActiveGate version 1.300+
Permissions: For a list of permissions required, go to Dynatrace Hub , select Extensions
, and display Technical information.
Generate an access token with the openpipeline.events_security
scope.
In Dynatrace, search for Harbor and select Install.
Follow the on-screen instructions to configure the extension.
Verify configuration by running the following queries in Notebooks:
For audit logs:
fetch logs| filter log.source=="Harbor"
For finding events:
fetch events| filter dt.system.bucket == "default_security_custom_events"| filter event.kind == "SECURITY_EVENT"AND event.provider=="Harbor"AND event.type=="VULNERABILITY_FINDING"
For scan events:
fetch events| filter dt.system.bucket == "default_security_custom_events"| filter event.kind == "SECURITY_EVENT"AND event.provider=="Harbor"AND event.type=="VULNERABILITY_SCAN"
Once the extension is installed and working, you can access and manage it in Dynatrace via the Extensions app. For details, see Extensions 2.0 concepts.
With the ingested data, you can accomplish various use cases, such as
The Harbor APIs only expose the status of the last completed scan for artifacts. This means that when the extension runs, it can only report the most recent scan that occurred (if any) during the last collection interval.
If the extension is set to collect scan and vulnerability data once per hour and two scans occurred in that last hour, only the details of the most recent one will be reported.
Vulnerability finding events store the individual vulnerability findings reported by Harbor per container image and component.
Vulnerability scan events indicate coverage of scans for individual container images.
Audit logs represent user activity logs in Harbor.
The container_image
namespace is added for container image-related information with the following fields:
container_image.digest
represents the container image digest; this value can be used to match to the runtime containers
container_image.repository
represents the container repository name
container_image.registry
represents the container registry name
The container_image.tags
field isn't reported by Harbor, so it's not available.
CONTAINER_IMAGE
: All findings from Harbor are generated by vulnerability assessments of container images set with the CONTAINER_IMAGE
value in the object.type
field, and the container_image
namespace is added.
dt.security.risk.level
is taken from the severity level set by the configured scanner in Harbor. The values (CRITICAL
, HIGH
, MEDIUM
, LOW
, and NONE
) are mapped as is, with the exception of Unknown
, which is also mapped to NONE
.
dt.security.risk.score
is mapped to a set of fixed values based on the risk level determined above.
dt.security.risk.level
(mapped from finding.severity
)dt.security.risk.score