Skip to main content

perry-spies

perry-spies

perry-spies is a powerful, lightweight Python package that provides comprehensive local static application security testing (SAST) and live web fuzzing features:

  • Local Repository Scanning: Multi-language AST-based parsing, hardcoded secret discovery, and dependency advisory checking.
  • Live Web Fuzzing: On-demand custom HTTP request validation, fuzzing suite attacks (SQLi, XSS, Path Traversal, Cmd Injection), and reporting.

You can run perry-spies inside your terminal for quick local audits, integrate it as a CI/CD gate in GitHub Actions/GitLab, or use its underlying services directly in your Python applications.


More About perry-spies

At a granular level, perry-spies consists of the following key CLI subcommands and internal services:

Component Description
perry scan Scans a local repository or directory for secrets, code quality issues, and dependency vulnerabilities.
perry custom-test Sends on-demand attack vectors (shorthand or JSON schema) to a live URL and returns detailed findings.
perry.services.sast_engine AST-based static analysis engine natively parsing Python and JS/TS patterns.
perry.services.risk_engine Deterministic 5-factor risk scoring engine that bands repository threats from minimal to critical.

Usually, perry-spies is used either as:

  1. A fast, local pre-commit hook or security gate in CI/CD pipelines.
  2. A lightweight fuzzer to quickly test specific live web endpoints for common injection vulnerabilities.

Key Features

AST-Based SAST

Rather than searching for naive regex patterns, perry-spies uses abstract syntax tree (AST) parsers (leveraging tree-sitter for polyglot support) to understand actual code structure. This flags genuine issues like unsafe SQL string concatenations and dangerous evaluations while keeping false positives low.

Intelligent Secret Hygiene

The secret scanner matches credentials against high-entropy patterns. It automatically cross-references discovered secrets with your repository's .gitignore. Files that are ignored are flagged as low-severity hygiene logs, while unignored secrets generate active security alerts.

Fully Local Dependency Advisory

It extracts dependencies from manifests (like package.json, requirements.txt, etc.) and performs reachability analysis. It queries OSV.dev advisories to check if vulnerable libraries are imported and actually used in execution paths.

Live Fuzzing Preset Attacks

Using the custom-test subcommand, you can run pre-packaged test suites mimicking common attacks:

  • Reflected XSS: Identifies if unescaped markers reflect into the DOM.
  • SQL Injection: Probes inputs with database error-triggering and boolean payloads.
  • Path Traversal: Tests local file inclusion against system structures like /etc/passwd.
  • Command Injection: Traces system command outcomes using canary echo execution.

Installation

Install the package directly from PyPI:

pip install perry-spies

Local Development Installation

For developers wishing to extend or test perry-spies locally:

git clone https://github.com/aayushhh-operator/perry.git
cd perry/backend
pip install -e .

Getting Started

Scan the current directory

perry scan

Scan a specific folder and fail if high/critical issues are found

perry scan /path/to/project --fail-on high

Run the default fuzzing suite against a live site (with authorization)

perry custom-test --url https://perryspies.vercel.app/ --authorized

Export definitive logs to a JSON file

perry scan --json report.json

License

perry-spies is distributed under the MIT license.

Download files

Download the file for your platform. If you're not sure which to choose, learn more about installing packages.

Source Distribution

perry_spies-1.0.5.tar.gz (141.8 kB view details)

Uploaded Source

Built Distribution

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

perry_spies-1.0.5-py3-none-any.whl (151.5 kB view details)

Uploaded Python 3

File details

Details for the file perry_spies-1.0.5.tar.gz.

File metadata

  • Download URL: perry_spies-1.0.5.tar.gz
  • Upload date:
  • Size: 141.8 kB
  • Tags: Source
  • Uploaded using Trusted Publishing? No
  • Uploaded via: twine/7.0.0 CPython/3.13.15

File hashes

Hashes for perry_spies-1.0.5.tar.gz
Algorithm Hash digest
SHA256 c46f178efe153b237bf2a3a8e3b800a19fc45bd5bfe57b02286aa5fc7491351a
MD5 d6dd26e79b79989ef8d969b607571711
BLAKE2b-256 f082f269267f27ba1feee48a98fc1f87baa15625e7ab9a0400cff7bfafdda4df

See more details on using hashes here.

File details

Details for the file perry_spies-1.0.5-py3-none-any.whl.

File metadata

  • Download URL: perry_spies-1.0.5-py3-none-any.whl
  • Upload date:
  • Size: 151.5 kB
  • Tags: Python 3
  • Uploaded using Trusted Publishing? No
  • Uploaded via: twine/7.0.0 CPython/3.13.15

File hashes

Hashes for perry_spies-1.0.5-py3-none-any.whl
Algorithm Hash digest
SHA256 037c6ae3cabc12af7748593857223d93e27c3e285b30f76e33a02ee88d7cb493
MD5 a79eb13291c5032184be155d0d8e5494
BLAKE2b-256 0b5852480729f34152fcf1a326a44bb84e4058d7d0753bc00c2f52d31547a467

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 Sentry Error logging StatusPage Status page