Attacks API - GET all attacks
Lists all detected attacks on your applications.
The request produces an application/json
payload.
GET | ManagedDynatrace for Government | https://{your-domain}/e/{your-environment-id}/api/v2/attacks |
SaaS | https://{your-environment-id}.live.dynatrace.com/api/v2/attacks | |
Environment and Cluster ActiveGate (default port 9999) | https://{your-activegate-domain}:9999/e/{your-environment-id}/api/v2/attacks |
Authentication
To execute this request, you need an access token with attacks.read
scope.
To learn how to obtain and use it, see Tokens and authentication.
Parameters
Parameter | Type | Description | In | Required |
---|---|---|---|---|
nextPageKey | string | The cursor for the next page of results. You can find it in the nextPageKey field of the previous response. The first page is always returned if you don't specify the nextPageKey query parameter. When the nextPageKey is set to obtain subsequent pages, you must omit all other query parameters. | query | optional |
pageSize | integer | The amount of attacks in a single response payload. The maximal allowed page size is 500. If not set, 100 is used. | query | optional |
attackSelector | string | Defines the scope of the query. Only attacks matching the specified criteria are included in the response. You can add one or more of the following criteria. Values are not case-sensitive and the
To set several criteria, separate them with a comma ( Specify the value of a criterion as a quoted string. The following special characters must be escaped with a tilde (
| query | optional |
sort | string | Specifies one or more fields for sorting the attack list. Multiple fields can be concatenated using a comma ( You can sort by the following properties with a sign prefix for the sorting order.
| query | optional |
fields | string | A list of additional attack properties you can add to the response. The following properties are available (all other properties are always included and you can't remove them from the response):
To add properties, specify them in a comma-separated list and prefix each property with a plus (for example, | query | optional |
from | string | The start of the requested timeframe. You can use one of the following formats:
If not set, the relative timeframe of thirty days is used ( | query | optional |
to | string | The end of the requested timeframe. You can use one of the following formats:
If not set, the current timestamp is used. | query | optional |
Response
Response codes
Code | Type | Description |
---|---|---|
200 | AttackList | Success |
Response body objects
The AttackList
object
A list of attacks.
Element | Type | Description |
---|---|---|
attacks | Attack[] | A list of attacks. |
nextPageKey | string | The cursor for the next page of results. Has the value of Use it in the nextPageKey query parameter to obtain subsequent pages of the result. |
pageSize | integer | The number of entries per page. |
totalCount | integer | The total number of entries in the result. |
The Attack
object
Describes an attack.
Element | Type | Description |
---|---|---|
affectedEntities | AffectedEntities | Information about affected entities of an attack. |
attackId | string | The ID of the attack. |
attackTarget | AttackTarget | Information about the targeted host/database of an attack. |
attackType | string | The type of the attack.
|
attacker | Attacker | Attacker of an attack. |
displayId | string | The display ID of the attack. |
displayName | string | The display name of the attack. |
entrypoint | AttackEntrypoint | Describes the entrypoint used by an attacker to start a specific attack. |
managementZones | ManagementZone[] | A list of management zones which the affected entities belong to. |
request | RequestInformation | Describes the complete request information of an attack. |
securityProblem | AttackSecurityProblem | Assessment information and the ID of a security problem related to an attack. |
state | string | The state of the attack.
|
technology | string | The technology of the attack.
|
timestamp | integer | The timestamp when the attack occurred. |
vulnerability | Vulnerability | Describes the exploited vulnerability. |
The AffectedEntities
object
Information about affected entities of an attack.
Element | Type | Description |
---|---|---|
processGroup | AffectedEntity | Information about an affected entity. |
processGroupInstance | AffectedEntity | Information about an affected entity. |
The AffectedEntity
object
Information about an affected entity.
Element | Type | Description |
---|---|---|
id | string | The monitored entity ID of the affected entity. |
name | string | The name of the affected entity. |
The AttackTarget
object
Information about the targeted host/database of an attack.
Element | Type | Description |
---|---|---|
entityId | string | The monitored entity ID of the targeted host/database. |
name | string | The name of the targeted host/database. |
The Attacker
object
Attacker of an attack.
Element | Type | Description |
---|---|---|
location | AttackerLocation | Location of an attacker. |
sourceIp | string | The source IP of the attacker. |
The AttackerLocation
object
Location of an attacker.
Element | Type | Description |
---|---|---|
city | string | City of the attacker. |
country | string | The country of the attacker. |
countryCode | string | The country code of the country of the attacker, according to the ISO 3166-1 Alpha-2 standard. |
The AttackEntrypoint
object
Describes the entrypoint used by an attacker to start a specific attack.
Element | Type | Description |
---|---|---|
codeLocation | CodeLocation | Information about a code location. |
entrypointFunction | FunctionDefinition | Information about a function definition. |
payload | object[] | A list of values that has possibly been truncated. |
The CodeLocation
object
Information about a code location.
Element | Type | Description |
---|---|---|
className | string | The fully qualified class name of the code location. |
displayName | string | A human readable string representation of the code location. |
functionName | string | The function/method name of the code location. |
lineNumber | integer | The line number of the code location. |
parameterTypes | TruncatableListString | A list of values that has possibly been truncated. |
returnType | string | The return type of the function. |
The TruncatableListString
object
A list of values that has possibly been truncated.
Element | Type | Description |
---|---|---|
truncationInfo | TruncationInfo | Information on a possible truncation. |
values | string[] | Values of the list. |
The TruncationInfo
object
Information on a possible truncation.
Element | Type | Description |
---|---|---|
truncated | boolean | If the list/value has been truncated. |
The FunctionDefinition
object
Information about a function definition.
Element | Type | Description |
---|---|---|
className | string | The fully qualified class name of the class that includes the function. |
displayName | string | A human readable string representation of the function definition. |
functionName | string | The function/method name. |
parameterTypes | TruncatableListString | A list of values that has possibly been truncated. |
returnType | string | The return type of the function. |
The EntrypointPayload
object
Describes a payload sent to an entrypoint during an attack.
Element | Type | Description |
---|---|---|
name | string | Name of the payload, if applicable. |
type | string | Type of the payload.
|
value | string | Value of the payload. |
The ManagementZone
object
A short representation of a management zone.
Element | Type | Description |
---|---|---|
id | string | The ID of the management zone. |
name | string | The name of the management zone. |
The RequestInformation
object
Describes the complete request information of an attack.
Element | Type | Description |
---|---|---|
host | string | The target host of the request. |
path | string | The request path. |
protocolDetails | ProtocolDetails | Details that are specific to the used protocol. |
url | string | The requested URL. |
The ProtocolDetails
object
Details that are specific to the used protocol.
Element | Type | Description |
---|---|---|
http | HttpProtocolDetails | HTTP specific request details. |
The HttpProtocolDetails
object
HTTP specific request details.
Element | Type | Description |
---|---|---|
headers | TruncatableListAttackRequestHeader | A list of values that has possibly been truncated. |
parameters | TruncatableListHttpRequestParameter | A list of values that has possibly been truncated. |
requestMethod | string | The HTTP request method. |
The TruncatableListAttackRequestHeader
object
A list of values that has possibly been truncated.
Element | Type | Description |
---|---|---|
truncationInfo | TruncationInfo | Information on a possible truncation. |
values | AttackRequestHeader[] | Values of the list. |
The AttackRequestHeader
object
A header element of the attack's request.
Element | Type | Description |
---|---|---|
name | string | The name of the header element. |
value | string | The value of the header element. |
The TruncatableListHttpRequestParameter
object
A list of values that has possibly been truncated.
Element | Type | Description |
---|---|---|
truncationInfo | TruncationInfo | Information on a possible truncation. |
values | HttpRequestParameter[] | Values of the list. |
The HttpRequestParameter
object
An HTTP request parameter.
Element | Type | Description |
---|---|---|
name | string | The name of the parameter. |
value | string | The value of the parameter. |
The AttackSecurityProblem
object
Assessment information and the ID of a security problem related to an attack.
Element | Type | Description |
---|---|---|
assessment | AttackSecurityProblemAssessmentDto | The assessment of a security problem related to an attack. |
securityProblemId | string | The security problem ID. |
The AttackSecurityProblemAssessmentDto
object
The assessment of a security problem related to an attack.
Element | Type | Description |
---|---|---|
dataAssets | string | The reachability of data assets by the attacked target.
|
exposure | string | The level of exposure of the attacked target
|
numberOfReachableDataAssets | integer | The number of data assets reachable by the attacked target. |
The Vulnerability
object
Describes the exploited vulnerability.
Element | Type | Description |
---|---|---|
codeLocation | CodeLocation | Information about a code location. |
displayName | string | The display name of the vulnerability. |
vulnerabilityId | string | The id of the vulnerability. |
vulnerableFunction | FunctionDefinition | Information about a function definition. |
vulnerableFunctionInput | VulnerableFunctionInput | Describes what got passed into the code level vulnerability. |
The VulnerableFunctionInput
object
Describes what got passed into the code level vulnerability.
Element | Type | Description |
---|---|---|
inputSegments | VulnerableFunctionInputSegment[] | A list of input segments. |
type | string | The type of the input.
|
The VulnerableFunctionInputSegment
object
Describes one segment that was passed into a vulnerable function.
Element | Type | Description |
---|---|---|
type | string | The type of the input segment.
|
value | string | The value of the input segment. |
Response body JSON model
1{2 "attacks": [3 {4 "affectedEntities": {5 "processGroup": {6 "id": "string",7 "name": "string"8 },9 "processGroupInstance": {}10 },11 "attackId": "string",12 "attackTarget": {13 "entityId": "string",14 "name": "string"15 },16 "attackType": "COMMAND_INJECTION",17 "attacker": {18 "location": {19 "city": "string",20 "country": "string",21 "countryCode": "string"22 },23 "sourceIp": "string"24 },25 "displayId": "string",26 "displayName": "string",27 "entrypoint": {28 "codeLocation": {29 "className": "string",30 "displayName": "string",31 "functionName": "string",32 "lineNumber": 1,33 "parameterTypes": {34 "truncationInfo": {35 "truncated": true36 },37 "values": [38 "string"39 ]40 },41 "returnType": "string"42 },43 "entrypointFunction": {44 "className": "string",45 "displayName": "string",46 "functionName": "string",47 "parameterTypes": {},48 "returnType": "string"49 },50 "payload": [51 {52 "truncationInfo": {},53 "values": [54 {55 "name": "string",56 "type": "HTTP_BODY",57 "value": "string"58 }59 ]60 }61 ]62 },63 "managementZones": [64 {65 "id": "string",66 "name": "string"67 }68 ],69 "request": {70 "host": "string",71 "path": "string",72 "protocolDetails": {73 "http": {74 "headers": {75 "truncationInfo": {},76 "values": [77 {78 "name": "string",79 "value": "string"80 }81 ]82 },83 "parameters": {84 "truncationInfo": {},85 "values": [86 {87 "name": "string",88 "value": "string"89 }90 ]91 },92 "requestMethod": "string"93 }94 },95 "url": "string"96 },97 "securityProblem": {98 "assessment": {99 "dataAssets": "NOT_AVAILABLE",100 "exposure": "NOT_AVAILABLE",101 "numberOfReachableDataAssets": 1102 },103 "securityProblemId": "string"104 },105 "state": "ALLOWLISTED",106 "technology": "DOTNET",107 "timestamp": 1,108 "vulnerability": {109 "codeLocation": {},110 "displayName": "string",111 "vulnerabilityId": "string",112 "vulnerableFunction": {},113 "vulnerableFunctionInput": {114 "inputSegments": [115 {116 "type": "MALICIOUS_INPUT",117 "value": "string"118 }119 ],120 "type": "COMMAND"121 }122 }123 }124 ],125 "nextPageKey": "AQAAABQBAAAABQ==",126 "pageSize": 1,127 "totalCount": 1128}