SBOM Observer Docs logoSBOM Observer Docs

Mappings

Configure mappings to transform data during indexing


Mappings provide user-defined transformations of names and identifiers during the indexing (import) process. This can be used to solve use-cases like:

  • Fix data quality issues
  • Solve legacy data issues
  • Renaming issues
  • Making sure suppliers or components are identified as 'being-the-same-as'

Configure mappings

Configure at Settings → Data Model

Mappings are configured by providing a patternreplacement pair.

  • Pattern can be a simple string to be matched exactly or a regular expression [^1].
  • Replacement is a simple string

What makes mappings so powerful is that they are applied recursively, the patterns will be applied on the replacement value until there are no more matching patterns.

Mappings only take effect during indexing (i.e. importing SBOMs). Changing a mapping will not affect already imported SBOMs. To apply to indexed data, archive and re-import SBOMs.

SBOM Observer uses the Go flavour of regular expressions

Example - Consolidate Suppliers

Scenario

You have multiple SBOMs that include components with Microsoft as supplier. The problem is that each SBOM uses slightly different names, Microsoft, Microsoft Inc., Microsoft Corporation etc. These will be identified as separate suppliers in SBOM Observer.

By adding a mapping like this:

screenshot

All suppliers that start with Microsoft (or microsoft) will map to the same name, and therefore the same supplier.