Metadata-Version: 2.4
Name: vamp-api-probe
Version: 1.2
Summary: REST API security DAST scanner: BOLA, BFLA, mass assignment, rate limiting and OWASP API Top 10
Author-email: VampSecure Studios <contact@vampsecurestudios.com>
License: AGPL-3.0-only
Project-URL: Homepage, https://github.com/Vampsecure-Labs/vamp-api-probe
Project-URL: Repository, https://github.com/Vampsecure-Labs/vamp-api-probe
Keywords: security,pentest,api,rest,owasp,bola,bfla,mass-assignment,vampsecure,dast
Classifier: Development Status :: 5 - Production/Stable
Classifier: Environment :: Console
Classifier: Intended Audience :: Information Technology
Classifier: License :: OSI Approved :: GNU Affero General Public License v3 or later (AGPLv3+)
Classifier: Operating System :: OS Independent
Classifier: Programming Language :: Python :: 3
Classifier: Topic :: Security
Requires-Python: >=3.9
Description-Content-Type: text/markdown
Requires-Dist: rich>=13.7.0
Requires-Dist: aiohttp>=3.8.0
Requires-Dist: pyyaml>=6.0

<!-- © VampSecure Studios — VampSecure Labs Security Research Division -->
<h1 align="center">vamp-api-probe</h1>

<p align="center">
  <img src="https://img.shields.io/badge/python-3.9%2B-blue?logo=python&logoColor=white" alt="Python 3.9+"/>
  <img src="https://img.shields.io/badge/platform-linux%20%7C%20macOS%20%7C%20windows-lightgrey" alt="Platform"/>
  <img src="https://img.shields.io/badge/license-AGPL--3.0-green" alt="License AGPL-3.0"/>
  <img src="https://img.shields.io/badge/VampSecure-Labs-magenta" alt="VampSecure Labs"/>
  <img src="https://github.com/Vampsecure-Labs/vamp-api-probe/actions/workflows/ci.yml/badge.svg" alt="CI"/>
</p>

