OpenBAS-Platform / openbas

Open Breach and Attack Simulation Platform

Home Page:https://openbas.io

Geek Repo:Geek Repo

Github PK Tool:Github PK Tool

Assets group are not selectable in Scenario, Simulation, Atomic Testing

jborozco opened this issue · comments

Description

When trying to select an asset group for an inject, the list is returned empty.

image

Reproducible Steps

  1. Go to https://testing.obas.staging.filigran.io/admin/exercises/f7dcbd18-1062-4c9a-8870-67eb731d9d5a/injects
  2. Try to add an asset group to the inject
  3. The list is empty

Expected Output

It should return a list of all asset groups compatible with the inject

In the backend, I got this error, likely due to new asset types (security platforms). I added a filter to exclude non-endpoint assets : java.util.NoSuchElementException: No value present
at java.base/java.util.Optional.orElseThrow(Optional.java:377) ~[na:na]
at io.openbas.utils.schema.SchemaUtils.retrieveProperty(SchemaUtils.java:140) ~[classes/:na]
at io.openbas.utils.FilterUtilsRuntime.lambda$computeFilter$1(FilterUtilsRuntime.java:68) ~[classes/:na]
at io.openbas.asset.AssetGroupService.computeDynamicAssets(AssetGroupService.java:94) ~[classes/:na]