Skip to content

A fast and efficient Python-based port scanner for detecting open ports on single or multiple targets with customizable port ranges and color-coded output.

License

Notifications You must be signed in to change notification settings

AdityaBhatt3010/Basic-Port-Scanner

Folders and files

NameName
Last commit message
Last commit date

Latest commit

 

History

6 Commits
 
 
 
 
 
 
 
 
 
 
 
 

Repository files navigation

Basic Port Scanner

Description

The Optimized Port Scanner is a Python-based network scanning tool that efficiently checks for open ports on a given target IP address or multiple IPs. It allows users to specify a range of ports to scan, defaults to scanning ports 1-1000 if not specified, and provides a user-friendly output using colors.

Features

  • Supports scanning single or multiple IP addresses.
  • Allows users to define a specific port range.
  • Uses socket timeout to speed up the scanning process.
  • Displays open ports in a structured and readable format.
  • Outputs a message if no open ports are found.
  • Colored output for better visibility.

Requirements

Ensure you have Python installed along with the required dependency termcolor.

To install it run the command as follows:

pip install termcolor

Alternatively, simply run:

pip install -r requirements.txt

Usage

  1. Run the script:
    python PortScanner.py
  2. Enter the target IP addresses (comma-separated for multiple targets):
    [*] Enter Targets To Scan (comma-separated): 192.168.1.1,192.168.1.2
    
  3. Enter the port range to scan (or press enter for default 1-1000):
    [*] Enter Port Range to Scan (e.g., 1-1000 or just press enter for 1-1000): 1-500
    

Example Output

[+] Starting Scan For 192.168.1.1
[+] Port 22 is Open
[+] Port 80 is Open
[+] Open Ports: 22, 80

If no open ports are found:

[-] No open ports found. All ports are closed.

Screenshots

Scan Result with Open Ports:

Open Ports

Scan Result with All Ports Closed:

Closed Ports

Author

Developed by Aditya Bhatt.

About

A fast and efficient Python-based port scanner for detecting open ports on single or multiple targets with customizable port ranges and color-coded output.

Resources

License

Stars

Watchers

Forks

Releases

No releases published

Packages

No packages published

Languages