Dark

Scanning Network

Network and port scanning is a key step in cybersecurity. It involves analyzing important details like a network's setup and system information to find possible entry points for attacks. This process is important for protecting networks from potential threats


Key Ideas of Advanced Scanning

Network and port scanning is more than just basic research. In this phase, testers find out detailed information about the target, such as open ports, running services, operating systems, and weak spots in configurations. The information collected here helps in creating strong strategies to break into the target system or network.


Goals of Advanced Network and Port Scanning

The main goals include:

  • Finding live systems and open ports on complex networks.
  • Discovering services running on open ports, even if they use uncommon protocols.
  • Doing detailed OS detection and identifying the specific versions of operating systems and software.
  • Finding hidden vulnerabilities in the network, like weak encryption or poorly set-up services.

Overview of Advanced Scanning Networks

Advanced network scanning involves using detailed research techniques to gather in-depth information about the target. This process is used to find hidden communication channels, exploit services running on unusual ports, and avoid detection systems like Intrusion Detection Systems (IDS) and firewalls.

Types of Advanced Scanning:

  • Port Scanning: This not only finds open ports but also identifies the services running on them, even if they are hidden or using unusual ports.
  • Network Scanning: This finds active hosts and maps their IP addresses, focusing on identifying complex network structures.
  • Vulnerability Scanning: This goes beyond basic scans to find hidden vulnerabilities, like new exploits or poorly configured systems.

Understanding Ports and Protocols

Ports are like doors on a building, allowing data to enter and leave a network. Each port number represents a different service. For example, port 80 is used for regular web traffic (HTTP), like the front door of a building, while port 443 is used for secure web traffic (HTTPS), like a door with a security guard. Here are some important ports you should know about:

  • Port 21: Used for FTP (File Transfer Protocol), which helps transfer files between a client and a server.
  • Port 22: SSH (Secure Shell) is used for secure logins, file transfers, and port forwarding.
  • Port 23: Telnet, an old protocol used for text communications, which is mostly outdated due to security issues.
  • Port 25: SMTP (Simple Mail Transfer Protocol) is used for sending emails.
  • Port 53: DNS (Domain Name System) queries, essential for converting domain names into IP addresses.
  • Port 80: HTTP, used for standard web traffic on the internet.
  • Port 110: POP3 (Post Office Protocol 3), used by email clients to get emails from a server.
  • Port 143: IMAP (Internet Message Access Protocol), another protocol for getting emails, with more features than POP3.
  • Port 443: HTTPS, which secures HTTP communications with SSL/TLS.
  • Port 3306: MySQL database connections.

Some websites use unusual ports to either hide their services or to run multiple services on the same IP address without conflicts. For example, running a web service on port 8080 or 8443 instead of the standard 80/443 can help avoid detection or make automated attacks less likely.


Tools for Network Scanning

Advanced tools and techniques are used for network and port scanning. Below are tools that help on finding network informations.

Advanced Host Discovery using Nmap
Nmap is a powerful tool that can be used for stealthy host discovery, using methods like SYN scans and decoy scanning to avoid detection.
Example command:

This command performs a stealth scan (SYN scan) with decoy addresses to hide the tester's true location.

Comprehensive Port and Service Discovery using Masscan
Masscan can scan the entire Internet in minutes, making it great for finding open ports across large networks.
Example command:

This command scans all 65,535 ports on a given subnet at a speed of 1,000 packets per second.

Identifying Hidden Services using ZMap
ZMap specializes in scanning networks quickly with single-packet probes, which can find hidden or obscure services.
Example command:

This command scans for HTTPS services on a specific network.

Advanced OS Discovery using Nmap Script Engine (NSE)
Nmap’s NSE scripts allow for detailed OS detection and can also identify specific software versions or interact with services.
Example command:

Advanced Vulnerability Scanning with OpenVAS
OpenVAS is a free vulnerability scanner that provides detailed scanning capabilities, including finding new vulnerabilities.
Example task:

  • Set up OpenVAS to scan a target network for vulnerabilities and generate detailed reports on potential weaknesses.

Additional Advanced Network Scanning Tools on GitHub

Here are some more advanced network scanning tools available on GitHub:

  • RustScan: A very fast port scanner that works with Nmap for detailed scanning after a quick initial scan.
  • Arachni: A high-performance web application security scanner that also scans networks for vulnerabilities in web systems.
  • Nuclei: A fast, customizable vulnerability scanner that uses YAML templates, perfect for automating security checks across large networks.
  • AutoRecon: A multi-threaded network reconnaissance tool that automates the initial scanning process and provides detailed output.
  • Sn1per: An automated scanner that combines various tools for vulnerability scanning, port scanning, and network reconnaissance.
  • Censys: A Python wrapper for the Censys API, used for large-scale Internet scanning and searching for devices and services worldwide.
  • Metasploit Pro: While not a free tool, Metasploit Pro offers advanced network scanning as part of its comprehensive penetration testing framework.