Realm9 Logo
Search documentation...

Compliance

Realm9 automatically scans virtual machines provisioned through Terraform against CIS (Center for Internet Security) benchmarks, giving you a compliance score for each VM and optionally blocking handover until violations are resolved.

Licence requirement: Compliance scanning is available on the Infrastructure Enterprise and Ultimate tiers.
Access: Provisioners and Admins can view results. Only Admins can manage settings and release blocked handovers.


What Gets Scanned

Compliance scans run against VMs provisioned through Terraform runs in Realm9. When a Terraform apply completes and a VM is spun up, a scan is triggered automatically (if Scan on Provision is enabled in settings).

Scans are not run against:

  • Environments or bookings directly
  • Terraform code (that is handled by Terraform Policies)
  • User accounts or configuration

Supported VM providers: AWS, Azure, GCP, VMware vCenter, Proxmox.


CIS Profiles

Choose the benchmark profile that matches your workload:

ProfileUse case
CIS Level 1 ServerBaseline security controls for servers (default)
CIS Level 2 ServerEnhanced hardening for servers
CIS Level 1 WorkstationBaseline controls for workstations
CIS Level 2 WorkstationEnhanced hardening for workstations

Level 1 covers core, broadly applicable recommendations. Level 2 adds more opinionated controls suitable for high-security environments.


Compliance Page

Navigate to Compliance in the sidebar (visible to Provisioners and above).

Overview Tab

Summary cards:

  • Average Score — organisation-wide average compliance percentage (green ≥ 90%, amber ≥ 70%, red < 70%)
  • Total Scans — total VMs scanned
  • Blocked VMs — VMs currently blocked pending remediation
  • Pass Rate — percentage of scans meeting the minimum score threshold

Recent Scans table — last 20 scan results showing:

  • VM hostname or IP
  • Cloud provider
  • Compliance score (percentage)
  • Status badge
  • Critical failure count
  • Scan date
  • Actions: Report (download HTML report), Release (unblock, Admin only)

Scan Results Tab

Full paginated list of all scan results with filtering by status and Terraform project.

Settings Tab

Configure compliance behaviour for your organisation (Admin only):

SettingDescription
Enable CIS ScanningMaster toggle for the feature
Enforcement ModeAudit, Warn, or Block (see below)
CIS ProfileBenchmark profile to apply
Minimum Pass ScorePercentage threshold (0–100, default 70%)
Block on Critical FailuresBlock if any critical checks fail (default: on)
Block on High FailuresBlock if any high-severity checks fail (default: off)
Scan on ProvisionAuto-scan after every Terraform apply (default: on)
Scan on ScheduleRun periodic scans on a schedule
SSH UserOS user for the scanner to connect as (default: ubuntu)
Exempted Rule IDsCIS control IDs to skip globally
Exempted ProjectsTerraform projects to exclude from scanning

Scan Statuses

StatusMeaning
PendingScan created, waiting to start
RunningScanner is actively checking the VM
CompletedScan finished — results available
FailedScanner encountered an error (not a VM compliance failure)
CancelledScan was aborted

Additionally, a completed scan can have a handover blocked flag if enforcement rules are violated (see Enforcement below).


Scan Results

Each completed scan produces:

  • Overall score — percentage of applicable CIS checks that passed
  • Check breakdown — passed, failed, error, and not-applicable counts
  • Severity breakdown — critical, high, medium, and low failure counts
  • Per-rule results — for each CIS control: rule ID, title, status (pass/fail/error), severity, description, and remediation guidance

Report Formats

Three report formats are generated per scan:

  • HTML — human-readable report, downloadable from the UI via the Report button
  • ARF — Assessment Results Format (machine-readable XML/JSON for compliance tooling)
  • JSON — raw structured data with full rule details

Enforcement Modes

ModeEffect
AuditScans run and results are recorded, but no VM is ever blocked. Use for visibility only.
WarnSame as Audit — results recorded, no blocking. Intended for future alerting.
BlockScans run and enforcement rules are evaluated. VMs that fail are blocked from handover until an Admin releases them.

Blocking Rules (Block mode)

A VM is blocked if any of the following apply:

  • Critical failures — if Block on Critical Failures is on and any critical CIS check fails
  • High failures — if Block on High Failures is on and any high-severity check fails
  • Score below threshold — if the overall score is below the configured minimum pass score

When a VM is blocked, its scan record shows the specific reason (e.g. "3 critical CIS check(s) failed").

Releasing a Blocked VM

Admins can release a blocked VM by clicking Release on the scan result. This records the admin's identity and timestamp and allows the handover to proceed. All releases are captured in the audit log.


How Scans are Triggered

Automatic (default): When a Terraform apply completes successfully and produces a VM, a scan is created automatically. This requires Scan on Provision to be enabled.

Scheduled: When Scan on Schedule is enabled, scans run on the configured cron interval.

Manual scan triggering from the UI is not currently available.


Role-Based Access

ActionViewerUserProvisionerAdmin
View compliance page and scan results
Download scan reports
Configure compliance settings
Release blocked VM handovers

Next Steps