Skip to main content

A comprehensive Python wrapper for nmap with enhanced features

Project description

nust-nmap

PyPI version Python versions License: GPL-3.0 Downloads

🎯 Enterprise-Grade Python Nmap Wrapper
Production-ready network scanning with built-in stealth capabilities


🌟 What is nust-nmap?

A comprehensive Python wrapper for nmap that enhances the original functionality with enterprise-grade features. Designed for security professionals, penetration testers, and network administrators who need reliable, production-ready network scanning capabilities.

Key Features

  • 🎯 Complete nmap Coverage: All scan types, NSE scripts, and advanced features
  • 🛡️ Built-in Security: Stealth profiles, evasion techniques, input validation
  • ⚡ High Performance: Async scanning, intelligent caching, memory efficiency
  • 🔧 Enterprise Ready: Thread-safe, comprehensive error handling, resource management
  • 📊 Rich Output: Multiple export formats (XML, JSON, CSV) with enhanced parsing
  • 🌐 Cross-Platform: Windows, macOS, Linux with automatic nmap detection
  • 🔄 100% Compatible: Drop-in replacement for python-nmap

📦 Quick Installation

Prerequisites

  • Python 3.8+
  • Nmap 7.90+ installed on your system

Install

pip install nust-nmap

Install Nmap

# Ubuntu/Debian
sudo apt update && sudo apt install nmap

# macOS  
brew install nmap

# Windows: Download from nmap.org

🚀 Quick Start

Basic Usage

import nmap

# Create scanner instance
scanner = nmap.PortScanner()

# Basic network scan
result = scanner.scan('192.168.1.0/24', '22,80,443')

# Process results
for host in scanner.all_hosts():
    print(f"Host: {host} ({scanner[host].state()})")
    for protocol in scanner[host].all_protocols():
        ports = scanner[host][protocol].keys()
        for port in ports:
            state = scanner[host][protocol][port]['state']
            print(f"  {port}/{protocol}: {state}")

Stealth Scanning

# Built-in stealth profiles
result = scanner.scan(
    hosts='target.com',
    evasion_profile=nmap.EvasionProfile.STEALTH
)

# Quick stealth functions
result = nmap.scan_stealth('target.com', '1-1000')
result = nmap.scan_ghost('target.com', '80,443')  # Maximum stealth

Advanced Features

# Asynchronous scanning
def scan_callback(host, result):
    print(f"Completed scan for {host}")

nmap.scan_progressive('192.168.1.0/24', callback=scan_callback)

# Memory-efficient large network scanning
yield_scanner = nmap.YieldScanner()
for host, result in yield_scanner.scan('10.0.0.0/16'):
    process_host_data(host, result)

📚 Documentation

🛡️ Security & Ethics

This tool is designed for legitimate security testing and network administration. Users are responsible for:

  • Obtaining proper authorization before scanning networks
  • Complying with applicable laws and regulations
  • Using responsible disclosure for any vulnerabilities discovered

🤝 Contributing

Contributions are welcome! Please see our contributing guidelines for details.

📄 License

This project is licensed under the GPL-3.0 License - see the LICENSE file for details.

Author

Sameer Ahmed

�🙏 Acknowledgments

  • Powered by the Nmap Security Scanner - the industry standard for network discovery
  • Inspired by the network security community and best practices in vulnerability assessment
  • Thanks to the cybersecurity community for continuous feedback and improvements

🔗 Links

⚠️ Legal Disclaimer

IMPORTANT: This tool is designed for authorized security testing and network administration only.

  • Authorized Use: Own networks, approved penetration testing, security research
  • Prohibited Use: Unauthorized scanning, malicious activities, illegal reconnaissance

Users are solely responsible for compliance with applicable laws and regulations. Always obtain explicit permission before scanning networks you do not own or administer.


⚡ Ready to secure your network? Start scanning with nust-nmap today!

Project details


Download files

Download the file for your platform. If you're not sure which to choose, learn more about installing packages.

Source Distribution

nust_nmap-2.1.1.tar.gz (26.7 kB view details)

Uploaded Source

Built Distribution

If you're not sure about the file name format, learn more about wheel file names.

nust_nmap-2.1.1-py3-none-any.whl (23.7 kB view details)

Uploaded Python 3

File details

Details for the file nust_nmap-2.1.1.tar.gz.

File metadata

  • Download URL: nust_nmap-2.1.1.tar.gz
  • Upload date:
  • Size: 26.7 kB
  • Tags: Source
  • Uploaded using Trusted Publishing? Yes
  • Uploaded via: twine/6.1.0 CPython/3.12.9

File hashes

Hashes for nust_nmap-2.1.1.tar.gz
Algorithm Hash digest
SHA256 81860cdbde63a95ef05780153b7f3fa17cb425f610786059de938558acf0f93a
MD5 f9e9c8e0bca2b7ab6b3bd8d4a3384068
BLAKE2b-256 e9f3a7f985f09b8809143da4ed225e06cbc493ce5607233750d54896065a4180

See more details on using hashes here.

Provenance

The following attestation bundles were made for nust_nmap-2.1.1.tar.gz:

Publisher: publish.yml on codeNinja62/nust-nmap

Attestations: Values shown here reflect the state when the release was signed and may no longer be current.

File details

Details for the file nust_nmap-2.1.1-py3-none-any.whl.

File metadata

  • Download URL: nust_nmap-2.1.1-py3-none-any.whl
  • Upload date:
  • Size: 23.7 kB
  • Tags: Python 3
  • Uploaded using Trusted Publishing? Yes
  • Uploaded via: twine/6.1.0 CPython/3.12.9

File hashes

Hashes for nust_nmap-2.1.1-py3-none-any.whl
Algorithm Hash digest
SHA256 130823da7f0f2f7f6768662d07be77128751a2c9a94c3f04de6218fab07f7c69
MD5 9ffba73c0d4e2b055e571d9dac87812f
BLAKE2b-256 5cb794371142bddfe42b31591d75188cb2eabaa58d9c252b811e2f03c7f2a68a

See more details on using hashes here.

Provenance

The following attestation bundles were made for nust_nmap-2.1.1-py3-none-any.whl:

Publisher: publish.yml on codeNinja62/nust-nmap

Attestations: Values shown here reflect the state when the release was signed and may no longer be current.

Supported by

AWS Cloud computing and Security Sponsor Datadog Monitoring Depot Continuous Integration Fastly CDN Google Download Analytics Pingdom Monitoring Sentry Error logging StatusPage Status page