Skip to main content

AI-powered security code auditor and project alignment validator

Project description

KYLO ๐Ÿ›ก๏ธ

PyPI version Python Support License: MIT Downloads

KYLO is an AI-powered security code auditor that helps developers ship safer code. It performs static analysis, detects vulnerabilities, and aligns your codebase with your project goalsโ€”all from the command line.

โœจ Features

  • ๐Ÿ” AST-Based Security Scanning โ€” Detects dangerous functions (eval, exec), SQL injection risks, and common vulnerabilities
  • ๐Ÿ›ก๏ธ Advanced Security Checks โ€” Finds hardcoded secrets, weak crypto, auth risks, and more
  • ๐Ÿ“Š Project Alignment โ€” Validates code against your README goals and requirements
  • ๐Ÿ”’ Privacy-First โ€” Encrypted local storage for sensitive data
  • ๐ŸŽจ Beautiful Terminal UI โ€” Rich, colorful output with progress indicators
  • ๐Ÿ“ˆ Usage Tracking โ€” Monitor audits and scans with built-in analytics
  • โšก Zero-Config โ€” Works out of the box, no API keys required for basic scanning

๐Ÿš€ Installation

Via pip (Recommended)

pip install kylo

From source

git clone https://github.com/Shizzysagacious/kylo.git
cd kylo
pip install -e .

๐Ÿ“– Quick Start

1. Initialize KYLO in your project

cd your-project
kylo init

This creates:

  • .kylo/ directory for state and configuration
  • README.md template (if missing)
  • Project goals tracking

2. Run a security audit

# Audit current directory
kylo audit

# Audit specific file or folder
kylo audit backend/api.py
kylo audit src/

3. Get security hardening recommendations

kylo secure backend/

4. View usage statistics

kylo stats

๐Ÿ”ง Configuration

Setting an Admin Token

Protect sensitive operations with an admin token:

kylo config set-admin-token

Storing API Keys (Optional)

For advanced features, you can store API keys securely:

kylo config set-api-key gemini

All keys are encrypted using hardware-bound encryption and stored in .kylo/secure/.

Environment Variables

Customize KYLO's behavior with environment variables:

# Rate limits (requests per hour)
export KYLO_RATE_LIMIT_AUDITS=100
export KYLO_RATE_LIMIT_SECURE=50

# CLI colors
export KYLO_CLI_PRIMARY_COLOR=magenta
export KYLO_CLI_ACCENT_COLOR=purple

# Logging
export KYLO_LOG_LEVEL=INFO  # DEBUG, INFO, WARNING, ERROR

๐Ÿ›ก๏ธ Security Checks

KYLO performs comprehensive security analysis:

Basic Checks

  • Dangerous function usage (eval, exec, pickle.loads)
  • SQL injection vulnerabilities (f-strings in queries)
  • Insecure file operations
  • Weak cryptographic functions (MD5, SHA1)

Advanced Checks (Aggressive Mode)

  • Hardcoded secrets and credentials
  • Authentication and session management risks
  • Network operation vulnerabilities
  • Data deserialization issues
  • Security-relevant code comments (TODO, FIXME, HACK)

๐Ÿ“Š Usage Examples

Audit with verbose output

kylo -v audit backend/

Check specific security concerns

kylo secure api/auth.py

List stored API keys

kylo config list-keys

๐ŸŽจ Terminal UI

KYLO features a beautiful, modern terminal interface:

โ–ˆโ–ˆโ•—  โ–ˆโ–ˆโ•—โ–ˆโ–ˆโ•—   โ–ˆโ–ˆโ•—โ–ˆโ–ˆโ•—      โ–ˆโ–ˆโ–ˆโ–ˆโ–ˆโ–ˆโ•— 
โ–ˆโ–ˆโ•‘ โ–ˆโ–ˆโ•”โ•โ•šโ–ˆโ–ˆโ•— โ–ˆโ–ˆโ•”โ•โ–ˆโ–ˆโ•‘     โ–ˆโ–ˆโ•”โ•โ•โ•โ–ˆโ–ˆโ•—
โ–ˆโ–ˆโ–ˆโ–ˆโ–ˆโ•”โ•  โ•šโ–ˆโ–ˆโ–ˆโ–ˆโ•”โ• โ–ˆโ–ˆโ•‘     โ–ˆโ–ˆโ•‘   โ–ˆโ–ˆโ•‘
โ–ˆโ–ˆโ•”โ•โ–ˆโ–ˆโ•—   โ•šโ–ˆโ–ˆโ•”โ•  โ–ˆโ–ˆโ•‘     โ–ˆโ–ˆโ•‘   โ–ˆโ–ˆโ•‘
โ–ˆโ–ˆโ•‘  โ–ˆโ–ˆโ•—   โ–ˆโ–ˆโ•‘   โ–ˆโ–ˆโ–ˆโ–ˆโ–ˆโ–ˆโ–ˆโ•—โ•šโ–ˆโ–ˆโ–ˆโ–ˆโ–ˆโ–ˆโ•”โ•
โ•šโ•โ•  โ•šโ•โ•   โ•šโ•โ•   โ•šโ•โ•โ•โ•โ•โ•โ• โ•šโ•โ•โ•โ•โ•โ• 

