Skip to content

Commit 15d0598

Browse files
Merge branch 'main' into issue-287-6493-gaps-manual-runs-9.0-serv
2 parents fcaa577 + 3581831 commit 15d0598

File tree

1 file changed

+35
-41
lines changed

1 file changed

+35
-41
lines changed

solutions/security/detect-and-alert/manage-detection-rules.md

Lines changed: 35 additions & 41 deletions
Original file line numberDiff line numberDiff line change
@@ -63,21 +63,23 @@ For {{ml}} rules, an indicator icon (![Error icon from rules table](/solutions/i
6363

6464
## Modify existing rules settings [edit-rules-settings]
6565

66-
You can edit an existing rule’s settings, and can bulk edit settings for multiple rules at once.
66+
::::{admonition} Requirements
6767

68-
::::{note}
69-
For prebuilt Elastic rules, you can’t modify most settings. You can only edit [rule actions](/solutions/security/detect-and-alert/create-detection-rule.md#rule-schedule) and [add exceptions](/solutions/security/detect-and-alert/add-manage-exceptions.md). If you try to bulk edit with both prebuilt and custom rules selected, the action will affect only the rules that can be modified.
70-
71-
Similarly, rules will be skipped if they can’t be modified by a bulk edit. For example, if you try to apply a tag to rules that already have that tag, or apply an index pattern to rules that use data views.
68+
* You can edit custom rules and bulk-modify them with any [{{stack}} subscription](https://www.elastic.co/pricing) or [{{serverless-short}} project tier](../../../deploy-manage/deploy/elastic-cloud/project-settings.md). Editing [rule notifications](/solutions/security/detect-and-alert/create-detection-rule.md#rule-notifications) (notifications and response actions) for prebuilt rules can also be done with any {{stack}} subscription or {{serverless-short}} project tier.
69+
* You must have an [Enterprise subscription](https://www.elastic.co/pricing) to edit all prebuilt rule settings (except for the **Author** and **License** fields) and bulk-modify them.
7270

7371
::::
7472

7573

7674
1. Find **Detection rules (SIEM)** in the navigation menu or by using the [global search field](/explore-analyze/find-and-organize/find-apps-and-objects.md).
7775
2. Do one of the following:
7876

79-
* **Edit a single rule**: Select the **All actions** menu (**…​**) on a rule, then select **Edit rule settings**. The **Edit rule settings** view opens, where you can modify the [rule’s settings](/solutions/security/detect-and-alert/create-detection-rule.md).
80-
* **Bulk edit multiple rules**: Select the rules you want to edit, then select an action from the **Bulk actions** menu:
77+
* Edit a single rule: Select the **All actions** menu (**…​**) on a rule, then select **Edit rule settings**. Alternatively, open the rule’s details page and click **Edit rule settings**. The **Edit rule settings** view opens, where you can modify the [rule’s settings](/solutions/security/detect-and-alert/create-detection-rule.md).
78+
* Bulk edit multiple rules: Select the rules you want to edit, then select an action from the **Bulk actions** menu:
79+
80+
::::{note}
81+
Rules will be skipped if they can’t be modified by a bulk edit. For example, if you try to apply a tag to rules that already have that tag, or apply an index pattern to rules that use data views.
82+
::::
8183

8284
* **Index patterns**: Add or delete the index patterns used by all selected rules.
8385
* **Tags**: Add or delete tags on all selected rules.
@@ -89,13 +91,13 @@ Similarly, rules will be skipped if they can’t be modified by a bulk edit. For
8991
::::
9092

9193

92-
::::{note}
93-
Rule actions won’t run during a [maintenance window](/explore-analyze/alerts-cases/alerts/maintenance-windows.md). They’ll resume running after the maintenance window ends.
94-
::::
94+
:::{note}
95+
Rule actions won’t run during a [maintenance window](/explore-analyze/alerts-cases/alerts/maintenance-windows.md). They’ll resume running after the maintenance window ends.
96+
::::
9597

9698

97-
* **Update rule schedules**: Update the [schedules](/solutions/security/detect-and-alert/create-detection-rule.md#rule-schedule) and look-back times on all selected rules.
98-
* **Apply Timeline template**: Apply a specified [Timeline template](/solutions/security/investigate/timeline-templates.md) to the selected rules. You can also choose **None** to remove Timeline templates from the selected rules.
99+
* **Update rule schedules**: Update the [schedules](/solutions/security/detect-and-alert/create-detection-rule.md#rule-schedule) and look-back times on all selected rules.
100+
* **Apply Timeline template**: Apply a specified [Timeline template](/solutions/security/investigate/timeline-templates.md) to the selected rules. You can also choose **None** to remove Timeline templates from the selected rules.
99101

100102
3. On the page or flyout that opens, update the rule settings and actions.
101103

@@ -109,7 +111,7 @@ Similarly, rules will be skipped if they can’t be modified by a bulk edit. For
109111

110112
## Manage rules [manage-rules-ui]
111113

112-
You can duplicate, enable, disable, delete, and snooze actions for rules:
114+
You can duplicate, enable, disable, delete, and do more to rules:
113115

114116
::::{note}
115117
When duplicating a rule with exceptions, you can choose to duplicate the rule and its exceptions (active and expired), the rule and active exceptions only, or only the rule. If you duplicate the rule and its exceptions, copies of the exceptions are created and added to the duplicated rule’s [default rule list](/solutions/security/detect-and-alert/rule-exceptions.md). If the original rule used exceptions from a shared exception list, the duplicated rule will reference the same shared exception list.
@@ -179,15 +181,12 @@ You can snooze rule notifications from the **Installed Rules** tab, the rule det
179181

180182
## Export and import rules [import-export-rules-ui]
181183

182-
You can export custom detection rules to an `.ndjson` file, which you can then import into another {{elastic-sec}} environment.
183-
184-
::::{note}
185-
You cannot export Elastic prebuilt rules, but you can duplicate a prebuilt rule, then export the duplicated rule.
186-
187-
If you try to export with both prebuilt and custom rules selected, only the custom rules are exported.
188-
184+
::::{admonition} Requirements
185+
* You can export and import custom rules and prebuilt rules (modified and unmodified) with any [{{stack}} subscription](https://www.elastic.co/pricing) or [{{serverless-short}} project tier](../../../deploy-manage/deploy/elastic-cloud/project-settings.md).
186+
* At minimum, your role needs `Read` privileges for the **Action and Connectors** feature to import rules with actions. To overwrite or add new connectors, you need `All` privileges. Refer to [Enable and access detections](/solutions/security/detect-and-alert/detections-requirements.md#enable-detections-ui) to learn more about the required privileges for managing rules.
189187
::::
190188

189+
You can export custom detection rules to an `.ndjson` file, which you can then import into another {{elastic-sec}} environment.
191190

192191
The `.ndjson` file also includes any actions, connectors, and exception lists related to the exported rules. However, other configuration items require additional handling when exporting and importing rules:
193192

@@ -203,36 +202,31 @@ The `.ndjson` file also includes any actions, connectors, and exception lists re
203202

204203
* **Value lists**: Any value lists used for rule exceptions are *not* included in rule exports or imports. Use the [Manage value lists](/solutions/security/detect-and-alert/create-manage-value-lists.md#edit-value-lists) UI to export and import value lists separately.
205204

206-
To export and import detection rules:
205+
### Export rules [export-rules-ui]
207206

208207
1. Find **Detection rules (SIEM)** in the navigation menu or by using the [global search field](/explore-analyze/find-and-organize/find-apps-and-objects.md).
209-
2. To export rules:
210-
211-
1. In the Rules table, select the rules you want to export.
212-
2. Select **Bulk actions****Export**, then save the exported file.
213-
214-
3. To import rules:
208+
2. Do one of the following:
215209

216-
::::{note}
217-
To import rules with or without actions, and to manage rule connectors, you must have the appropriate user role. Refer to [Enable and access detections](detections-requirements.md#enable-detections-ui) for more information.
218-
::::
210+
* Export a single rule: Find the rule in the Rules table, then select **All actions****Export**. Alternatively, export the rule from its details page (click on the rule name to open its details, then click **All actions****Export**).
211+
* Export multiple rules: In the Rules table, select the rules you want to export, then click **Bulk actions → Export**.
219212

213+
The rules are exported to an `.ndjson` file.
220214

221-
1. Click **Import rules**.
222-
2. Drag and drop the file that contains the detection rules.
215+
### Import rules [impr=ort-rules-ui]
223216

224-
::::{note}
225-
Imported rules must be in an `.ndjson` file.
226-
::::
217+
1. Above the Rules table, click *Import rules*.
218+
2. In the Import rules modal:
227219

228-
3. (Optional) Select **Overwrite existing detection rules with conflicting "rule_id"** to update existing rules if they match the `rule_id` value of any rules in the import file. Configuration data included with the rules, such as actions, is also overwritten.
229-
4. (Optional) Select **Overwrite existing exception lists with conflicting "list_id"** to replace existing exception lists with exception lists from the import file if they have a matching `list_id` value.
230-
5. (Optional) Select **Overwrite existing connectors with conflicting action "id"** to update existing connectors if they match the `action id` value of any rule actions in the import file. Configuration data included with the actions is also overwritten.
231-
6. Click **Import rule**.
232-
7. (Optional) If a connector is missing sensitive information after the import, a warning displays and you’re prompted to fix the connector. In the warning, click **Go to connector**. On the Connectors page, find the connector that needs to be updated, click **Fix**, then add the necessary details.
220+
1. Drag and drop the `.ndjson` file that contains the exported rules.
221+
2. (Optional) Select the appropriate options to overwrite existing data:
233222

223+
* **Overwrite existing detection rules with conflicting "rule_id"**: Updates existing rules if they match the `rule_id` value of any rules in the import file. Configuration data included with the rules, such as actions, is also overwritten.
224+
* **Overwrite existing exception lists with conflicting "list_id"**: Replaces existing exception lists with exception lists from the import file if they have a matching `list_id` value.
225+
* **Overwrite existing connectors with conflicting action "id"**: Updates existing connectors if they match the `action id` value of any rule actions in the import file. Configuration data included with the actions is also overwritten.
234226

227+
The imported rules are added to the Rules table.
235228

229+
236230
## Confirm rule prerequisites [rule-prerequisites]
237231

238232
Many detection rules are designed to work with specific [Elastic integrations](https://docs.elastic.co/en/integrations) and data fields. These prerequisites are identified in **Related integrations** and **Required fields** on a rule’s details page. **Related integrations** also displays each integration’s installation status and includes links for installing and configuring the listed integrations.
@@ -252,5 +246,5 @@ You can also check rules' related integrations in the **Installed Rules** and **
252246
:::
253247

254248
::::{tip}
255-
You can hide the **integrations** badge in the rules tables by turning off the `securitySolution:showRelatedIntegrations` [advanced setting](/solutions/security/get-started/configure-advanced-settings.md#show-related-integrations).
249+
You can hide the **integrations** badge in the Rules tables by turning off the `securitySolution:showRelatedIntegrations` [advanced setting](/solutions/security/get-started/configure-advanced-settings.md#show-related-integrations).
256250
::::

0 commit comments

Comments
 (0)