> ## Documentation Index
> Fetch the complete documentation index at: https://docs.kikimora.io/llms.txt
> Use this file to discover all available pages before exploring further.

# Creating a custom policy

> Build your own SCA benchmark with the four-step wizard by picking checks from a base policy and assigning target endpoints.

A custom hardening policy lets you tailor SCA benchmark checks to a specific environment, keeping only the rules that matter and applying them to the endpoints you choose.

Creating one requires the **Wazuh SCA preset store permission**. Without it, the **Create Custom Policy** button is not visible.

## The four steps

1. **General Information** — name the policy and pick the base benchmark.
2. **Select Checks** — choose which compliance rules to include from that benchmark's catalogue.
3. **Select Endpoints** — choose which endpoints to evaluate.
4. **Review** — confirm your selections and save.

## Create a policy

1. On **Hardening Assessments** (`/compliance/hardening`), click **Create Custom Policy**.

2. On **Step 1**, enter a policy **Name** and select a base benchmark from the **Policy** combobox, then click **Next**.

   <img src="https://mintcdn.com/kikimora/_61TKijx1WdBSLGY/images/compliance-hardening/wizard--01--step1-validation.png?fit=max&auto=format&n=_61TKijx1WdBSLGY&q=85&s=8107eb740f6cf276789ca8a26d7d2d0d" alt="Step 1 of the wizard showing inline validation errors on the empty name and policy fields" width="1920" height="1080" data-path="images/compliance-hardening/wizard--01--step1-validation.png" />

3. On **Step 2**, select the compliance checks to include. Click any check title to preview its full detail before deciding.

   <img src="https://mintcdn.com/kikimora/_61TKijx1WdBSLGY/images/compliance-hardening/wizard--04--step2-selected.png?fit=max&auto=format&n=_61TKijx1WdBSLGY&q=85&s=0af316c219bf95f251683abcd9060229" alt="Step 2 with compliance checks selected from the benchmark catalogue" width="1920" height="1080" data-path="images/compliance-hardening/wizard--04--step2-selected.png" />

4. Click **Next**. If nothing is selected, a toast blocks you.

   <img src="https://mintcdn.com/kikimora/_61TKijx1WdBSLGY/images/compliance-hardening/wizard--03--step2-validation.png?fit=max&auto=format&n=_61TKijx1WdBSLGY&q=85&s=fb0a033087721a7a37fabae3e41596bd" alt="Step 2 showing the toast error returned when no checks are selected" width="1920" height="1080" data-path="images/compliance-hardening/wizard--03--step2-validation.png" />

5. On **Step 3**, select the target endpoints. The table shows Name, IP, and a connection status badge for each.

   <img src="https://mintcdn.com/kikimora/_61TKijx1WdBSLGY/images/compliance-hardening/wizard--06--step3-selected.png?fit=max&auto=format&n=_61TKijx1WdBSLGY&q=85&s=165e3f3f492a8b916124d0287d8ea385" alt="Step 3 with target endpoints selected for evaluation" width="1920" height="1080" data-path="images/compliance-hardening/wizard--06--step3-selected.png" />

   <img src="https://mintcdn.com/kikimora/_61TKijx1WdBSLGY/images/compliance-hardening/wizard--05--step3-validation.png?fit=max&auto=format&n=_61TKijx1WdBSLGY&q=85&s=2c6894a7705cbb77b3ae210a6659adef" alt="Step 3 showing the error returned when no endpoints are selected" width="1920" height="1080" data-path="images/compliance-hardening/wizard--05--step3-validation.png" />

6. On **Step 4**, expand the **Selected Checks (N)** and **Selected Endpoints (N)** accordions to confirm everything, then click **Finish**.

   <img src="https://mintcdn.com/kikimora/_61TKijx1WdBSLGY/images/compliance-hardening/wizard--07--step4-review.png?fit=max&auto=format&n=_61TKijx1WdBSLGY&q=85&s=d76e359d6900aec26b5e36d2aa28a1d3" alt="Step 4 review with the selected checks and endpoints accordions expanded" width="1920" height="1080" data-path="images/compliance-hardening/wizard--07--step4-review.png" />

## Validation and behavior

| Step | Condition                | Message                                 |
| :--- | :----------------------- | :-------------------------------------- |
| 1    | Name left blank          | `Name is required`                      |
| 1    | Base policy not selected | `Policy is required`                    |
| 2    | No checks selected       | `Select at least one compliance check.` |
| 3    | No endpoints selected    | `Select at least one endpoint.`         |

Two behaviors are worth knowing before you start:

**Changing the base policy resets your work.** Selecting a different base policy on step 1 clears every check and endpoint selection you made in later steps. Settle on the base benchmark first.

**Endpoints must have been scanned.** If no base policies exist, or no endpoint has completed an SCA scan, the dropdown reads `No policies found. Endpoints must complete a scan first.`
