Skip to main content

Supplemental Rules

Supplemental rules extend Bulwark’s built-in health checks with custom detections — no code required. Rules are plain-text files (YAML, JSON, or XML) that describe conditions to evaluate against the data Bulwark collects from an AD environment. Triggered rules appear in the supplemental_rule_results list in the output alongside built-in findings.

How It Works

When Bulwark completes data collection, it loads all supplemental rules from the path you specify. Each rule’s conditions are evaluated against the collected HealthCheckData. If a rule’s conditions are satisfied, it is added to the results. Rules that do not trigger are silently skipped. If a field referenced by a criterion is not present in the collected data, Bulwark attempts a live LDAP query to retrieve it (see LDAP Fallback).

Supplying Rules

CLI

TUI

From the main menu, select Rules — Ingest and manage supplemental rules, then type the path to a file or directory and press Apply.

Rule File Format

Each file must contain a top-level rules list. A single file may contain multiple rules.

YAML

JSON

XML


Rule Fields


Conditions


Operators

All values are strings. Numeric operators convert both sides automatically.

LDAP Fallback

If a field path cannot be resolved from collected data, Bulwark performs a live LDAP query using one of four structured notations — all prefixed with ldap..

Notation 1 — Attribute Lookup: ldap.<attr>

Searches the domain object for the attribute, falls back to subtree scan.

Notation 2 — Type Attribute Query: ldap.<type>.self.<attr>

Searches all objects of <type> and returns every value of <attr> as a list.

Notation 3 — Type + Filter Query: ldap.<type>.filter.<ldap-filter>

Finds objects of <type> matching the raw LDAP filter. Returns distinguished names as a list.

Notation 4 — Raw Filter Query: ldap.filter.<ldap-filter>

Searches the entire domain with a raw LDAP filter. No type restriction.

Supported Object Types

Unrecognized tokens fall back to (objectClass=<token>).

Examples

Multi-Rule YAML File

OR Condition (XML)