How jstreampro/php_surface_audit works
PHP Surface Audit is a bounded, evidence-driven PHP exposure scanner for approved IPs, DNS names, and URLs. Its principal workflow normalizes targets and scope, resolves and probes them over HTTP(S), discovers in-scope routes and host identities, compares responses for PHP indicators, then classifies evidence and emits review reports. The README also documents configurable concurrency and request budgets, optional enhanced DNS, and CVE-version review. The implementation is a single large module; the excerpts show key stages but not every internal call, so uncertain wiring is omitted.
Main entry points: php_surface_audit.py Target auditor
Components 20
Scan orchestration
- CLI and config
php_surface_audit.py - Target auditor
php_surface_audit.py - Target parsing
php_surface_audit.py - Scope policy
php_surface_audit.py
Network and discovery
- DNS resolver
php_surface_audit.py - Rate limiter
php_surface_audit.py - HTTP probes
php_surface_audit.py - Redirect handling
php_surface_audit.py - Page discovery
php_surface_audit.py - Host candidates
php_surface_audit.py - Route controls
php_surface_audit.py
Evidence analysis
- Evidence detection
php_surface_audit.py - Finding classification
php_surface_audit.py - Version review
php_surface_audit.py - Coverage notes
php_surface_audit.py
Review outputs
- Observation evidence
php_surface_audit.py - HTML CSV JSON
php_surface_audit.py
Other components
- Authorized operator
- Target web service
- dnspython
Connections 20
- Authorized operator → CLI and config: supplies targets
README.md - CLI and config → Target parsing: parses inputs
php_surface_audit.py - CLI and config → Target auditor: starts scan
php_surface_audit.py - Target auditor → Scope policy: checks scope
php_surface_audit.py - Target auditor → DNS resolver: resolves names
php_surface_audit.py - Target auditor → HTTP probes: requests pages
php_surface_audit.py - Target auditor → Rate limiter: limits requests
php_surface_audit.py - HTTP probes → Target web service: sends GET
README.md - Target auditor → Redirect handling: follows redirects
php_surface_audit.py - Target auditor → Page discovery: queues links
php_surface_audit.py - Page discovery → Scope policy: filters links
php_surface_audit.py - Target auditor → Host candidates: records candidates
php_surface_audit.py - Target auditor → Route controls: compares routes
php_surface_audit.py - Target auditor → Evidence detection: observes responses
php_surface_audit.py - Evidence detection → Finding classification: supports findings
php_surface_audit.py - Finding classification → Version review: assesses reports
php_surface_audit.py - Target auditor → Coverage notes: records gaps
php_surface_audit.py - Target auditor → Observation evidence: saves evidence
php_surface_audit.py - Target auditor → HTML CSV JSON: generates reports
php_surface_audit.py - DNS resolver → dnspython: uses optionally
README.md