Skip to main content

Context-aware async XSS scanner for CI

Project description

Company: EasyProTech LLC (www.easypro.tech) Dev: Brabus Contact: https://t.me/EasyProTech

BRS-XSS

Context-aware async XSS scanner for CI

Python Tests Coverage Docker PyPI GHCR SARIF Security Performance License

Professional XSS vulnerability scanner with intelligent context detection, async performance, and enterprise-grade reporting.


Why BRS-XSS?

Context-Aware Detection - Understands HTML, JavaScript, CSS, and attribute contexts for precise payload generation
Async Performance - Scans 1000+ URLs in 12 minutes on 8 vCPU with intelligent rate limiting
CI/CD Ready - SARIF output integrates directly with GitHub Security, GitLab, and other SAST platforms
WAF Evasion - Advanced bypass techniques for Cloudflare, AWS WAF, ModSecurity, and 7+ popular WAFs
Enterprise Features - Comprehensive reporting, payload deduplication, and production-safe defaults

Comparison Matrix

Feature BRS-XSS XSStrike XSpear dalfox
Context Detection ✅ 6 contexts ⚠️ Basic ⚠️ Basic ✅ 4 contexts
Async Performance ✅ 32 concurrent ❌ Sequential ❌ Sequential ✅ 100 concurrent
SARIF Output ✅ Full spec ❌ No ❌ No ⚠️ Basic
WAF Bypass ✅ 8 WAFs ✅ 5 WAFs ⚠️ 3 WAFs ✅ 6 WAFs
False Positive Rate ✅ <5% ⚠️ ~15% ⚠️ ~20% ✅ <8%
CI Integration ✅ Native ❌ Manual ❌ Manual ⚠️ Scripts

Quickstart (60 seconds)

Install & Scan

pip install -U brs-xss
brs-xss scan https://target.tld -o out.sarif --fast

Docker

docker run --rm -v $(pwd):/out ghcr.io/eptllc/brs-xss:latest scan https://target.tld -o /out/out.sarif

GitHub Actions Integration

- name: XSS Security Scan
  run: |
    pip install brs-xss
    brs-xss scan ${{ github.event.repository.html_url }} -o xss-results.sarif
    
- name: Upload SARIF
  uses: github/codeql-action/upload-sarif@v2
  with:
    sarif_file: xss-results.sarif

Results & Reporting

SARIF Integration

Perfect integration with GitHub Security tab, GitLab Security Dashboard, and SAST platforms:

Notes on SARIF 2.1.0 compliance:

  • Includes driver.semanticVersion matching package version
  • Each rule provides help text and helpUri
  • run-level properties columnKind=utf16CodeUnits and defaultEncoding=utf-8 are set on save
# Scan and upload to GitHub Security
brs-xss scan https://app.example.com -o security.sarif
gh api repos/:owner/:repo/code-scanning/sarifs -f sarif=@security.sarif

Interactive HTML Reports

Rich HTML reports with vulnerability details, payload explanations, and one-click replay:

brs-xss scan https://target.tld --output-html report.html

JSON Schema Validation

Machine-readable results with full JSON Schema validation:

{
  "scan_info": {
  "timestamp": "2025-09-08T09:03:08Z",
  "scanner": "BRS-XSS v1.0.5.1",
    "targets_scanned": 47,
    "vulnerabilities_found": 8,
    "false_positive_rate": "3.2%"
  },
  "vulnerabilities": [
    {
      "url": "https://app.example.com/search?q=test",
      "parameter": "q",
      "context": "html_attribute", 
      "payload": "\" onmouseover=\"alert(1)\"",
      "severity": "high",
      "confidence": 0.94,
      "cwe": "CWE-79",
      "sarif_rule_id": "XSS001"
    }
  ]
}

Advanced Features

Context Matrix

  • HTML Context - Tag content, attributes, comments
  • JavaScript Context - Script blocks, event handlers, JSON
  • CSS Context - Style blocks, inline styles
  • URI Context - URL parameters, fragments
  • SVG Context - SVG elements and attributes
  • XML Context - CDATA, processing instructions

Performance & Safety

  • Rate Limiting - 8 RPS default, respects robots.txt
  • Concurrency Control - 32 concurrent requests with backoff
  • Smart Caching - URL+parameter reflection cache, Bloom filter deduplication
  • Safe Mode - Production-safe defaults: depth 3, denylist enabled

Payload Engineering

  • 1200+ Payloads - Context-specific, polyglot, and WAF bypass variants
  • Intelligent Selection - ML-enhanced payload effectiveness scoring
  • Aggr Mode - Multi-encoding polyglots for maximum coverage
  • WAF Metrics - Hit rates tested on 10+ demo targets

License

Dual License: GPL-3.0-or-later OR Commercial License.

  • Open Source (GPLv3+): for education, research, open-source, and non-commercial usage.
  • Commercial License: for commercial use, proprietary integrations, or when GPL is not suitable.

See the LICENSE file for full terms and contact details.


Configuration

Default config in ~/.config/brs-xss/config.toml:

