Documentation Index

Fetch the complete documentation index at: https://help.nucleussec.com/llms.txt

Use this file to discover all available pages before exploring further.

Regex Matching

Prev Next

Overview

Nucleus provides numerous opportunities to match data from different sources to automate processes in the Nucleus console. For example, you might want to search for naming conventions across different teams to standardize your organizational hierarchy.

You can use regex matching in Nucleus wherever an indicator is shown for wildcard matching (*). To use regex matching, specify two forward slashes and type your regex expression within them.

If you would like to specify different options to apply on the regular expressions, you will need to do so within the opening and closing forward slashes. For example, if you want the regular expression matches to be case insensitive, you will need to specify it like this:
/(?i)<replace-this-with-your-regular-expression>/

Examples

For example, when trying to match all assets which have a name of 'asset_unique_identifier', you have two options:

  1. Wildcard matching
asset_*
  1. Regex matching
/asset/ - any asset that has the string "asset" in its name

or 

/^asset/ - only assets that begin with the name "asset"

Since any regex expressions will work within the // you can feel free to be as creative as you want, such as including OR operators, character classes, and more.

NOTE: Outside the // will still resolve and attempt to match, so mixing and matching regex with standard wildcard matching might have unintended consequences. For example /<valid-regular-expression>/i will also try to match the letter 'i' as well as the regex expression within the double slashes.

Places you can use this in Nucleus

Again, you can use regex matching anywhere there is an indicator for wildcard matching; it is especially useful in the automation section of Nucleus. Some examples where this can come in handy:

If you have questions about regex matching in Nucleus, let us know! We are happy to help!