This project is a Python-based port scanner designed for educational purposes. It allows users to scan open TCP ports on a target machine. The tool can be used via a command-line interface or a web-based GUI built with Flask.
- Scans the top 1000 TCP ports by default.
- Allows custom port range scanning.
- Logs scan results to a file for later analysis.
- Displays scan duration and performance metrics.
- Web-based GUI for ease of use.
- Input validation and error handling.
- Clone the repository or download the project files.
- Navigate to the
Port_Scanner_(Python)directory. - Install the required dependencies:
pip install -r requirements.txt
- Run the
port_scanner.pyscript:python port_scanner.py
- Enter the target IP address when prompted.
- Run the Flask application:
python app.py
- Open your browser and navigate to
http://127.0.0.1:5000. - Enter the target IP address and optional port range, then click "Scan".
Scan results are saved in the logs folder within the Port_Scanner_(Python) directory. Each log file is named with the target IP and timestamp.
Refer to the example.txt file for sample target IPs to use for testing.
This tool is intended for educational purposes only. Ensure you have proper authorization before scanning any network or device. Unauthorized scanning is illegal and unethical.
- Networking basics
- TCP/IP
- Ethical scanning principles
