Skip to main content

Otynx

Sniff out the keys your AI agent could grab.

In April 2026 an AI coding agent fixing a small bug found an unrelated API token in a project file, and used it to delete a company's live database and backups in 9 seconds. Rules in a prompt are suggestions: the only real protection is that dangerous keys aren't reachable in the first place.

Otynx shows you what your agent can reach, before you let it loose. It scans a folder for secret keys and risky AI-agent settings, ranks them by how much damage they could do, and tells you how to fix each one. It's read-only, works offline and never sends anything anywhere.

Otynx scanning a project with a production database URL, a GitHub token in .mcp.json, loose Claude Code permissions and a Stripe test key

Quick start

pip install otynx
otynx scan .           # scan the current folder

Requires Python 3.11+. Status: v0.1.3, alpha. Feedback and new rules welcome!

Options

Command What it does
otynx scan <folder> Scan a project folder (default: .)
--home Also check credential files in your home folder: ~/.aws, ~/.kube, ~/.docker, ~/.npmrc, ~/.pypirc, ~/.netrc, ~/.git-credentials, gcloud, Azure, and ~/.ssh (only checks that key files exist, never reads them)
--json Print results as JSON for scripts and CI
--list-files Also list every file that was scanned

Exit code: 1 if anything is CRITICAL, otherwise 0. Use it in CI or as a pre-agent hook. You can also run it with python -m otynx scan <folder>.

What it checks

  • Secrets: database URLs with passwords, AWS keys, GitHub tokens, OpenAI and Anthropic keys, Stripe live and test keys, Supabase service-role keys, Slack tokens, Google API keys, private keys, npm and PyPI tokens, and any random-looking value stored under a name like SECRET, TOKEN, PASSWORD or API_KEY.
  • Agent configs: secrets written straight into .mcp.json, .cursor/mcp.json or .vscode/mcp.json instead of loaded from the environment, and .claude/settings.json files that allow every Bash command with no deny rules (or turn permission prompts off).
  • Skipped: node_modules, .git, venv, binary files, files over 1 MB, and placeholders like your-key-here, xxxx, <API_KEY> or ${TOKEN}.

How the danger level is worked out

Each finding starts with points for the worst thing its key can do: 40 if it controls real systems (databases, cloud, private keys), 30 if it changes code or money (GitHub, Stripe live), 20 if it spends money or reads data (OpenAI, Slack, Google), and 10 for test or unknown keys. Then it gets +10 if it looks live (prod, production, live nearby), −10 if it looks safe (localhost, test, dev, sandbox), +5 if it's inside the project folder, +5 if the same secret is in more than one file, and +5 if tools load it automatically (a .env file or the default AWS profile). 45+ is CRITICAL, 30–44 HIGH, 20–29 MEDIUM, under 20 LOW. Loose agent permissions aren't secrets, so they're always MEDIUM.

Safety promises

  1. Read-only. Otynx never edits, moves or deletes a file.
  2. Offline. No network calls, ever.
  3. Masked. Secrets are always shown masked, e.g. sk_live_****9f2a, in the terminal, in JSON and in errors.
  4. Never reads ~/.ssh. It only reports that private key files exist.
  5. Home folder is opt-in. It looks outside the project only with --home.
  6. No telemetry. Nothing about you or your scans is collected.

Only scan projects and computers you own or are allowed to check.

Developing

python -m venv .venv
.venv\Scripts\activate          # Windows  (macOS/Linux: source .venv/bin/activate)
pip install -e ".[dev]"
pytest

The full plan is in SPEC.md. To add a detection rule, add one Rule(...) to src/otynx/rules.py and a must-find and must-ignore test to tests/test_detectors.py. Never put a real-looking secret in a file: build fake ones at runtime (see tests/fake_secrets.py).

Metadata

Release files for otynx 0.1.3

For a detailed explanation of source distributions (sdists) and built distributions (wheels), please see the package formats documentation.

Source distribution (sdist)

Source distribution for otynx 0.1.3
File Size Uploaded Provenance Actions
otynx-0.1.3.tar.gz 35.5 kB Without provenance Details for otynx-0.1.3.tar.gz

Built distribution (wheel)

Table of built distributions (wheels) for otynx 0.1.3
File Interpreter ABI Platform Actions
otynx-0.1.3-py3-none-any.whl Python 3 none any Details for otynx-0.1.3-py3-none-any.whl

Total release size: 63.6 kB

Release files / otynx-0.1.3.tar.gz

Download URL otynx-0.1.3.tar.gz
Size 35.5 kB
Tags Source
SHA-256 checksum
How to use checksums
8350a90c919eed716588581750c49ff32033a96815111054d62279c0acacfde2
BLAKE2b-256 checksum
How to use checksums
f79a049c9b2098098c49858a654efee5e35071eaecf9f0b82de2282683a8565f
Upload date
Uploaded using Trusted Publishing?
What is trusted publishing?
No
Uploaded via twine/7.0.0 CPython/3.14.7

Release files / otynx-0.1.3-py3-none-any.whl

Download URL otynx-0.1.3-py3-none-any.whl
Size 28.2 kB
Tags Python 3
SHA-256 checksum
How to use checksums
3c8c31eeb2328db92a8aa30d6d6ec86519627c94d5ba31bd0f2889e3c1f655ff
BLAKE2b-256 checksum
How to use checksums
cfd8ee6b8e76304965f98e3cd9c05e40d14fa5fb62c2885d7dac5ea4b17b3ad9
Upload date
Uploaded using Trusted Publishing?
What is trusted publishing?
No
Uploaded via twine/7.0.0 CPython/3.14.7

Security for otynx 0.1.3

Provenance

Provenance describes where a file came from. On PyPI, provenance is shared via attestations, which provide a verifiable record of the build or publishing details. View details, limitations and caveats.

No provenance found

None of the files in this release were uploaded with provenance metadata.

A note on package security

PyPI is a repository for distributing packages, not a service for auditing them. While third-party security researchers and our staff do their best to detect and remove malicious packages, PyPI cannot guarantee the quality, security or suitability of any given package.

To learn more about protecting yourself from malicious actors, visit our package security documentation.

Release history Release notifications | RSS feed

This release

0.1.3 This release

2 release files No provenance

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