GV

GeezerVison

The World Wide Web, restored to 800 pixels of glory.

Home|About|Gaming cabinet|Archives|How it works|Starter sites

On this site

  • Sign in
  • ActionsCI/CD and automation
  • CodespacesCloud development environments
  • All Features
  • Documentation
  • Training
  • Certifications
  • Build with Copilot
  • Customize Copilot
  • Integrations
  • Trending repos
  • GitHub Sponsors
  • Developer articles
  • Enterprises

This view

  • Original page
  • New address

GeezerVison is showing github.com — GitHub - devogabs/port-scanner: a little port scanner to learn about networks.

BranchesTags
Open more actions menu

Latest commit

 

History

6 Commits
6 Commits

Folders and files

NameName
Last commit message
Last commit date
src
src
 
 
.gitignore
.gitignore
 
 
README.md
README.md
 
 
requirements.txt
requirements.txt
 
 

Repository files navigation

Simple Python Port Scanner

I built this project to get comfortable with Python's socket library and to understand how network connections work under the hood. It started as a basic script and I've been refactoring it to make it faster and more efficient.

What it does

  • Scans a range of TCP ports on a target IP address.
  • Uses multithreading (ThreadPoolExecutor) to scan ports in parallel (much faster than a basic loop).
  • Identifies your own public IP for testing purposes.

How to run it

  1. Clone the repo: git clone https://github.com/devogabs/python-port-scanner.git cd python-port-scanner

  2. Install dependencies: pip install -r requirements.txt

  3. Run the scanner: python src/scanner.py

What I learned building this

  • Sockets: I learned how the TCP three-way handshake works and how connect_ex returns error codes instead of crashing the program.
  • Concurrency: My first version was very slow. I learned how to use ThreadPoolExecutor to handle hundreds of port checks at the same time.
  • Lambda Functions: I used lambdas to pass arguments into my threaded functions—which was confusing at first, but makes the code a lot cleaner.

Next Steps / Roadmap

  • Add a SYN scan (stealth scan) using Scapy.
  • Add the ability to export results to a .csv file.
  • Implement a GUI or a more robust CLI with argparse.

Disclaimer: This tool is for educational purposes only. Do not use it to scan networks you do not own or have explicit permission to test.

About

a little port scanner to learn about networks.

Topics

networkportscannerpythonsocket

Resources

Readme
Activity

Stars

0 stars

Watchers

0 watching

Forks

0 forks
Report repository

Releases

Packages

Contributors

Languages

You are visitor 01402520 — GeezerVison does not store the pages you look up.
Best viewed with Netscape Navigator 4.7 or Internet Explorer 6 at 800×600. No cookies required.