AI-Powered Security Code Auditor v1.0.0

๐Ÿ” Scanning files...
๐Ÿ“‚ Reading project structure...
๐Ÿ›ก๏ธ Running security checks...
โœ“ Audit complete!

Files scanned: 45
Issues found: 3

๐Ÿ—๏ธ Project Structure

your-project/
โ”œโ”€โ”€ .kylo/
โ”‚   โ”œโ”€โ”€ state.json          # Audit results and history
โ”‚   โ”œโ”€โ”€ goals.json          # Project goals for alignment
โ”‚   โ”œโ”€โ”€ secure/             # Encrypted API keys (if configured)
โ”‚   โ”‚   โ””โ”€โ”€ humanwhocodes.enc
โ”‚   โ””โ”€โ”€ stats/              # Usage statistics
โ”‚       โ””โ”€โ”€ usage.json
โ””โ”€โ”€ README.md               # Your project documentation

๐Ÿ” Privacy & Security

  • Local-First: All scanning happens on your machine
  • Encrypted Storage: API keys and sensitive data are encrypted using hardware-bound keys
  • Privacy-Preserving: Usage tracking uses SHA256 hashes, not actual code
  • No Telemetry: KYLO doesn't send your code anywhere (unless you explicitly use AI features)

๐Ÿค Contributing

Contributions are welcome! Here's how:

  1. Fork the repository
  2. Create a feature branch (git checkout -b feature/amazing-feature)
  3. Commit your changes (git commit -m 'Add amazing feature')
  4. Push to the branch (git push origin feature/amazing-feature)
  5. Open a Pull Request

๐Ÿ“ Development

Setup

git clone https://github.com/yourusername/kylo.git
cd kylo
python -m venv .venv
source .venv/bin/activate  # On Windows: .venv\Scripts\activate
pip install -r requirements.txt
pip install -e .

Running Tests

python tests/run_tests.py

๐Ÿ—บ๏ธ Roadmap

  • Multi-language support (JavaScript, Go, Rust, TypeScript)
  • CI/CD integrations (GitHub Actions, GitLab CI, CircleCI)
  • Live monitoring dashboard
  • AI-powered deep analysis (via optional proxy service)
  • Custom rule definitions
  • Team collaboration features

๐Ÿ“„ License

This project is licensed under the MIT License - see the LICENSE file for details.

๐Ÿ™ Acknowledgments

๐Ÿ’ฌ Support

Ship safer code, faster.

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

kylo-1.0.0.tar.gz (23.4 kB view details)

Uploaded Source

Built Distribution

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

kylo-1.0.0-py3-none-any.whl (23.5 kB view details)

Uploaded Python 3

File details

Details for the file kylo-1.0.0.tar.gz.

File metadata

  • Download URL: kylo-1.0.0.tar.gz
  • Upload date:
  • Size: 23.4 kB
  • Tags: Source
  • Uploaded using Trusted Publishing? No
  • Uploaded via: twine/6.2.0 CPython/3.14.0

File hashes

Hashes for kylo-1.0.0.tar.gz
Algorithm Hash digest
SHA256 14cb893eb44c8f44c071adbf198e0bdc2370801d179693a54980abbda69b4081
MD5 4675c39cb119975885a13e4f6614835b
BLAKE2b-256 a8ad0be09915c9041d32f2b51cd217f957995d9e18ed12a64da23c788a00f7ac

See more details on using hashes here.

File details

Details for the file kylo-1.0.0-py3-none-any.whl.

File metadata

  • Download URL: kylo-1.0.0-py3-none-any.whl
  • Upload date:
  • Size: 23.5 kB
  • Tags: Python 3
  • Uploaded using Trusted Publishing? No
  • Uploaded via: twine/6.2.0 CPython/3.14.0

File hashes

Hashes for kylo-1.0.0-py3-none-any.whl
Algorithm Hash digest
SHA256 485060eb671f8d061a2eaa3a7dea36d765c687f5e0f30482dc2e16c4e06101b2
MD5 c7db2877faea7dd7c43e0ab4b3f22911
BLAKE2b-256 4af971f1413a6786bbce160366be0a5b532277037539a8778ddaa795fda7a340

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