htb_hosts_select
Resolve managed Hack The Box host entries by fuzzy pattern and return bare IP or hostname values, optionally narrowing by multiple patterns and selecting indexed results for immediate use in commands.
Instructions
Look up managed entries by fuzzy pattern and return just their bare values, ready to feed into another command. patterns matches against ip/tag/hostname, and several patterns NARROW (every one must match). field picks what comes back: 'ip' (default) or 'host'. Use this to resolve a box name to its IP before scanning.
Input Schema
| Name | Required | Description | Default |
|---|---|---|---|
| field | No | Which values to return (default 'ip') | |
| index | No | Keep only these 1-based values when a box has several (a hostname per vhost): 2, -1 for the last, the range '2-4', or the list '1,3'. Omit to return them all. | |
| patterns | No | Fuzzy patterns, e.g. ['machine']; omit to match everything |