Mohamed Gaber's Portfolio

PyScout: A Basic Web Vulnerability Scanner

PyScout is a command-line interface (CLI) tool developed in Python, designed to perform fundamental web vulnerability checks. This project demonstrates my understanding of common web security flaws and how to programmatically identify them.

Features:

How to Run PyScout:

PyScout is a Python script that runs directly from your terminal.

  1. **Navigate to Project Directory:**
    cd D:\Coding\my-portfolio\projects\pyscout
  2. **Install Dependencies:** Ensure you have the `requests` library installed:
    pip install requests
  3. **Execute the Scan:** Run the script with the target URL using the `-u` or `--url` argument:
    python pyscout.py -u http://example.com/

    Note: Always ensure you have explicit permission to scan any website. For testing purposes, you can use intentionally vulnerable sites like http://testphp.vulnweb.com/.

Sample Output:

Here's an example of PyScout detecting missing security headers:

PyScout Terminal Output

============================================================
[*]  Initiating PyScout Basic Scan for: http://testphp.vulnweb.com/
[*] Checking for Reflected XSS on: http://testphp.vulnweb.com/
[*] Checking for Error-Based SQL Injection on: http://testphp.vulnweb.com/
[*] Checking for essential Security Headers on: http://testphp.vulnweb.com/
[!]    [Missing Headers] Found missing security headers for http://testphp.vulnweb.com/:
[!]        - X-Frame-Options (Purpose: Prevents Clickjacking (should be DENY or SAMEORIGIN))
[!]        - X-Content-Type-Options (Purpose: Prevents MIME-sniffing (should be nosniff))
[!]        - Strict-Transport-Security (Purpose: HSTS - Enforces HTTPS (should be present for HTTPS sites))
[!]        - Content-Security-Policy (Purpose: CSP - Mitigates XSS and data injection (can be complex))
[!]        - Referrer-Policy (Purpose: Controls referrer information (e.g., no-referrer, same-origin))

============================================================
[*] Scan Summary:
[!]    PyScout detected 1 potential vulnerabilities:
[!]      - Missing/Incomplete Security Headers
============================================================
            
View PyScout on GitHub Back to Projects