Get affected entities for a vulnerability in Dynatrace with the Vulnerabilities API and a segment filter, using filters and a time range.
| POST | SaaS | https://{your-environment-id}.apps.dynatrace.com/platform/vulnerabilities/v1/vulnerabilities/{id}/affected-entities:segment |
You provide the vulnerability ID in the path and can use filter, sort, start-time, and end-time to narrow the affected entities returned, then send filterSegments in the request body. It returns the affected entities of the vulnerability from Dynatrace.
To execute this request, you need a platform token or OAuth access token with vulnerability-service:vulnerabilities:read scope. To learn how to obtain and use it, see Tokens and authentication.
| Parameter | Type | Description | In | Required |
|---|---|---|---|---|
| id | string | The ID of the related vulnerability. | path | Required |
| filter | string | The filter parameter, as explained here:
This expression filters the returned affected entities.
Generally, all fields can be used for filtering, except for the | query | Optional |
| sort | string | The sort parameter, as explained here:
Fields can be prefixed with Generally, all fields with a single value can be used for sorting; array fields can only be sorted by their
counts: If this parameter is omitted, the affected entities are sorted by their id. | query | Optional |
| start-time | string | The start of the requested timeframe. You can use one of the following formats:
| query | Optional |
| end-time | string | The end of the requested timeframe. | query | Optional |
| body | Segment | The JSON body of the request containing the filter segments. | body | Optional |
SegmentRequestBody object| Element | Type | Description | Required |
|---|---|---|---|
| filterSegments | Filter | - | Optional |
FilterSegment objectUse filter segments to define the considered affected entities. For more information see the documentation.
| Element | Type | Description | Required |
|---|---|---|---|
| id | string | - | Required |
| variables | Filter | - | Optional |
FilterSegmentVariable object| Element | Type | Description | Required |
|---|---|---|---|
| name | string | - | Required |
| values | string[] | - | Required |
This is a model of the request body, showing the possible elements. It has to be adjusted for usage in an actual request.
{"filterSegments": [{"id": "string","variables": [{"name": "string","values": ["string"]}]}]}
| Code | Type | Description |
|---|---|---|
| 200 | Affected | The affected entities of the vulnerability |
| 400 | - | - |
| 401 | - | - |
| 403 | - | - |
| 404 | - | - |
| 429 | - | - |
| 500 | - | - |
| 501 | - | - |
| 503 | - | - |
AffectedEntities objectA list of affected entities.
| Element | Type | Description |
|---|---|---|
| affectedEntities | Affected | - |
AffectedEntity objectContains detailed information about an affected entity and the related vulnerability.
| Element | Type | Description |
|---|---|---|
| id | string | - |
| name | string | - |
| type | Affected | -The element can hold these values
|
| affectedProcesses | string[] | - |
| mute | Mute | - |
| cvss | Cvss | - |
| risk | Risk | - |
| davisAssessment | Davis | - |
| resolution | Resolution | - |
| vulnerableComponent | Vulnerable | - |
| vulnerableFunctions | Vulnerable | A list of vulnerable functions in use. |
| trackingLink | Tracking | - |
| entryPoints | Entry | - |
AffectedEntityType objectMuteDetails object| Element | Type | Description |
|---|---|---|
| status | Mute | -The element can hold these values
|
| reason | Mute | -The element can hold these values
|
| user | string | - |
| comment | string | - |
| changeDate | string | - |
MuteStatus objectMuteReason objectCvss object| Element | Type | Description |
|---|---|---|
| baseScore | number | - |
| version | string | - |
| vector | string | - |
Risk object| Element | Type | Description |
|---|---|---|
| score | number | - |
| level | Risk | -The element can hold these values
|
RiskLevel objectDavisAssessment object| Element | Type | Description |
|---|---|---|
| score | number | - |
| level | Risk | -The element can hold these values
|
| exposureStatus | Exposure | -The element can hold these values
|
| dataAssetsStatus | Data | -The element can hold these values
|
| assessmentMode | Assessment | -The element can hold these values
|
| exploitStatus | Exploit | -The element can hold these values
|
| vulnerableFunctionStatus | Vulnerable | -The element can hold these values
|
| vector | string | - |
ExposureStatus objectDataAssetsStatus objectAssessmentMode objectExploitStatus objectVulnerableFunctionStatus objectResolution object| Element | Type | Description |
|---|---|---|
| status | Status | -The element can hold these values
|
| changeDate | string | - |
Status objectVulnerableComponent object| Element | Type | Description |
|---|---|---|
| id | string | - |
| name | string | - |
| shortName | string | - |
| version | string | - |
| packageName | string | - |
VulnerableFunctions objectA list of vulnerable functions in use.
TrackingLink object| Element | Type | Description |
|---|---|---|
| url | string | The tracking link URL set for the affected entities, e.g. https://example.com/ISSUE-123. Note that only valid URLs with 'http' or 'https' protocols are supported. |
| text | string | The tracking link text set for the affected entities, e.g. 'ISSUE-123'. |
EntryPoint object| Element | Type | Description |
|---|---|---|
| url | Entry | - |
| payload | string | - |
| function | Entry | - |
| userControlledInputs | User | - |
EntryPointUrl object| Element | Type | Description |
|---|---|---|
| path | string | - |
EntryPointFunction object| Element | Type | Description |
|---|---|---|
| name | string | - |
UserControlledInput object| Element | Type | Description |
|---|---|---|
| type | string | - |
| key | string | - |
| value | string | - |
| payload | User | - |
| isMalicious | boolean | - |
UserControlledInputPayload object| Element | Type | Description |
|---|---|---|
| start | integer | - |
| end | integer | - |
{"affectedEntities": [{"id": "string","name": "string","type": "PROCESS_GROUP","affectedProcesses": ["string"],"mute": {"status": "MUTED","reason": "FALSE_POSITIVE","user": "string","comment": "string","changeDate": "string"},"cvss": {"baseScore": 1,"version": "string","vector": "string"},"risk": {"score": 1,"level": "NONE"},"davisAssessment": {"score": 1,"level": "NONE","exposureStatus": "NOT_AVAILABLE","dataAssetsStatus": "NOT_AVAILABLE","assessmentMode": "NOT_AVAILABLE","exploitStatus": "NOT_AVAILABLE","vulnerableFunctionStatus": "NOT_AVAILABLE","vector": "string"},"resolution": {"status": "OPEN","changeDate": "string"},"vulnerableComponent": {"id": "string","name": "string","shortName": "string","version": "string","packageName": "string"},"vulnerableFunctions": ["string"],"trackingLink": {"url": "string","text": "string"},"entryPoints": [{"url": {"path": "string"},"payload": "string","function": {"name": "string"},"userControlledInputs": [{"type": "string","key": "string","value": "string","payload": {"start": 1,"end": 1},"isMalicious": true}]}]}]}