AppSec: Reported vulnerability is considered as a false positive

This article is about using Dynatrace AppSec and dealing with reported false-positives in your applications.<br>Looking for <span>known CVEs in Dynatrace components</span>? Go to <a href="https://cve-status.dynatrace.com" target="_blank" rel="noopener noreferrer">https://cve-status.dynatrace.com</a>

This is a Self Service Diagnostics article of type Full-Self-Service.

For unexpected product issues on the Dynatrace side please submit a Support Ticket.

Self Service Summary

Issue Solution Tasks Alternative
Reported third-party vulnerabilities for certain process groups or Kubernetes nodes are not relevant for your environment Mute entities: They will be hidden and not taken into account for Application Security metrics or Davis Security Score Mute* entities via UI (security problem or its individual items) or API (security problem or individual items) Set up fine-grained Security-monitoring rules for affected processes, e.g. based on process or host tags

* Available mute state changes include CONFIGURATION_NOT_AFFECTED, FALSE_POSITIVE, IGNORE, OTHER, VULNERABLE_CODE_NOT_IN_USE

The following query examples may be helpful to identify relevant processes before muting them:

Filter by Java version

This example shows how to filter out processes of a security problem with a Java version < 9.

Steps to reproduce:

  1. Get all security problems
  2. For each: Get a list of “affectedEntities” (processes)
  3. For each: Get entity (process) property “softwareTechnologies” and filter by version (“type”=“JAVA”)
...<br>"softwareTechnologies": [<br>  {<br>    "type": "JAVA"<br>  },<br>  {<br>    "type": "JAVA",<br>    "edition": "OpenJDK",<br>    "version": "1.8.0_312"<br>  },<br>...

Related Python script: GitHub - robinwyss/spring4shell-dynatrace-export · GitHub

Filter by third-party library data

This example shows how to identify processes with a certain third-party library package name or version.

Step to reproduce: Get entities using

  1. “entitySelector” type(SOFTWARE_COMPONENT), softwareComponentType(JAVA) and your specific criteria e.g. packageName(org.springframework.boot:spring-boot), softwareComponentFileName(spring-boot-1.5.12.RELEASE.jar), or softwareComponentShortName(spring-boot),
    and response “fields” fromRelationships.isSoftwareComponentOfPgi to retrieve affected processes.
  2. previously identified Process Group Instances and response “fields” fromRelationships.isInstanceOf to retrieve affected Process Groups required for remediation.

Notes:

  • The libraries in use by PROCESS_GROUP_INSTANCES are reported as SOFTWARE_COMPONENT entities by the OneAgent.
  • Possible properties of an entity of a specified type can be listed via the entityTypes API.

Request 1:

GET /api/v2/entities?entitySelector=type(SOFTWARE_COMPONENT),softwareComponentType(JAVA),packageName(org.springframework.boot:spring-boot)&fields=properties.packageName,properties.softwareComponentFileName,properties.softwareComponentShortName,properties.softwareComponentType,fromRelationships.isSoftwareComponentOfPgi

Response:

...<br>"entities": [<br>  {<br>    "entityId": "SOFTWARE_COMPONENT-x",<br>    "displayName": "org.springframework.boot:spring-boot:1.5.12.RELEASE",<br>    "properties": {<br>      "softwareComponentFileName": "spring-boot-1.5.12.RELEASE.jar",<br>      "softwareComponentType": "JAVA",<br>      "softwareComponentShortName": "spring-boot",<br>      "packageName": "org.springframework.boot:spring-boot"<br>    },<br>    "fromRelationships": {<br>      "isSoftwareComponentOfPgi": [<br>        {<br>          "id": "PROCESS_GROUP_INSTANCE-x",<br>          "type": "PROCESS_GROUP_INSTANCE"<br>        },<br>        {<br>          "id": "PROCESS_GROUP_INSTANCE-x",<br>          "type": "PROCESS_GROUP_INSTANCE"<br>        }<br>      ]<br>    }<br>  }<br>]<br>...

Request 2:

GET /api/v2/entities/PROCESS_GROUP_INSTANCE-x?fields=fromRelationships.isInstanceOf

Response:

{ <br>  "entityId": "PROCESS_GROUP_INSTANCE-x", <br>  "type": "PROCESS_GROUP_INSTANCE", <br>  "displayName": "NAME", <br>  "fromRelationships": { <br>    "isInstanceOf": [ <br>      { <br>        "id": "PROCESS_GROUP-x", <br>        "type": "PROCESS_GROUP" <br>      } <br>    ] <br>  } <br>}
7 Likes

Thank you @stefanie_pachne for sharing this :slightly_smiling_face:

1 Like