Skip to main content

SKSecurity

CI

Small, local security tools for an AI agent estate. Four things ship:

Tool What it does Honest limit
guard Finds leaked credentials in files, directories, staged git changes and text. Redacts what it prints. 12 regexes. Finds known token shapes and key = "value" assignments, nothing else.
claims Fails on forbidden crypto overclaims in docs and code ("quantum-proof", "unbreakable"). Runs in CI. Pattern match. Honest negations and quoted references are allowed.
screen Scores text for phishing, prompt injection and social engineering. Text-only regex heuristics. A SAFE verdict is not a guarantee.
pqc-* Post-quantum self-report built from live skcomms / SKStacks data. Reports what the registry says is deployed, per surface.

Also in the package: sksecurity.kms (an HKDF + AES-GCM key-wrapping KMS that skcapstone imports), an MCP server with two tools, and an optional sk-alert adapter.

Everything is read-only with respect to the files it inspects. Nothing is moved, deleted or modified, nothing runs in the background, and there are no network calls. License: GPL-3.0-or-later.

2.0 removed the scanner, quarantine, dashboard, threat-intel feed and monitor (see CHANGELOG.md). They did not work and one of them moved the scanned directory.

Install

pip install sksecurity            # CLI: sksecurity, MCP server: sksecurity-mcp
pip install 'sksecurity[skcapstone]'   # optional: publish alerts on sk-alert

Examples

Output below was produced by running the commands against a throwaway directory with a temporary HOME.

guard: find secrets

$ sksecurity guard scan demo
🔐 SKSecurity Secret Guard Report
==================================================
📁 Target: demo
📄 Files Scanned: 1

🚨 Found 1 secret(s):
------------------------------
  🟠 PostgreSQL Connection String
     File: demo/settings.py:3
     Match: post********************app"
     PostgreSQL connection string with credentials
     Fix: Change the database password. Use environment variables.
$ echo $?
1

Other forms: guard staged (what would be committed), guard text "...", guard install (git pre-commit hook), --format json. Exit code is 1 when secrets are found.

claims: block overclaims

$ sksecurity claims text "our link is quantum-proof"
🚨 Found 1 overclaim(s):
  🔴 quantum-proof: quantum-proof
     Say: Say "post-quantum" / "quantum-resistant" and cite FIPS 203/204.
$ echo $?
1

sksecurity claims scan . is the CI gate (.github/workflows/honest-claims.yml). Suppress an honest reference with # honest-claims: allow or list a file in .honestclaims-allow.

screen: heuristic input screening

$ sksecurity screen "Your account is suspended. Verify your password at http://paypa1-login.tk/verify" --subject "Urgent: account suspended"
🛡️ SKSecurity Email/Input Screening Report
==================================================
📊 Risk Score: 59.2/100
🎯 Verdict: SUSPICIOUS

🚨 Found 1 issue(s):
------------------------------
  🟠 [HIGH] malicious_link
     Suspicious URL: suspicious TLD (.tk), phishing keyword in domain (login)
     Match: "http://paypa1-login.tk/verify"
     Fix: Do not follow this link. Verify with the sender through a trusted channel.

It misses things. click http://bit.ly/x to verify your password now with subject Urgent scores 0 and SAFE. Treat it as one weak signal, not a filter.

pqc-*: post-quantum posture

pqc-report, pqc-posture, pqc-dashboard, pqc-snapshot and pqc-stacks print a per-surface table (hybrid-pq, gated, classical, symmetric) with FIPS references and honest notes. --static shows the model defaults instead of live fleet state. pqc-stacks needs SKStacks at ~/clawd/SKStacks or SKSTACKS_ROOT. capauth imports sksecurity.pqc_report.

$ sksecurity pqc-posture --static
🔐 PQC Posture - coverage self-report (per surface)
======================================================================
Mode: static   (honest claims only - hybrid = either-leg; no overclaims)

surface       posture    wire-tag                   suite
----------------------------------------------------------------------
dm-ratchet    gated      pqdr1                      x25519-pgp-wrap-v1 → x25519-mlkem768
group         gated      kem_suite                  rsa-pgp-wrap-v1 → x25519-mlkem768
...
transport     classical  channel: WireGuard/TLS X25519 wireguard-x25519 / tls1.3-x25519

MCP server

sksecurity-mcp speaks stdio and exposes two tools:

  • check_secrets: run the secret guard on text.
  • screen_input: run the email/input screener on text (optional sender, subject).
{"mcpServers": {"sksecurity": {"command": "sksecurity-mcp"}}}

Library use

from sksecurity import SecretGuard, EmailScreener
from sksecurity.honest_claims import HonestClaimsScanner
from sksecurity.kms import KMS            # used by skcapstone
from sksecurity.pqc_report import build_live_report   # used by capauth

Development

pip install -e '.[dev]'
pytest
ruff check sksecurity/

The test suite points HOME and SKCAPSTONE_HOME at tmp dirs and sets SK_STANDALONE=1 (tests/conftest.py), so it never touches real state. Keep doing that if you run tests some other way.

See SOP.md for operations, docs/ARCHITECTURE.md for the module map, docs/QUANTUM_RESISTANCE.md for the PQC inventory, SECURITY.md to report a vulnerability, and CONTRIBUTING.md.

Metadata

Release files for sksecurity 1.2.8

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

Source distribution (sdist)

Source distribution for sksecurity 1.2.8
File Size Uploaded Provenance Actions
sksecurity-1.2.8.tar.gz 197.8 kB Without provenance Details for sksecurity-1.2.8.tar.gz

Built distribution (wheel)

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

Total release size: 297.8 kB

Release files / sksecurity-1.2.8.tar.gz

Download URL sksecurity-1.2.8.tar.gz
Size 197.8 kB
Tags Source
SHA-256 checksum
How to use checksums
e0444411eb976586e8163bb0fed0161f55016a9b944fefa150c9844a1f3f6624
BLAKE2b-256 checksum
How to use checksums
7e7ec5e28d91214c5126c7315f119e48f1616b7ced807bab6d0b280f5be1e40f
Upload date
Uploaded using Trusted Publishing?
What is trusted publishing?
No
Uploaded via twine/7.0.0 CPython/3.12.16

Release files / sksecurity-1.2.8-py3-none-any.whl

Download URL sksecurity-1.2.8-py3-none-any.whl
Size 99.9 kB
Tags Python 3
SHA-256 checksum
How to use checksums
6d7be16203fe531db6022acf24a3f7487946c4d0fb794f6fb4635020157fe8f8
BLAKE2b-256 checksum
How to use checksums
15c72acf0453ff92197b255c2df6661a46eb5ab92cc8027cebf849ab0fec06a4
Upload date
Uploaded using Trusted Publishing?
What is trusted publishing?
No
Uploaded via twine/7.0.0 CPython/3.12.16

Security for sksecurity 1.2.8

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.

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