Skip to main content

BADASS Local Runner

Securely connect private AI endpoints to BADASS Cloud for authorized behavioral security testing.


What it is

The BADASS Local Runner (badass-runner) connects AI endpoints inside your private network to BADASS Cloud without requiring them to be publicly accessible.

The runner establishes an outbound connection, executes authorized behavioral security tests locally, and returns structured, redacted results to the BADASS dashboard. It supports token-based registration, configurable endpoint access, CI and headless environments, and strict protocol validation.

The runner reports observed endpoint behavior. It does not claim that an upstream gateway enforced a policy unless that enforcement is independently verified.

Why it exists

Many AI systems under test run behind:

  • corporate VPNs
  • private cloud networks
  • localhost development environments
  • firewalls that block inbound connections

BADASS Cloud cannot reach these endpoints directly. The connector solves this by running inside your network and pulling jobs from the cloud rather than receiving inbound traffic.

Your endpoint never needs a public IP address. Your credentials never leave your machine.


Requirements

  • Python 3.11 or later
  • Network access to https://badass-sec.com (outbound HTTPS only)
  • The AI endpoint you want to test (reachable from the machine running the connector)

Installation

From PyPI (recommended)

pip install badass-runner

From source

git clone https://github.com/DKB8man/badass-connector
cd badass-connector
pip install .

Verify

badass-runner --version

See docs/install.md for detailed install options, virtual environment setup, and environment variable reference.


Quick start

1. Create a registration token

Open Connect Runner in BADASS Cloud, name the connector, and create its one-time account-owned registration token.

2. Register and start the connector

badass-runner start \
  --server-url https://badass-sec.com \
  --token badass_reg_YOURTOKEN \
  --name my-private-ai-server

The one-time token is exchanged for a permanent local runner credential. The connector runs in the foreground, sends a heartbeat to the cloud every 30 seconds, and polls for harness jobs assigned to it. Later starts use the saved credential:

badass-runner start

Press Ctrl-C or run badass-runner stop (from another terminal) to shut it down.

3. Check status

badass-runner status

Testing private and local AI apps

The connector targets any HTTP endpoint that accepts a text message and returns a text reply — the same interface used by most chat-completion, agent, and RAG APIs.

Typical configuration in the BADASS Cloud dashboard:

Field Example
Base URL http://localhost:8000
Message path /api/chat
Method POST
Request field message
Response field reply
Auth type bearer / api_key / none

Credentials (API keys, Bearer tokens) are stored in the connector's local auth store on your machine and looked up at runtime. They are never sent to the cloud. See Where credentials live below.


Token-based registration for headless systems

CI pipelines and headless systems use the same account-owned one-time registration-token flow:

badass-runner start \
  --server-url https://badass-sec.com \
  --token    badass_reg_YOURTOKEN \
  --name     my-ci-runner

The token is consumed on first use and replaced with a long-lived runner credential stored in the local config file.


Where credentials live

All connector state is stored in ~/.badass-runner/ (overridable with $BADASS_RUNNER_HOME):

~/.badass-runner/
  config.json   # runner_id, runner_token, server_url, runner_name
  runner.pid    # PID of the running connector process

config.json is written with permissions 0600 (owner read/write only). It contains:

  • server_url — the BADASS Cloud base URL
  • runner_name — a human-readable label you chose
  • runner_id — your runner's UUID assigned by the cloud
  • runner_token — the long-lived bearer token used to authenticate job polls and result uploads

Your API keys and endpoint credentials are never written to config.json. They are managed separately through the BADASS Cloud dashboard and resolved by the connector at job execution time from your local auth store.


What data is uploaded

When the connector completes a harness test, it uploads to BADASS Cloud:

Data Description
Run status DONE, FAILED, or CANCELLED
Per-test turn sequences The messages sent to and received from your endpoint, with auth headers stripped
Endpoint metadata Base URL, method, path, auth type (not auth values)
Validation evidence Pattern-match results used to determine PASS/FAIL
Error messages Failure reasons, passed through credential redaction before upload

What is never uploaded

The connector is designed so the following data never leaves your machine:

