﻿---
title: Destructive deletes allow wildcards
description: Describes what AutoOps detects and surfaces with the Destructive deletes allow wildcards insight: The cluster still allows destructive index operations with wildcards or `_all`, so one delete request can target many indices at once.
url: https://docs-v3-preview.elastic.dev/elastic/autoops-insights/tree/main/elasticsearch/destructive_deletes_allow_wildcards
products:
  - Elastic Cloud Enterprise
  - Elastic Cloud Hosted
  - Elastic Cloud on Kubernetes
  - Elasticsearch
applies_to:
  - Elastic Cloud Hosted: Generally available
  - Elastic Cloud on Kubernetes: Generally available
  - Elastic Cloud Enterprise: Generally available
  - Self-managed Elastic deployments: Generally available
---

# Destructive deletes allow wildcards
The cluster still allows destructive index operations with wildcards or `_all`, so one delete request can target many indices at once. That pattern is a common source of accidental data loss.
<note>
  For a complete list of insights, refer to [AutoOps insights](https://docs-v3-preview.elastic.dev/elastic/autoops-insights/tree/main/elasticsearch).
</note>


## Insight details


| Field     | Value           |
|-----------|-----------------|
| Component | Elasticsearch   |
| Severity  | Medium          |
| Scope     | Cluster         |
| Domains   | security-safety |


## Example: What you might see in AutoOps

The following is an example of what you might see when this insight is triggered. Real insights use live data and links from your deployment or cluster.

### Destructive index deletes can use wildcards


#### What was detected

`action.destructive_requires_name` is false. Destructive operations such as index deletes can use wildcards or `_all`.

#### Recommendations

<note>
  AutoOps shows different recommendations depending on how their conditions match your deployment or cluster.
</note>

<dropdown title="Prevent deletion of wildcard indices">
  **Condition**: Always shown for this insight.Enable `action.destructive_requires_name` so index deletes must name a specific index and cannot use wildcards. Use the action below.
  ```json

  {
    "persistent": {
      "action.destructive_requires_name": "true"
    }
  }
  ```

  <note>
    Requires the `manage cluster` privilege. Requires Elasticsearch 8.0.0 or later. This action changes cluster or index configuration.
  </note>
</dropdown>


#### Background and impact

When `action.destructive_requires_name` is false, Elasticsearch accepts delete (and similar destructive) requests that target many indices at once through wildcards or `_all`.
A single mistaken request can remove large parts of a cluster’s data. Production clusters usually require an exact index name so operators cannot wipe multiple indices by accident.
Until the setting is enabled, any client with delete privileges can still perform broad destructive operations.