NetExec Generate Hosts File
Generate hosts file and add them to /etc/hosts file
- Tool
- nxc
- Category
- Utilities / Network & Time Setup
- Platform
- linux
- Requires
- no credentials
- Protocols
- SMB
Syntax
Angle-bracket tokens are placeholders — replace them with your target's values, or open this command in the app to fill them in and copy the result.
nxc smb ips.txt --generate-hosts-file hosts.txt && cat hosts.txt | sudo tee -a /etc/hosts
Examples
nxc smb 10.10.11.76 --generate-hosts-file hosts.txt && cat hosts.txt | sudo tee -a /etc/hosts
Tags
Related commands
- Fix Kerberos Time Skew Fix time skew issues for Kerberos authentication