User Guides

How to operate Nmap with a proxy

Anastasia Lukinova
Anastasia Lukinova
17 June 2024 • 2 min read

Nmap is a tool that allows you to scan ports and perform many other network operations. The main uses of Nmap include:

  • Determining the connection security level;
  • Analysis of services running on the node;
  • Definition of operating systems and applications;
  • Determining the type of firewall used on the scanned host.

Using a proxy server in conjunction with this tool allows you to hide the real IP address of the scanner, which significantly increases anonymity when performing port scanning. This is especially important when performing penetration testing or security research to avoid detection. Additionally, if the scanner's IP address is blocked by the target system or firewalls, using a proxy can bypass these restrictions by providing an alternative IP address to access the target host. For more stable sessions during security research, ISP proxies can be a practical choice because they tend to have a more consistent reputation than many datacenter ranges.

Integrating a proxy server in Nmap

Integration of a proxy into the Nmap tool is facilitated using the ProxyChains program through specific commands. To set up this combination, follow these step-by-step instructions:

  1. Install ProxyChains using a package manager with the command:

“sudo apt-get install proxychains”

  1. Open the ProxyChains settings file for configuration, usually located at “/etc/proxychains.conf”. Open this file in a text editor with the command:

“sudo nano /etc/proxychains.conf”

  1. In the opened file, enable the “strict_chain” line by removing the “#” character before it. This setup routes the traffic specifically through the proxies listed.

    1.png

  2. Locate the line “proxy_dns” and remove the “#” before this line to ensure DNS requests are routed through the proxy, thus preventing the end server from seeing the user's DNS.

    2.png

  3. Scroll down to find an example of how to enter proxy server data. Replace or add your proxy details at the bottom of the file using the provided templates. Save the changes with “CTRL+S”. If your environment supports IPv6, you can also add an IPv6 proxy entry to ProxyChains using the same template format.

    3.png

    4.png

  4. To run Nmap through ProxyChains, prepend the Nmap command with proxychains. For example:

“proxychains nmap -sT -p 80 example.com”

With these settings, the proxy setup is complete. This configuration will help hide your real IP address and circumvent any network restrictions of the target resource. It is advisable to buy private proxy access to ensure a high level of connection anonymization.

PROXIES FROM $0.02/IP

Ready to put this into practice?

Pick a proxy type and location, and start using it within minutes.

See pricing

Instant delivery

24/7 support

Refund policy


Share:

About the author

Anastasia Lukinova

Anastasia Lukinova

Editor & Content Manager @ Proxy-Seller
Editor & Content Manager at Proxy-Seller. Writes step-by-step how-to guides on proxy setup and tool configuration — every workflow is verified end-to-end before publication.

Related articles

Insights

What Is a Port Scanning, and How to Perform It

This article explores the specifics of internet port functionality, their role in the network, and how to check for open and closed ports using an IP port scanner to enhance the security of a user's network.
23 July 2024
Insights

What Do IP and Port of Proxy Server Mean?

Setting up a proxy server often feels like you're staring at an incomprehensible collection of digits. It's an IP address, then a colon, then a port number. This is something so simple to look at, yet fundamentally opaque to many users.
10 March 2021
User Guides

How to set up a proxy in ProxyChains on Linux

Explore Proxychains, a comprehensive guide to setting up a proxy in Linux, step-by-step configuration via the command line, and how it enhances your system's capabilities.
12 December 2023