Ecosyste.ms: Awesome
An open API service indexing awesome lists of open source software.
https://github.com/chizuru-nina-yamauchi/port_scanner_with_ip_address
Understanding sockets, port scanning, and TCP connection with Python
https://github.com/chizuru-nina-yamauchi/port_scanner_with_ip_address
port-scanner python socket tcp-connection
Last synced: 6 days ago
JSON representation
Understanding sockets, port scanning, and TCP connection with Python
- Host: GitHub
- URL: https://github.com/chizuru-nina-yamauchi/port_scanner_with_ip_address
- Owner: chizuru-nina-yamauchi
- Created: 2024-06-01T13:23:51.000Z (6 months ago)
- Default Branch: main
- Last Pushed: 2024-06-01T14:06:49.000Z (6 months ago)
- Last Synced: 2024-11-08T21:54:28.441Z (6 days ago)
- Topics: port-scanner, python, socket, tcp-connection
- Language: Python
- Homepage:
- Size: 2.93 KB
- Stars: 0
- Watchers: 1
- Forks: 0
- Open Issues: 0
-
Metadata Files:
- Readme: README.md
Awesome Lists containing this project
README
# Port Scanner with IP address(Simple ethical hacking experiment with Python)
## Overview
This Python script serves as a simple ethical hacking experiment, allowing users to scan ports on a specified IP address to identify open ports. It utilizes the socket module to create TCP sockets and establish connections to each port within a specified range.## Requirements
- Python 3.x## Usage
1. Clone the repository or download the Python script.
2. Open a terminal or command prompt.
3. Navigate to the directory containing the Python script.
4. Run the script by executing the command:```
python port_scanner.py
```5. Follow the prompts to enter the target IP address.
6. The script will scan ports 1 to 1024 on the specified IP address and display the results.## Understanding the code
- The socket module is used for creating network sockets, allowing the script to establish TCP connections to each port.
- TCP (Transmission Control Protocol) connections are established to determine whether each port on the target IP address is open or closed.
- The script utilizes error handling to gracefully handle exceptions such as KeyboardInterrupt and socket errors.## IDE I used
- pycharm## Disclaimer
This script is intended for educational purposes only. Do not use it for any malicious activities. Always seek permission before scanning ports on a network or IP address.