- 14 Jun 2022
- 2 Minutes to read
Windows DHCP Server
- Updated on 14 Jun 2022
- 2 Minutes to read
Windows DHCP Server is a networking server used to lease IP addresses and manage other configuration information.
Types of Assets Fetched
This adapter fetches the following types of assets:
- Host Name or IP Address (required) - The hostname or IP address of the Windows DHCP server.
- User Name and Password (required) - The credentials for a domain user account that has the Required Permissions to execute PowerShell code which queries the Windows DHCP server for information on the systems managed by that server.
- Encoding (optional, default: utf8NoBom) - Select from the dropdown a custom encoding for the temporary JSON file created on the Windows DHCP server before it is downloaded to Axonius.
- For PowerShell versions 7 and above, select utf8NoBom.
- For PowerShell versions prior to version 7, select utf8.
- For PowerShell version 2, select ASCII.
- For details on the common adapter connection parameters and buttons, see Adding a New Adapter Connection.
From version 4.6 Advanced settings can either apply for all connections for this adapter, or you can set different advanced settings and/or different scheduling for a specific connection, refer to Advanced Configuration for Adapters
- Number of parallel connections (required, default: 20) Specify the maximum number of parallel connections permitted.
- Fetch Timeout Per Parallel Connection (seconds) (required, default: 300, min: 30). Specify the timeout for data to be returned from each parallel connection.
- CIDR Exclusion List - Enter a comma-separated list of IP addresses and CIDRs to exclude from the fetch.
For details on general advanced settings under the Adapter Configuration tab, see Adapter Advanced Settings.
- 135 (RPC)
- 445 (SMB)
- Random port in the range 1024-65535
Setting up a fixed port for WMI
The Windows DHCP Server adapter uses WMI.
You need to set up a fixed port to work with WMI.
WMI runs as part of a shared service host with ports assigned through DCOM by default. However, you can set up the WMI service to run as the only process in a separate host and specify a fixed port. For more details, see Microsoft Documentation - Setting Up a Fixed Port for WMI.
To set up a fixed port for WMI:
- At the command prompt, type:
- Stop the WMI service by typing:
net stop "Windows Management Instrumentation"
net stop winmgmt
- Restart the WMI service again in a new service host by typing:
net start "Windows Management Instrumentation"
net start winmgmt
- Establish a new port number for the WMI service by typing (e.g. the following example will establish port TCP 24158):
netsh firewall add portopening TCP 24158 WMIFixedPort
To undo any changes you make to WMI, type:
Then stop and start the winmgmt service again.
The value supplied in User Name and Password must be able to execute PowerShell code which queries the Windows DHCP server for information on the systems managed by that server.
The supplied User Name must have the following permissions:
- Access RPC on the Windows DHCP server.
- Execute PowerShell on the Windows DHCP server and access the IPC$ share on the Windows DHCP server.
- Access ADMIN$ share on the Windows DHCP server (preferred permissions).