Skip to content

dvlinuxx-max/portscope

Folders and files

NameName
Last commit message
Last commit date

Latest commit

 

History

1 Commit
 
 
 
 
 
 
 
 

Repository files navigation

portscope

Concurrent TCP port scanner with service identification and banner grabbing. A connect scan needs no root, so it runs anywhere Python does. Standard library only, no dependencies.

Usage

python portscope.py <target> [options]

target is a hostname, an IP, or a CIDR range (10.0.0.0/24).

python portscope.py scanme.nmap.org
python portscope.py 192.168.1.10 -p 1-1024
python portscope.py 10.0.0.0/24 -p top --open-only
python portscope.py example.com -p 80,443,8080 --no-banner --json

Options

-p, --ports      top | all | list (22,80,443) | range (1-1024)   (default: top)
-t, --timeout    per-connection timeout in seconds                (default: 1.0)
-w, --workers    concurrent connections per host                  (default: 200)
    --no-banner  skip banner grabbing
    --open-only  only show hosts with at least one open port
    --json       machine-readable output
    --no-color   disable ANSI colors

top covers the common service and web/admin ports. On a CIDR sweep each host is liveness-probed first, so dead addresses are skipped quickly.

Notes

Connect scans complete the TCP handshake, so they are reliable but visible in target logs. Banner grabbing reads the first line a service offers and, for HTTP ports, sends a HEAD / request. TLS ports are wrapped before reading.

Authorization

Scan only hosts you own or have explicit written permission to test. Port scanning third-party systems without authorization is illegal in many jurisdictions.

License

MIT

About

Concurrent TCP port scanner with service identification and banner grabbing. Stdlib only, no root.

Topics

Resources

License

Stars

0 stars

Watchers

0 watching

Forks

Releases

No releases published

Packages

 
 
 

Contributors

Languages