Data Handling
API keys Stored locally; injected into requests at runtime; never included in uploaded results
Bearer tokens Stripped from all request/response transcripts before upload
Cookies Stripped from all transcripts; cookie values are replaced with [REDACTED]
Raw Authorization headers Removed from all uploaded turn data
X-Api-Key, X-Auth-Token headers Removed from all uploaded turn data
Proxy or VPN credentials Never read or transmitted by the connector
Quoted-assignment secrets in log lines Caught and redacted by the text-level redactor before error strings are uploaded

See docs/security-model.md for the full technical description of the redaction layer.


Commands

Command Description
badass-runner start --token … Register a new connector with a dashboard-issued one-time token
badass-runner start Start a previously registered connector (foreground)
badass-runner status Show whether a connector process is running locally
badass-runner stop Send SIGTERM to the running connector
badass-runner recorder HTTP traffic recorder for endpoint discovery
badass-runner --version Print connector version
badass-runner --help Show all commands and options

Environment variables

Variable Default Description
BADASS_SERVER_URL Cloud base URL (replaces --server-url)
BADASS_REG_TOKEN One-time registration token (replaces --token)
BADASS_RUNNER_NAME Runner label (replaces --name)
BADASS_RUNNER_HOME ~/.badass-runner Override config directory
BADASS_STATUS_PORT 7890 Local status server port

Local status server

While running, the connector exposes a read-only HTTP status endpoint on localhost at port 7890 (configurable via --port or BADASS_STATUS_PORT). This is not accessible from outside the machine. It is intended for local monitoring integrations.


Security

See SECURITY.md for how to report vulnerabilities and our data handling commitments.

See docs/security-model.md for a full description of what data the connector handles, what it redacts, and what it uploads.


License

See LICENSE file.

Download files

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

Source Distribution

badass_runner-0.4.2.tar.gz (47.3 kB view details)

Uploaded Source

Built Distribution

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

badass_runner-0.4.2-py3-none-any.whl (53.3 kB view details)

Uploaded Python 3

File details

Details for the file badass_runner-0.4.2.tar.gz.

File metadata

  • Download URL: badass_runner-0.4.2.tar.gz
  • Upload date:
  • Size: 47.3 kB
  • Tags: Source
  • Uploaded using Trusted Publishing? Yes
  • Uploaded via: twine/7.0.0 CPython/3.13.14

File hashes

Hashes for badass_runner-0.4.2.tar.gz
Algorithm Hash digest
SHA256 2909f7248dd1f02b40c1919766849b13377542a6a3eaa6cfc36a5940cbd2c4d1
MD5 52995ef12365665296472d51c9efe3c8
BLAKE2b-256 37b3e3bd4def6912a536bf9a6eac52408d329c1f35c17142637b59c309b883ad

See more details on using hashes here.

Provenance

The following attestation bundles were made for badass_runner-0.4.2.tar.gz:

Publisher: runner-release.yml on DKB8man/BADASS

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

File details

Details for the file badass_runner-0.4.2-py3-none-any.whl.

File metadata

  • Download URL: badass_runner-0.4.2-py3-none-any.whl
  • Upload date:
  • Size: 53.3 kB
  • Tags: Python 3
  • Uploaded using Trusted Publishing? Yes
  • Uploaded via: twine/7.0.0 CPython/3.13.14

File hashes

Hashes for badass_runner-0.4.2-py3-none-any.whl
Algorithm Hash digest
SHA256 14522beb4c30d3e5bf91008a7f7c7d32161a5952413c20a062b00a4487bf1d3b
MD5 7c14c88e1a1564ba03d1c9b3f07194c3
BLAKE2b-256 0f701594869484c412f6b2b4cc70da9e01b7d594ebfe9bf817d852e1a6d782cd

See more details on using hashes here.

Provenance

The following attestation bundles were made for badass_runner-0.4.2-py3-none-any.whl:

Publisher: runner-release.yml on DKB8man/BADASS

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

Release history Release notifications | RSS feed

0.5.2

2 files

0.5.1

2 files

0.5.0

2 files

This release

0.4.2 This release

2 files

0.4.0

2 files

0.3.2

2 files

0.3.1

2 files

0.3.0

2 files

Anthropic, PBC Visionary sponsor Bloomberg Visionary sponsor Hudson River Trading Visionary sponsor Meta Visionary sponsor NVIDIA Visionary sponsor Microsoft Sustainability sponsor Depot Continuous Integration AWS Cloud computing and Security Sponsor Datadog Monitoring Fastly CDN Google Download Analytics Sentry Error logging StatusPage Status page