[scanner]
concurrency = 32
rate_limit = 8.0  # requests per second
timeout = 15
max_depth = 3
safe_mode = true

[generator]
max_payloads = 500
effectiveness_threshold = 0.65
include_evasions = true
include_waf_specific = true
seed = 1337
max_manager_payloads = 2000
max_evasion_bases = 10
evasion_variants_per_tech = 2
waf_bases = 3
enable_aggressive = false
pool_cap = 10000
norm_hash = false

[payloads]
contexts = ["html", "attribute", "script", "css", "uri", "svg"]
aggr_mode = false  # Enable polyglot + multi-encoding
waf_bypass = true

[output]
formats = ["sarif", "json", "html"]
include_screenshots = true
replay_urls = true

Commands

# Quick scan
brs-xss scan https://target.tld

# Comprehensive scan with all contexts
brs-xss scan https://target.tld --aggr --deep

# List available payloads by context
brs-xss payloads list --context html

# Replay specific vulnerability
brs-xss replay https://target.tld/vuln?param=payload

# Merge multiple scan reports  
brs-xss report merge scan1.json scan2.json -o combined.sarif

CI/CD & Docker

  • Dockerfile included for local builds
  • Multi-arch Docker builds via GitHub Actions (linux/amd64, linux/arm64). To push images, set repository secrets DOCKERHUB_USERNAME and DOCKERHUB_TOKEN.

Installation Options

PyPI (Recommended)

pip install brs-xss

Docker

docker pull ghcr.io/eptllc/brs-xss:latest

From Source

git clone https://github.com/EPTLLC/brs-xss.git
cd brs-xss
pip install -e .

How-To Guides

  1. Quick Scan - Get started in 2 minutes
  2. CI Integration - GitHub Actions, GitLab CI, Jenkins
  3. SARIF in GitHub - Security tab integration
  4. Docker Usage - Container deployment
  5. Safe Mode - Production scanning guidelines
  6. Configuration - Complete parameter reference

Benchmarks

Performance: 1000 URLs scanned in 12 minutes on 8 vCPU VPS
Accuracy: <5% false positive rate on DVWA, WebGoat, XSS-Game
Coverage: 98% payload success rate against unprotected targets
Reliability: 100% reproducible results with pinned dependencies

Benchmark


Legal & Ethics

Authorized Testing Only: This tool is designed for legitimate security testing with proper authorization.

Commercial License: Enterprise support available at https://t.me/EasyProTech


Contributing

  1. Fork the repository
  2. Create feature branch: git checkout -b feature/amazing-feature
  3. Follow code standards: ruff check .
  4. Add tests: pytest tests/
  5. Submit pull request

Good First Issues: Look for good-first-issue and help-wanted labels.


Roadmap

Sprint 1 (Current)

  • SARIF 2.1.0 full compliance
  • Performance benchmarks
  • Docker multi-arch builds

Sprint 2 (Next)

  • GraphQL endpoint scanning
  • WebSocket XSS detection
  • Custom payload templates
  • Burp Suite extension

BRS-XSS v1.0.5.1 | EasyProTech LLC | https://t.me/EasyProTech

Context-aware async XSS scanner for CI

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

brs_xss-1.1.0.tar.gz (190.8 kB view details)

Uploaded Source

Built Distribution

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

brs_xss-1.1.0-py3-none-any.whl (263.2 kB view details)

Uploaded Python 3

File details

Details for the file brs_xss-1.1.0.tar.gz.

File metadata

  • Download URL: brs_xss-1.1.0.tar.gz
  • Upload date:
  • Size: 190.8 kB
  • Tags: Source
  • Uploaded using Trusted Publishing? No
  • Uploaded via: twine/6.2.0 CPython/3.10.12

File hashes

Hashes for brs_xss-1.1.0.tar.gz
Algorithm Hash digest
SHA256 f320e610d111fab225b233ac47ab85ae3e2c11215675b4fbe7d9d0ede7024ce1
MD5 8499065d747782def8380c8d9dcea628
BLAKE2b-256 9d8e5c206453c4987eae7b9a38b8c655aefc8231d2500f30ffb7ad0f111fa753

See more details on using hashes here.

File details

Details for the file brs_xss-1.1.0-py3-none-any.whl.

File metadata

  • Download URL: brs_xss-1.1.0-py3-none-any.whl
  • Upload date:
  • Size: 263.2 kB
  • Tags: Python 3
  • Uploaded using Trusted Publishing? No
  • Uploaded via: twine/6.2.0 CPython/3.10.12

File hashes

Hashes for brs_xss-1.1.0-py3-none-any.whl
Algorithm Hash digest
SHA256 c1f4a4c375cb5f82ee11d6fee8f5c61315b398ccaeddb23d51c24cf244087775
MD5 3f92a6cdc5a63df100af9e8948ef2770
BLAKE2b-256 4ce23fc181ee89c70cdb84478ada4f4b00573101986d2472f3dbf6dafebda2ff

See more details on using hashes here.

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