> 🇬🇧 [English](#english) · 🇪🇸 [Español](#español)

---

<a name="english"></a>
## 🇬🇧 English

`vamp-api-probe` is a DAST (Dynamic Application Security Testing) scanner for modern REST APIs, aligned with the OWASP API Security Top 10 2023. It probes live API endpoints for broken object-level authorization (BOLA), broken function-level authorization (BFLA), mass assignment vulnerabilities, absent rate limiting, authentication weaknesses, exposed administrative endpoints, security header misconfigurations, and legacy version exposure. It can operate against a bare base URL with automatic endpoint discovery or drive its test suite from an OpenAPI/Swagger specification for complete endpoint coverage.

## Features

- **API1 — BOLA** (Broken Object Level Authorization): enumerates numeric path parameters (±1, ±10, ±100, and common IDs), compares authenticated vs unauthenticated responses to detect cross-user data leakage (CRITICAL/HIGH)
- **API2 — BFLA** (Broken Function Level Authorization): probes every endpoint without Authorization header and tests privileged HTTP methods (DELETE, PUT, PATCH) for missing access control (CRITICAL/HIGH)
- **API3 — Mass Assignment**: injects admin-escalation fields (`isAdmin`, `role`, `is_superuser`, `verified`, `balance`, `credits`) in POST/PUT/PATCH bodies and checks whether the API accepts them (CRITICAL)
- **API4 — Rate Limiting**: fires a configurable burst of requests against the same endpoint and flags absence of HTTP 429 responses (HIGH)
- **API5 — Broken Authentication**: tests manipulated JWT tokens (single-character mutation) and expired JWT detection to identify missing token validation (CRITICAL)
- **API6 — Sensitive Business Flows**: detects administrative and debug endpoints (`/admin`, `/internal`, `/debug`, `/actuator`, `/metrics`, `/env`, `/_debug`) accessible without authentication (HIGH)
- **API8 — Security Misconfiguration**: audits response headers (`X-Content-Type-Options`, `X-Frame-Options`, `Strict-Transport-Security`, `Content-Security-Policy`) and checks for stack trace exposure via malformed input (MEDIUM)
- **API9 — Improper Inventory Management**: probes legacy API versions (e.g. `/v1/` when target is `/v2/`) for unretired endpoints (MEDIUM)
- OpenAPI/Swagger spec ingestion (YAML or JSON) for automatic endpoint and schema discovery
- Fallback endpoint discovery against common REST paths when no spec is provided
- Bearer token support for authenticated test passes
- Configurable per-request timeout and rate-limit burst size
- Export to Console (Rich), JSON, and HTML (dark-theme)
- VSL unified client report (HTML + optional PDF via fpdf2)

## Requirements

- Python 3.9 or later
- `rich >= 13.7.0`
- `aiohttp >= 3.8.0`
- `pyyaml >= 6.0`
- Optional: `fpdf2 >= 2.7` for `--report-pdf`

## Installation

```bash
pip install vamp-api-probe
# or with Homebrew:
brew install vampsecure-labs/labs/vamp-api-probe
```

```bash
git clone https://github.com/Vampsecure-Labs/vamp-api-probe.git
cd vamp-api-probe
python3 -m venv .venv
source .venv/bin/activate   # Windows: .venv\Scripts\activate
pip install -r requirements.txt
```

## Usage

```
vamp-api-probe scan --help
```

```
usage: vamp-api-probe scan --url URL
                            [--spec OPENAPI_FILE]
                            [--token BEARER_TOKEN]
                            [--no-auth-tests]
                            [--timeout SECONDS]
                            [--rate-limit-burst N]
                            [--json FILE] [--html FILE]
                            [--client CLIENT] [--engagement ENGAGEMENT]
                            [--auditor AUDITOR] [--report-scope SCOPE]
                            [--report-html FILE] [--report-pdf FILE]

vamp-api-probe — REST API DAST Scanner (VampSecure Labs)
```

## Examples

```bash
# Scan a public API with automatic endpoint discovery
vamp-api-probe scan --url https://api.example.com/v1

# Scan with an OpenAPI spec for full endpoint coverage
vamp-api-probe scan --url https://api.example.com/v1 --spec openapi.yaml

# Authenticated scan with a Bearer token
vamp-api-probe scan --url https://api.example.com/v1 --token eyJhbGciOiJIUzI1NiJ9...

# Skip tests that require a second user account
vamp-api-probe scan --url https://api.example.com/v1 --no-auth-tests

# Custom timeout and rate-limit burst
vamp-api-probe scan --url https://api.example.com/v1 --timeout 15 --rate-limit-burst 30

# Export findings to JSON and dark-theme HTML
vamp-api-probe scan --url https://api.example.com/v1 --json results.json --html report.html

# Generate client-ready engagement report (HTML + PDF)
vamp-api-probe scan --url https://api.example.com/v1 \
    --client "Acme Corp" --engagement "API Security Assessment Q4 2026" \
    --auditor "J. Smith" --report-html client_report.html --report-pdf client_report.pdf
```

## CLI Reference

| Flag | Default | Description |
|------|---------|-------------|
| `--url URL` | (required) | Base URL of the API under test |
| `--spec FILE` | — | OpenAPI/Swagger YAML or JSON spec for endpoint discovery |
| `--token TOKEN` | — | Bearer token for authenticated requests |
| `--no-auth-tests` | off | Skip tests that require a second-user context |
| `--timeout N` | 10 | Per-request timeout in seconds |
| `--rate-limit-burst N` | 20 | Number of rapid requests for rate-limit test |
| `--json FILE` | — | Export results to JSON |
| `--html FILE` | — | Export dark-theme HTML report |
| `--client TEXT` | — | Client name for VSL engagement report |
| `--engagement TEXT` | — | Engagement title for VSL engagement report |
| `--auditor TEXT` | — | Auditor name for VSL engagement report |
| `--report-scope TEXT` | — | Scope description for VSL engagement report |
| `--report-html FILE` | — | Export unified VSL client report (HTML) |
| `--report-pdf FILE` | — | Export unified VSL client report (PDF, requires fpdf2) |

## Output Formats

| Format | Flag | Description |
|--------|------|-------------|
| Console | (default) | Rich progress and findings table with OWASP API Top 10 mapping |
| JSON | `--json FILE` | Machine-readable full result set |
| HTML | `--html FILE` | Dark-theme standalone report |
| Client HTML | `--report-html FILE` | Unified VampSecure Labs engagement report |
| Client PDF | `--report-pdf FILE` | PDF version of the VSL client report |

## OWASP API Top 10 Coverage

| ID | Category | Severity |
|----|----------|----------|
| API1:2023 | Broken Object Level Authorization (BOLA) | CRITICAL / HIGH |
| API2:2023 | Broken Function Level Authorization (BFLA) | CRITICAL / HIGH |
| API3:2023 | Broken Object Property Level Authorization / Mass Assignment | CRITICAL |
| API4:2023 | Unrestricted Resource Consumption (Rate Limiting) | HIGH |
| API5:2023 | Broken Function Level Authorization / Broken Authentication | CRITICAL |
| API6:2023 | Unrestricted Access to Sensitive Business Flows | HIGH |
| API8:2023 | Security Misconfiguration | MEDIUM |
| API9:2023 | Improper Inventory Management | MEDIUM |

## Exit Codes

| Code | Meaning | CI/CD Behavior |
|------|---------|----------------|
| `0` | No critical or high findings | Pipeline passes |
| `1` | CRITICAL or HIGH findings detected | Pipeline fails — review required |
| `2` | Connection or configuration error | Pipeline fails — check target |

## Sample Output

```
$ vamp-api-probe scan --url https://api.example.org/v2 --spec openapi.yaml \
    --token eyJhbGciOiJIUzI1NiJ9.example.sig

  vamp-api-probe v1.2 — REST API DAST Scanner
  VampSecure Labs Security Research Division

  Target: https://api.example.org/v2
  Spec:   openapi.yaml  (14 endpoints discovered)

  [API1] BOLA — Broken Object Level Authorization
  Probing /users/{id}, /orders/{id}, /invoices/{id} ...
  ✗ API-001 CRITICAL — GET /users/1338 returned 200 as user #1337 (cross-user object access)
  ✗ API-001 HIGH     — GET /orders/999 returned 200 without Authorization header

  [API2] BFLA — Broken Function Level Authorization
  ✓ DELETE /users/{id}: 403 Forbidden (correct)
  ✗ API-002 CRITICAL — DELETE /admin/users/42 returned 200 without Authorization header

  [API3] Mass Assignment
  Injecting {isAdmin: true, role: "admin", balance: 999999} into POST /users ...
  ✗ API-003 CRITICAL — POST /users accepted 'isAdmin' field reflected in response body

  [API4] Rate Limiting
  Firing 20 requests to POST /auth/login ...
  ✓ HTTP 429 received after 5 requests (rate limiting active)

  [API5] Broken Authentication
  Testing JWT manipulation on Authorization header ...
  ✗ API-005 CRITICAL — mutated JWT token accepted (missing signature validation)

  [API8] Security Misconfiguration
  Strict-Transport-Security: present ✓
  Content-Security-Policy: absent  ✗ API-008 MEDIUM

  ╭────────────────────── Summary ──────────────────────╮
  │  Endpoints tested: 14   Findings: 6                │
  │  CRITICAL: 4   HIGH: 1   MEDIUM: 1   Duration: 9s  │
  ╰─────────────────────────────────────────────────────╯

  Exit code: 1  (CRITICAL/HIGH findings detected)
```

## Why vamp-api-probe vs 42Crunch · OWASP ZAP · Burp Suite

| Feature | vamp-api-probe | 42Crunch | OWASP ZAP | Burp Suite |
|---------|---------------|----------|-----------|------------|
| OWASP API Top 10 2023 first-class | ✅ | ✅ (spec audit) | ⚠️ partial | ⚠️ partial |
| Runtime DAST (hits live endpoints) | ✅ | ❌ (static linting) | ✅ | ✅ |
| No JVM / Electron dependency | ✅ | ✅ (SaaS) | ❌ (Java) | ❌ (Java) |
| CLI-native, CI/CD ready | ✅ | ⚠️ (SaaS API only) | ⚠️ (headless mode) | ⚠️ (headless mode) |
| OpenAPI spec-driven + auto-discovery | ✅ | ✅ | ⚠️ partial | ⚠️ partial |
| BOLA cross-user object detection | ✅ | ❌ | ⚠️ | ⚠️ |
| Mass assignment injection testing | ✅ | ❌ | ⚠️ | ⚠️ |
| JWT single-character mutation test | ✅ | ⚠️ partial | ⚠️ | ✅ |
| License | AGPL-3.0 | commercial | Apache 2.0 | commercial |

**Key differentiators:**

- **Runtime testing, not spec linting**: 42Crunch audits the OpenAPI spec without hitting the live API. vamp-api-probe probes running endpoints for BOLA, BFLA, and mass assignment in actual traffic — catching logic flaws invisible to static analysis.
- **Async Python, zero JVM**: a single `pip install vamp-api-probe` vs managing a Java runtime or a Burp/ZAP GUI installation inside a CI container image.
- **OWASP API Top 10 2023 first-class**: every finding maps to the 2023 edition (not the older generic OWASP Top 10), keeping results relevant for microservice and mobile-backend architectures.
- **Dual-mode discovery**: spec-driven with `--spec` for full endpoint coverage from an OpenAPI file, or automatic path bruteforce against common REST paths when no spec is available.

## Check Coverage

| Check ID | Description | Standard | Severity |
|----------|-------------|----------|----------|
| API-001 | Cross-user object access via IDOR on numeric path parameter | OWASP API1:2023 BOLA | CRITICAL |
| API-002 | Unauthenticated request to protected object endpoint returns 200 | OWASP API1:2023 BOLA | HIGH |
| API-003 | Privileged HTTP method (DELETE/PUT) accessible without Authorization header | OWASP API2:2023 BFLA | CRITICAL |
| API-004 | Admin or internal endpoint (`/admin`, `/internal`, `/actuator`) reachable without auth | OWASP API2:2023 BFLA | HIGH |
| API-005 | Mass assignment: admin escalation field accepted and reflected in response | OWASP API3:2023 Mass Assignment | CRITICAL |
| API-006 | No HTTP 429 returned after configurable burst of requests to sensitive endpoint | OWASP API4:2023 Unrestricted Resource Consumption | HIGH |
| API-007 | Mutated or expired JWT token accepted by the API (missing signature validation) | OWASP API5:2023 Broken Authentication | CRITICAL |
| API-008 | Debug endpoint (`/debug`, `/env`, `/metrics`, `/_debug`) accessible without auth | OWASP API6:2023 Sensitive Business Flows | HIGH |
| API-009 | Missing HTTP security header (`Content-Security-Policy`, `X-Frame-Options`, `HSTS`) | OWASP API8:2023 Security Misconfiguration | MEDIUM |
| API-010 | Stack trace or internal path exposed via malformed request body | OWASP API8:2023 Security Misconfiguration | MEDIUM |
| API-011 | Legacy API version endpoint still active (e.g. `/v1/` when target is `/v2/`) | OWASP API9:2023 Improper Inventory Management | MEDIUM |

## Legal Notice

Use exclusively on systems you own or for which you hold explicit written authorization from the system owner. VampSecure Studios assumes no liability for unauthorized use.

## Part of VampSecure Labs Toolkit

`vamp-api-probe` is one tool in the VampSecure Labs security research toolkit. For the full toolkit including the orchestrator that runs all tools in sequence and aggregates findings into a single engagement report, see:

- Portfolio: [github.com/Vampsecure-Labs](https://github.com/Vampsecure-Labs)
- Orchestrator: [github.com/Vampsecure-Labs/vamp-orchestrator](https://github.com/Vampsecure-Labs/vamp-orchestrator)

## Version History

| Version | Main changes |
|---------|-------------|
| v1.1 | Bilingual README (EN/ES) |
| v1.0 | Initial release: OWASP API Top 10 2023 DAST scanner (BOLA, BFLA, mass assignment, rate limiting, JWT, admin endpoints, security headers, legacy versions) |

---

© VampSecure Studios — VampSecure Labs Security Research Division

---

<a name="español"></a>
## 🇪🇸 Español

`vamp-api-probe` es un escáner DAST (Dynamic Application Security Testing) para APIs REST modernas, alineado con el OWASP API Security Top 10 2023. Sondea endpoints de API en vivo para detectar autorización rota a nivel de objeto (BOLA), autorización rota a nivel de función (BFLA), vulnerabilidades de mass assignment, ausencia de rate limiting, debilidades de autenticación, endpoints administrativos expuestos, misconfiguraciones de cabeceras de seguridad y exposición de versiones legacy. Puede operar contra una URL base con descubrimiento automático de endpoints o ejecutar su suite de pruebas a partir de una especificación OpenAPI/Swagger para cobertura completa de endpoints.

## Características

- **API1 — BOLA** (Autorización rota a nivel de objeto): enumera parámetros numéricos de ruta (±1, ±10, ±100 e IDs comunes), compara respuestas autenticadas vs no autenticadas para detectar filtración de datos entre usuarios (CRITICAL/HIGH)
- **API2 — BFLA** (Autorización rota a nivel de función): sondea cada endpoint sin cabecera Authorization y prueba métodos HTTP privilegiados (DELETE, PUT, PATCH) para detectar ausencia de control de acceso (CRITICAL/HIGH)
- **API3 — Mass Assignment**: inyecta campos de escalada de privilegios (`isAdmin`, `role`, `is_superuser`, `verified`, `balance`, `credits`) en cuerpos POST/PUT/PATCH y comprueba si la API los acepta (CRITICAL)
- **API4 — Rate Limiting**: envía una ráfaga configurable de peticiones contra el mismo endpoint y detecta la ausencia de respuestas HTTP 429 (HIGH)
- **API5 — Autenticación rota**: prueba tokens JWT manipulados (mutación de un solo carácter) y detección de JWT expirados para identificar validación de token ausente (CRITICAL)
- **API6 — Flujos de negocio sensibles**: detecta endpoints administrativos y de depuración (`/admin`, `/internal`, `/debug`, `/actuator`, `/metrics`, `/env`, `/_debug`) accesibles sin autenticación (HIGH)
- **API8 — Mala configuración de seguridad**: audita cabeceras de respuesta (`X-Content-Type-Options`, `X-Frame-Options`, `Strict-Transport-Security`, `Content-Security-Policy`) y comprueba la exposición de stack traces mediante entrada malformada (MEDIUM)
- **API9 — Gestión inadecuada del inventario**: sondea versiones legacy de la API (ej. `/v1/` cuando el objetivo es `/v2/`) en busca de endpoints no retirados (MEDIUM)
- Ingesta de especificaciones OpenAPI/Swagger (YAML o JSON) para descubrimiento automático de endpoints y esquemas
- Descubrimiento de endpoints por fallback contra rutas REST comunes cuando no se proporciona especificación
- Soporte de token Bearer para pasadas de prueba autenticadas
- Timeout por petición y tamaño de ráfaga para rate limiting configurables
- Exportación a Consola (Rich), JSON y HTML (dark-theme)
- Informe unificado VSL para el cliente (HTML + PDF opcional vía fpdf2)

## Requisitos

- Python 3.9 o superior
- `rich >= 13.7.0`
- `aiohttp >= 3.8.0`
- `pyyaml >= 6.0`
- Opcional: `fpdf2 >= 2.7` para `--report-pdf`

## Instalación

```bash
pip install vamp-api-probe
# o con Homebrew:
brew install vampsecure-labs/labs/vamp-api-probe
```

```bash
git clone https://github.com/Vampsecure-Labs/vamp-api-probe.git
cd vamp-api-probe
python3 -m venv .venv
source .venv/bin/activate   # Windows: .venv\Scripts\activate
pip install -r requirements.txt
```

## Uso

```
vamp-api-probe scan --help
```

```
usage: vamp-api-probe scan --url URL
                            [--spec FICHERO_OPENAPI]
                            [--token TOKEN_BEARER]
                            [--no-auth-tests]
                            [--timeout SEGUNDOS]
                            [--rate-limit-burst N]
                            [--json FILE] [--html FILE]
                            [--client CLIENTE] [--engagement ENGAGEMENT]
                            [--auditor AUDITOR] [--report-scope SCOPE]
                            [--report-html FILE] [--report-pdf FILE]

vamp-api-probe — Escáner DAST para APIs REST (VampSecure Labs)
```

## Ejemplos

```bash
# Escanear una API pública con descubrimiento automático de endpoints
vamp-api-probe scan --url https://api.example.com/v1

# Escanear con una especificación OpenAPI para cobertura completa de endpoints
vamp-api-probe scan --url https://api.example.com/v1 --spec openapi.yaml

# Escaneo autenticado con un token Bearer
vamp-api-probe scan --url https://api.example.com/v1 --token eyJhbGciOiJIUzI1NiJ9...

# Omitir pruebas que requieren un segundo contexto de usuario
vamp-api-probe scan --url https://api.example.com/v1 --no-auth-tests

# Timeout y ráfaga de rate limiting personalizados
vamp-api-probe scan --url https://api.example.com/v1 --timeout 15 --rate-limit-burst 30

# Exportar hallazgos a JSON e HTML dark-theme
vamp-api-probe scan --url https://api.example.com/v1 --json results.json --html report.html

# Generar informe de compromiso listo para el cliente (HTML + PDF)
vamp-api-probe scan --url https://api.example.com/v1 \
    --client "Acme Corp" --engagement "Evaluación de Seguridad API Q4 2026" \
    --auditor "J. Smith" --report-html informe_cliente.html --report-pdf informe_cliente.pdf
```

## Referencia de CLI

| Flag | Por defecto | Descripción |
|------|-------------|-------------|
| `--url URL` | (obligatorio) | URL base de la API bajo prueba |
| `--spec FILE` | — | Especificación OpenAPI/Swagger YAML o JSON para descubrimiento de endpoints |
| `--token TOKEN` | — | Token Bearer para peticiones autenticadas |
| `--no-auth-tests` | off | Omitir pruebas que requieren contexto de segundo usuario |
| `--timeout N` | 10 | Timeout por petición en segundos |
| `--rate-limit-burst N` | 20 | Número de peticiones rápidas para la prueba de rate limiting |
| `--json FILE` | — | Exportar resultados a JSON |
| `--html FILE` | — | Exportar informe HTML dark-theme |
| `--client TEXT` | — | Nombre del cliente para el informe de compromiso VSL |
| `--engagement TEXT` | — | Título del compromiso para el informe VSL |
| `--auditor TEXT` | — | Nombre del auditor para el informe VSL |
| `--report-scope TEXT` | — | Descripción del alcance para el informe VSL |
| `--report-html FILE` | — | Exportar informe unificado VSL para el cliente (HTML) |
| `--report-pdf FILE` | — | Exportar informe unificado VSL para el cliente (PDF, requiere fpdf2) |

## Formatos de salida

| Formato | Flag | Descripción |
|---------|------|-------------|
| Consola | (por defecto) | Progreso Rich y tabla de hallazgos con mapeo OWASP API Top 10 |
| JSON | `--json FILE` | Conjunto completo de resultados legible por máquina |
| HTML | `--html FILE` | Informe dark-theme independiente |
| HTML cliente | `--report-html FILE` | Informe unificado VampSecure Labs para el compromiso |
| PDF cliente | `--report-pdf FILE` | Versión PDF del informe VSL para el cliente |

## Cobertura OWASP API Top 10

| ID | Categoría | Severidad |
|----|-----------|-----------|
| API1:2023 | Autorización rota a nivel de objeto (BOLA) | CRITICAL / HIGH |
| API2:2023 | Autorización rota a nivel de función (BFLA) | CRITICAL / HIGH |
| API3:2023 | Autorización rota a nivel de propiedad de objeto / Mass Assignment | CRITICAL |
| API4:2023 | Consumo ilimitado de recursos (Rate Limiting) | HIGH |
| API5:2023 | Autorización rota a nivel de función / Autenticación rota | CRITICAL |
| API6:2023 | Acceso sin restricciones a flujos de negocio sensibles | HIGH |
| API8:2023 | Mala configuración de seguridad | MEDIUM |
| API9:2023 | Gestión inadecuada del inventario | MEDIUM |

## Códigos de salida

| Código | Significado | Comportamiento CI/CD |
|--------|-------------|----------------------|
| `0` | Sin hallazgos críticos o altos | El pipeline pasa |
| `1` | Hallazgos CRITICAL o HIGH detectados | El pipeline falla — revisión requerida |
| `2` | Error de conexión o configuración | El pipeline falla — verificar objetivo |

## Ejemplo de salida

```
$ vamp-api-probe scan --url https://api.example.org/v2 --spec openapi.yaml \
    --token eyJhbGciOiJIUzI1NiJ9.example.sig

  vamp-api-probe v1.2 — Escáner DAST para APIs REST
  VampSecure Labs Security Research Division

  Objetivo: https://api.example.org/v2
  Spec:     openapi.yaml  (14 endpoints descubiertos)

  [API1] BOLA — Autorización rota a nivel de objeto
  Sondeando /users/{id}, /orders/{id}, /invoices/{id} ...
  ✗ API-001 CRITICAL — GET /users/1338 devolvió 200 como usuario #1337 (acceso entre usuarios)
  ✗ API-001 HIGH     — GET /orders/999 devolvió 200 sin cabecera Authorization

  [API2] BFLA — Autorización rota a nivel de función
  ✓ DELETE /users/{id}: 403 Forbidden (correcto)
  ✗ API-002 CRITICAL — DELETE /admin/users/42 devolvió 200 sin cabecera Authorization

  [API3] Mass Assignment
  Inyectando {isAdmin: true, role: "admin", balance: 999999} en POST /users ...
  ✗ API-003 CRITICAL — POST /users aceptó el campo 'isAdmin' reflejado en el cuerpo de la respuesta

  [API4] Rate Limiting
  Enviando 20 peticiones a POST /auth/login ...
  ✓ HTTP 429 recibido tras 5 peticiones (rate limiting activo)

  [API5] Autenticación rota
  Probando manipulación JWT en cabecera Authorization ...
  ✗ API-005 CRITICAL — token JWT mutado aceptado (validación de firma ausente)

  [API8] Mala configuración de seguridad
  Strict-Transport-Security: presente ✓
  Content-Security-Policy: ausente  ✗ API-008 MEDIUM

  ╭────────────────────── Resumen ──────────────────────╮
  │  Endpoints probados: 14   Hallazgos: 6              │
  │  CRITICAL: 4   HIGH: 1   MEDIUM: 1   Duración: 9s  │
  ╰─────────────────────────────────────────────────────╯

  Código de salida: 1  (hallazgos CRITICAL/HIGH detectados)
```

## Por qué vamp-api-probe vs 42Crunch · OWASP ZAP · Burp Suite

| Característica | vamp-api-probe | 42Crunch | OWASP ZAP | Burp Suite |
|----------------|---------------|----------|-----------|------------|
| OWASP API Top 10 2023 de primera clase | ✅ | ✅ (auditoría spec) | ⚠️ parcial | ⚠️ parcial |
| DAST en tiempo real (golpea endpoints en vivo) | ✅ | ❌ (linting estático) | ✅ | ✅ |
| Sin dependencia JVM / Electron | ✅ | ✅ (SaaS) | ❌ (Java) | ❌ (Java) |
| Nativo CLI, listo para CI/CD | ✅ | ⚠️ (solo API SaaS) | ⚠️ (modo headless) | ⚠️ (modo headless) |
| Spec OpenAPI + autodescubrimiento | ✅ | ✅ | ⚠️ parcial | ⚠️ parcial |
| Detección BOLA entre usuarios | ✅ | ❌ | ⚠️ | ⚠️ |
| Pruebas de inyección mass assignment | ✅ | ❌ | ⚠️ | ⚠️ |
| Test de mutación JWT de un carácter | ✅ | ⚠️ parcial | ⚠️ | ✅ |
| Licencia | AGPL-3.0 | comercial | Apache 2.0 | comercial |

**Diferenciadores clave:**

- **Pruebas en tiempo real, no linting de spec**: 42Crunch audita la especificación OpenAPI sin atacar la API en vivo. vamp-api-probe sondea endpoints en ejecución para BOLA, BFLA y mass assignment en tráfico real — detectando fallos lógicos invisibles para el análisis estático.
- **Python asíncrono, sin JVM**: un único `pip install vamp-api-probe` frente a gestionar un runtime Java o una instalación de Burp/ZAP GUI dentro de una imagen de contenedor CI.
- **OWASP API Top 10 2023 de primera clase**: cada hallazgo mapea a la edición 2023 (no al OWASP Top 10 genérico antiguo), manteniendo los resultados relevantes para arquitecturas de microservicios y backends móviles.
- **Descubrimiento dual**: impulsado por spec con `--spec` para cobertura completa de endpoints desde un fichero OpenAPI, o fuerza bruta automática de rutas contra rutas REST comunes cuando no hay spec disponible.

## Cobertura de checks

| Check ID | Descripción | Estándar | Severidad |
|----------|-------------|----------|-----------|
| API-001 | Acceso a objetos de otro usuario vía IDOR en parámetro numérico de ruta | OWASP API1:2023 BOLA | CRITICAL |
| API-002 | Petición no autenticada a endpoint de objeto protegido devuelve 200 | OWASP API1:2023 BOLA | HIGH |
| API-003 | Método HTTP privilegiado (DELETE/PUT) accesible sin cabecera Authorization | OWASP API2:2023 BFLA | CRITICAL |
| API-004 | Endpoint admin o interno (`/admin`, `/internal`, `/actuator`) accesible sin auth | OWASP API2:2023 BFLA | HIGH |
| API-005 | Mass assignment: campo de escalada admin aceptado y reflejado en la respuesta | OWASP API3:2023 Mass Assignment | CRITICAL |
| API-006 | Sin HTTP 429 tras ráfaga configurable de peticiones a endpoint sensible | OWASP API4:2023 Consumo ilimitado de recursos | HIGH |
| API-007 | Token JWT mutado o expirado aceptado por la API (validación de firma ausente) | OWASP API5:2023 Autenticación rota | CRITICAL |
| API-008 | Endpoint de depuración (`/debug`, `/env`, `/metrics`, `/_debug`) accesible sin auth | OWASP API6:2023 Flujos de negocio sensibles | HIGH |
| API-009 | Cabecera HTTP de seguridad ausente (`Content-Security-Policy`, `X-Frame-Options`, `HSTS`) | OWASP API8:2023 Mala configuración de seguridad | MEDIUM |
| API-010 | Stack trace o ruta interna expuesta mediante cuerpo de petición malformado | OWASP API8:2023 Mala configuración de seguridad | MEDIUM |
| API-011 | Endpoint de versión legacy de API aún activo (ej. `/v1/` cuando el objetivo es `/v2/`) | OWASP API9:2023 Gestión inadecuada del inventario | MEDIUM |

## Aviso legal

Uso exclusivo en sistemas propios o para los que se disponga de autorización escrita expresa del propietario del sistema. VampSecure Studios no asume responsabilidad alguna por usos no autorizados.

## Parte del Toolkit VampSecure Labs

`vamp-api-probe` es una herramienta del toolkit de investigación de seguridad VampSecure Labs. Para el toolkit completo, incluyendo el orquestador que ejecuta todas las herramientas en secuencia y agrega los hallazgos en un único informe de compromiso, ver:

- Portfolio: [github.com/Vampsecure-Labs](https://github.com/Vampsecure-Labs)
- Orquestador: [github.com/Vampsecure-Labs/vamp-orchestrator](https://github.com/Vampsecure-Labs/vamp-orchestrator)

## Historial de versiones

| Versión | Cambios principales |
|---------|---------------------|
| v1.1 | README bilingüe (EN/ES) |
| v1.0 | Primera versión: escáner DAST OWASP API Top 10 2023 (BOLA, BFLA, mass assignment, rate limiting, JWT, endpoints admin, cabeceras de seguridad, versiones legacy) |

---

© VampSecure Studios — VampSecure Labs Security Research Division
