This Python tool scans a target website for:
- Open Ports - Identifies open ports using
nmap. - Vulnerabilities - Uses
nmapscripts to find vulnerabilities on open ports. - CVE Information - Integrates with the NVD API to fetch related CVEs for detected vulnerabilities.
- Port Scanning: Scans all ports (1-65535) for open connections.
- Vulnerability Scanning: Identifies vulnerabilities using
nmap's--script vuln. - CVE Lookup: Queries the NVD CVE API for detailed information on vulnerabilities.
- Python 3.7 or higher.
- Install required libraries:
pip install python-nmap requests
- Access to
nmapcommand-line tool (ensure it is installed and in the system PATH).
Clone the repository and navigate to the project directory:
git clone https://github.com/RAD50/web-port-CVE-scan.git
cd web-port-CVE-scanRun the tool with:
python web-port-CVE-scan.pyEnter the target hostname or IP when prompted.
Enter the target hostname or IP: example.com
Target IP: 93.184.216.34
Scanning open ports for 93.184.216.34...
Open ports: [80, 443]
Scanning vulnerabilities for 93.184.216.34:80...
Vulnerability on port 80:
Script: http-vuln-cve2021
Output: ...
Searching CVEs for http-vuln-cve2021 using NVD API...
Related CVEs:
CVE ID: CVE-2021-1234 | Description: Example vulnerability description.
- Ensure you have explicit permission to scan the target.
- The tool assumes
nmapis installed and functional. - NVD API usage may be subject to rate limits.
If you encounter any issues or have questions, feel free to open an issue on the GitHub repository.
Contributions are welcome! Open an issue or submit a pull request to suggest improvements or fixes.
This project is licensed under the MIT License.