Assignment rules send each finding to the group that should fix it. You pick a method, such as a fixed user group, a group field on the configuration item, or a script, and set an execution order. Rules run from lowest order up, the first match wins, and a default rule catches what is left.
Choose the right assignment method for each rule
Each rule uses one of three methods to choose its group. The right one depends on where ownership data already lives and how much logic the rule needs. The options offered for the first two methods change with the tables you select in the Applies to field.
- User Group: assigns each matching finding to one group you select. Use it when a category of findings belongs to one team, whichever configuration item it touches.
- User Group Field: uses an assignment group field from the cmdb_ci table, so the owner is whatever the configuration item already records.
- Script: evaluates conditions you write yourself. This method requires coding or advanced ServiceNow expertise, so reserve it for logic the other two methods cannot express.
Assignment rules run when a finding is created, whether imported or entered manually, when a finding is reopened, and when a modified finding has its rules reapplied manually. For how assignment groups are set on rules in general, see assignment groups for Vulnerability Response rules.
Set execution order so the right rule matches first
The system evaluates rules in ascending execution order and applies the first rule that matches a finding. If no rule matches and a default rule is configured, the finding goes to the default group. If no default rule exists, the finding stays unassigned.
Order rules from specific to general
Arrange rules in three tiers. Put high priority rules first, for findings where the risk is critical, the item needs special handling, or regulatory compliance requires a fix. Put general rules next, for findings whose responsible party you understand well. Finish with a default rule that sends everything else to a group able to triage the leftovers and add rules of its own. The default rule should carry the highest execution order value so it runs last.
In the Security Exposure Management Workspace, drag rules into position on the Rules list page to change their order. Re-check the order after you add a rule, because a new rule placed above an existing one changes which rule matches first.
Build a rule that routes vulnerable items by business service
Some teams want vulnerable items routed by the business service they affect rather than by a fixed group. A script rule handles this. Because it requires scripting, treat it as an advanced option and test it on your instance before you rely on it.
This rule requires the sn_vul.vulnerability_admin role. Follow these steps:
- Go to All > Vulnerability Response > Administration > Assignment Rules.
- Select New and fill in the fields on the form.
- In the Assign using choice list, select Script.
- In the script editor, enter a script that reads the configuration item on each vulnerable item and collects the business services that item affects.
- Within the script, pick one of those services by business criticality, read its support group, and return that group as the assignment.
- If no service matches, or the matched service has no support group, return the Vulnerability Analyst group.
- Select Submit.
The script limits how far it walks the CMDB with two system properties, sn_sec_cmn.services_affected_by_CI_max_depth and sn_sec_cmn.services_affected_by_CI_max_size. When either property is missing, the script falls back to 10 for depth and 1000 for size. Change them when your service relationships run deeper or wider than those values.
Confirm that the fallback group exists before you save the rule. Review where the new rule sits in the execution order as well. A broad script placed above a specific rule can take findings that the specific rule was meant to handle, so move the script down the list if it matches too much.
For help planning this work, see ServiceNow implementation.
Apply rules to existing open findings
A new or changed rule does not reach existing findings until something applies it. Two mechanisms handle that.
- Run assignment rules job: runs daily to apply rules to open findings. The job is inactive by default. Set its schedule (daily, weekly, monthly, on demand, and so on) to match the size of your environment. The job skips findings that were manually assigned.
- Reapply button: applies updated rules to all open findings. Manually assigned findings are excluded from this process.
After the initial run, set the Run field on the job to suit how many active findings you have, so the job does not affect performance. Because both mechanisms skip manually assigned findings, review those first if you expect a reapply to move them.
Link findings to remediation tasks
The Link to Remediation Tasks business rule on the Findings table is what turns assignment results into remediation task groupings. It evaluates the assignment rules and applies them to newly created or modified findings.
- Go to System Definition > Business Rules.
- Find the Link to Remediation Tasks business rule and open it.
- Select the Active check box.
With the business rule active, a finding is regrouped under a relevant remediation task when one fits, and a new group is created when none does. Manual changes do not trigger regrouping. Rule-driven updates do. Remediation tasks themselves are not deleted. Only findings are removed or regrouped.
Unlink findings when rule conditions change
To unlink findings from earlier remediation tasks when their rule conditions no longer match, set the sn_sec_rem.rerun_task_rules system property to true. Open All > System Properties > All Properties, find the property, and enter true in the Value field. The same property also regroups findings when reapplied rules change their assignment group.
How remediation tasks inherit assignment groups
Remediation task rules take their assignment groups from the findings. When findings on several configuration items land in different groups, a remediation task can split accordingly. If you change the assignment group on a remediation task, all findings in that task that shared the original group change with it. Those findings are marked as manually assigned and drop out of later automatic rule evaluation.
For how remediation tasks get their owners, see how remediation tasks are assigned.
Assignment behavior differs by finding type
Each finding type handles rules a little differently, so check the entry for your type before you write rules for it.
- Vulnerable items (VITs): the base system includes an Assign to CI Support Group rule. Use execution order to place critical, general and fallback rules around it.
- Container vulnerable items (CVITs): only one matching rule applies. Rules skip CVITs that are not Open and CVITs that were manually assigned.
- Configuration test results (CTRs): the logic is similar, but the default assignment rule is inactive until you activate it.
Terminology changed in v14.9. A rule type labeled Group Rules in earlier releases appears as Remediation Task Rules from that version on.
Remove wrong assignments from findings and tasks
If a finding or remediation task landed with the wrong owner, you can remove yourself or your group from the Assigned to and Assignment group fields on that record. Use this for a single bad assignment. Before you clear a field, check which group the record holds now, so you clear the right one. When the same mistake keeps recurring, fix the rule that produces it.
For the full steps, see removing assignments from vulnerable items and remediation tasks.
Common questions about rule methods, reruns and default ownership
When does a User Group Field rule beat a fixed User Group rule?
Choose a User Group Field rule when the configuration item already records the owning team and that record stays accurate. A fixed User Group rule fits better when one team owns a category of findings no matter which configuration item they touch. If the owner field is often blank or wrong, correct the cmdb_ci records first, because the rule routes findings by what the record says.
Can a script fall back to a group other than Vulnerability Analyst?
Yes. The fallback group is named in a variable inside the script, so replace the name with the group you want.
Should I turn on the rerun property?
Turn it on when you expect rule changes to move findings that already sit in remediation tasks. If your rules are set once, before findings arrive, the property matters less.
Who should own configuration test results when no rule matches?
Activate the default assignment rule for CTRs and point it at a triage group. Without a default rule, unmatched CTRs stay unassigned. A triage group can read the unmatched results and write narrower rules as patterns show up.