Skip to main content
Version: 0.10

Scan templates

A scan template is a saved, runnable scan. It ties together three things:

  • One integration instance: the connection the scan collects through, and so the sensor it runs on.
  • That integration's scan settings: timing limits and what happens to new and changed assets. The integration declares them, so they differ from one integration to the next.
  • Rules (optional): conditions and actions applied to every change the scan produces, before it reaches the inventory.

Templates live under Scans → Templates. From there a template can be run straight away, put on a schedule, duplicated or deleted. For how templates fit with schedules and runs, see Scanning.

Creating a template​

Select New template. The wizard has three parts.

1. Choose the integration instance​

The first screen lists every integration instance connected in the tenant, with its integration type and sensor. When there are more than six, a search box filters them by name, integration or sensor. Select the one this template should scan with.

If the tenant has no integration instances yet, the wizard says so and offers Go to integrations. Connect one there first (see Integrations).

The integration instance cannot be changed after the template is created. To scan through a different instance, create another template.

2. Fill in the integration's settings​

The wizard then shows one step per group of settings that the integration declares, in this order:

StepWhat it holds
BasicsTemplate name and Template Description
AdvancedTiming limits applied while the scan runs, such as the scan timeout
ActionsWhat the platform does with what the scan finds: new assets, updated assets and missing assets

An integration that declares further groups gets a step for each, after these. The settings common to most integrations, and their defaults, are listed in Integrations: Configuration model; settings specific to one integration are on that integration's page.

Each step checks its own required fields when you select Next. The final Create template checks every step again and returns you to the first one with a problem.

Rules for the name and description:

  • The name is 2 to 64 characters and may contain letters, digits, spaces and . - _ : / \. Parentheses, apostrophes, &, + and # are refused.
  • The name must be unique among the tenant's scan templates.
  • The description is optional, up to 500 characters.
Hold new assets for approval on a new source

Setting On New Asset Discovered to To Approve for the first runs of a new integration lets you see what it would create before anything is written. The run waits in Awaiting approval until you approve it; see Reviewing a scan.

3. Add rules (optional)​

The last step, Rules, is optional. With no rules, everything the scan reports is applied to the inventory as it is. Select Create template to finish; the template's page opens.

Rules​

A rule says: when these conditions hold for a change, then do these things. Rules let you correct a field a source gets wrong, drop a field you do not want from that source, or ignore some of its records entirely.

Rules run during the Identification stage, on every change entry the scan produces, before any change is shown for review or written to an asset.

When: conditions​

Each rule has one or more conditions and a setting that combines them:

CombinationThe rule applies when
all of these matchevery condition is true
any of these matchat least one condition is true
none of these matchevery condition is false
any of these does not matchat least one condition is false

A condition names a field from the tenant's field list, an operator and, for most operators, a value:

OperatorValue
is / is notOne value
is one of / is not one ofSeveral values, separated by commas
exists / does not existNone
starts with / ends withOne value
contains / does not containOne value

The value box adapts to the field: a true/false picker for a boolean field, a number box for integer, decimal, date and date-time fields, free text otherwise.

Conditions read the scan, not the asset

A condition is checked against the fields in the change the scan produced, not against the existing asset. If the change does not carry the field at all, does not exist is true and every other operator is false.

Text comparisons are case-sensitive: Microsoft does not match microsoft. On a multi-value field the values are compared as one piece of text, so conditions work most predictably on single-value fields.

Then: actions​

Each rule has one or more actions:

ActionWhat it does
Set field valueReplaces whatever the scan reported for one field with the value you enter. If the scan did not report the field, it is added to the change
Remove fieldDrops one field from the change; the rest of the change is still applied
Discard the whole changeThe change is dropped and the scan result is ignored for that record

Order and validation​

Rules run in the order listed, and each rule sees the change as the rules before it left it. Once a rule discards a change, later rules do not see it.

A rule cannot be saved unless it has at least one condition, every condition names a field, it has at least one action, and every field action names a field. A collapsed rule shows a one-line summary such as When OS is → set field value; select it to open its conditions and actions.

Example​

An integration reports some embedded devices that you do not want in the inventory, and labels the operating system vendor inconsistently:

  • Rule 1: when OS contains Embedded, then Discard the whole change.
  • Rule 2: when OS Vendor is one of MS, msft, then Set field value OS Vendor to Microsoft.

Field names in your tenant may differ; the field picker lists the ones that exist.

Editing a template​

Open a template from the list to see its page:

  • Settings shows the integration's settings grouped as in the wizard.
  • Rules holds the same rule editor as the wizard.
  • About shows how many scans the template has run (linking to them in Scans → History), its integration instance and sensor, its mode (Sensor-collected or File upload), when it was created and modified, and its id.

Settings and rules save together: change either, then select Save changes, or Discard to go back to the saved version. The page header also offers Run now (or Run with a file) and Schedule.

Saved secret values (passwords, keys) are not shown again. Leave a secret field as it is to keep the stored value.

Duplicating a template​

Duplicate (on the template's page) or Duplicate template (in the list's row menu) creates a copy named <name> - copy, with the same integration instance, settings and rules. Saved secrets are not copied: enter them again in the copy.

Deleting a template​

Use Delete template on the template's page or in the list's row menu, or tick several rows and choose Delete templates. Schedules that run the template are deleted with it. Assets its scans created or updated stay as they are. Deleting cannot be undone.

TODO

The console states that scans the template already ran stay in history after the template is deleted. The database declares scan runs as deleted together with their template, so whether past runs survive could not be confirmed from the code. Verify before publishing.

Templates that scan a file​

Some integration instances are set up as isolated: no sensor reaches out to the source, and the scan instead analyses a file you upload. The Active Directory and Active Directory Users integrations offer this through their Isolated Integration setting.

A template on an isolated instance behaves differently:

  • Run becomes Run with a file (or Run with a file… in the list). It opens a dialog that asks for the CSV export to analyse; select Start scan once a file is attached.
  • It is skipped when you tick several templates and choose Run scans; the console tells you how many were skipped.
  • It cannot be put on a schedule: Velum Edge refuses to create a schedule for it, because every run needs its own file.
  • Its sensor must still be enabled.

There is no upload size limit by default; your deployment can set one.

See also​