Skip to main content

Real-time adversarial-input firewall for Pipecat voice agents — blocks prompt injection, PII-extraction, and policy-override before the LLM acts on it.

Project description

pipecat-firewall

A real-time adversarial-input firewall for Pipecat voice agents. It inspects each user turn in real time and blocks, flags, or redacts adversarial content — PII-extraction solicitation, prompt injection, and policy-override — before the LLM acts on it.

Detection + enforcement only: deterministic, dependency-light, and production-safe. Tested against the pipecat-ai 0.0.x line (0.0.98–0.0.108); the dependency is capped <1.0 because pipecat-ai 1.x restructures the frame API (1.x support is future work).

Status: 0.1.0 core. The inbound SentryFirewall FrameProcessor ships with three deterministic detectors and block/flag/redact enforcement. The outbound SentryLeakGuard and the optional LLM classifier land in later steps.

Install

pip install pipecat-firewall

The one-liner

from pipecat_firewall import SentryFirewall

pipeline = Pipeline([
    transport.input(),
    stt,
    SentryFirewall(),          # ← detects & blocks adversarial input
    context_aggregator.user(),
    llm,
    tts,
    transport.output(),
    context_aggregator.assistant(),
])

Detection categories

Category What it catches
PROMPT_INJECTION "ignore previous instructions", developer mode, "repeat your system prompt"
PII_EXTRACTION soliciting the agent to read back a card number, SSN, PIN, CVV
POLICY_OVERRIDE "skip verification", "my manager authorized", manufactured urgency
PII_LEAK outbound: Luhn-valid card numbers, SSN/PIN/CVV in the agent's response

License

MIT

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

pipecat_firewall-0.1.0.tar.gz (18.4 kB view details)

Uploaded Source

Built Distribution

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

pipecat_firewall-0.1.0-py3-none-any.whl (16.3 kB view details)

Uploaded Python 3

File details

Details for the file pipecat_firewall-0.1.0.tar.gz.

File metadata

  • Download URL: pipecat_firewall-0.1.0.tar.gz
  • Upload date:
  • Size: 18.4 kB
  • Tags: Source
  • Uploaded using Trusted Publishing? Yes
  • Uploaded via: twine/6.1.0 CPython/3.13.12

File hashes

Hashes for pipecat_firewall-0.1.0.tar.gz
Algorithm Hash digest
SHA256 29bef139c8b56c48cc5a04678dbbecea7d6b74cf755776e08f63cdd9d5736fa0
MD5 185cb7e60c8e56f76093555df7655a4b
BLAKE2b-256 53f8d2f0d9356084bf6bd6387482b5441240b188e3d3b2bc2a0318d6809ffb66

See more details on using hashes here.

Provenance

The following attestation bundles were made for pipecat_firewall-0.1.0.tar.gz:

Publisher: publish.yml on rushjais/pipecat-firewall

Attestations: Values shown here reflect the state when the release was signed and may no longer be current.

File details

Details for the file pipecat_firewall-0.1.0-py3-none-any.whl.

File metadata

File hashes

Hashes for pipecat_firewall-0.1.0-py3-none-any.whl
Algorithm Hash digest
SHA256 dee45e46f531218981e0e285aa6f5b14b6002703732a69a8367c2afe45bae54c
MD5 d6b29a927a03491137fb6c389e9de188
BLAKE2b-256 1bda27ed4dbb67b31f23751b0f7a0a997483555db60206b8e8a9c23072096e06

See more details on using hashes here.

Provenance

The following attestation bundles were made for pipecat_firewall-0.1.0-py3-none-any.whl:

Publisher: publish.yml on rushjais/pipecat-firewall

Attestations: Values shown here reflect the state when the release was signed and may no longer be current.

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