Skip to content

X30G/Python-Reconnaissance-Scanner

Folders and files

NameName
Last commit message
Last commit date

Latest commit

 

History

9 Commits
 
 
 
 
 
 

Repository files navigation

Python Reconnaissance Scanner


Smart Recon & Scanning

Platforms: Kali Linux Category: Pentesting License: MIT Made with Python & Nmap Warning


📌 Purpose

This script automates the reconnaissance and scanning phase of a penetration test by combining Nmap, socket-based banner grabbing, and web service analysis. It intelligently parses scan results to focus on actual open services, making your recon more accurate and efficient.


📖 Description

The Smart Recon & Scanning Tool:

  • Runs a full-port Nmap scan with service/version detection.
  • Parses the Nmap XML output to find actual open services.
  • Uses socket to grab banners from non-web services.
  • Uses Requests + BeautifulSoup to analyze discovered web pages for titles and metadata.
  • Supports verbose mode for detailed feedback or quiet mode for clean output.
  • Saves results in both TXT and XML formats for later review or reporting.

🚀 Features

  • Smart Targeting – Only analyzes services that Nmap finds open.
  • Web Recon – Automatically identifies and inspects HTTP/HTTPS services.
  • Banner Grabbing – Quickly identifies non-web services via socket.
  • Cross-Platform – Runs on Linux, macOS, and Windows (with Python 3 + Nmap installed).
  • Output Files – Saves detailed scan results in nmap_scan_<timestamp>.txt and .xml.
  • Verbose/Quiet Modes – Toggle detailed output as needed.

🛠 Requirements

  • Python 3.7+
  • Nmap installed and accessible in PATH
  • Python modules:
  pip install requests beautifulsoup4

💡 Example Usage

python3 python_recon.py <target>
python3 python_recon.py 192.168.x.x

Run in quiet mode:
python3 python_recon.py <target> --quiet

📜 Example Output (Verbose Mode)

============================================================
   Smart Recon & Scanning Tool
============================================================
[+] Running Nmap scan on 192.168.x.x...
[+] Scan complete! XML: nmap_scan_20250809_143000.xml, TXT: nmap_scan_20250809_143000.txt
[+] 192.168.x.x - http (Apache httpd 2.4.51)
    [Web] Fetching: http://192.168.x.x:80
    [Web] Title: Example_Domain.com
    [Web] Meta: description = This is an example website.
[+] 192.168.x.x:22 - ssh (OpenSSH 8.2)
    [Banner] SSH-2.0-OpenSSH_8.2p1 Ubuntu-4ubuntu0.3
[+] Detailed scan saved to: nmap_scan_20250809_143000.txt

⚠️ Disclaimer

This tool is intended solely for educational purposes and authorized penetration testing. You are responsible for ensuring you have explicit permission from the system owner before running this script against any target. Unauthorized use of this tool against networks, systems, or applications without prior consent may be illegal and could result in criminal charges. The author assumes no liability for any misuse or damage caused by this software.

About

Python recon and scanning using nmap

Topics

Resources

License

Stars

Watchers

Forks

Releases

No releases published

Packages

 
 
 

Contributors

Languages