Metadata-Version: 2.1
Name: langsec
Version: 0.0.1
Summary: Security framework for LLM-generated SQL queries
Home-page: https://github.com/langsec-ai/langsec
Author: LangSec
Author-email: dev@lang-sec.com
Classifier: Development Status :: 3 - Alpha
Classifier: Intended Audience :: Developers
Classifier: License :: OSI Approved :: Apache Software License
Classifier: Programming Language :: Python :: 3
Classifier: Programming Language :: Python :: 3.8
Classifier: Programming Language :: Python :: 3.9
Classifier: Programming Language :: Python :: 3.10
Classifier: Programming Language :: Python :: 3.11
Classifier: Programming Language :: Python :: 3.12
Requires-Python: >=3.8
Description-Content-Type: text/markdown
License-File: LICENSE
Requires-Dist: sqlglot>=11.5.0
Requires-Dist: pydantic>=2.0.0
Requires-Dist: typing-extensions>=4.0.0
Provides-Extra: dev
Requires-Dist: pytest>=7.0.0; extra == "dev"
Requires-Dist: black>=23.0.0; extra == "dev"
Requires-Dist: mypy>=1.0.0; extra == "dev"
Requires-Dist: isort>=5.0.0; extra == "dev"

[![Version](https://img.shields.io/github/v/release/langsec-ai/langsec)](https://github.com/langsec-ai/langsec/releases)
[![License](https://img.shields.io/github/license/langsec-ai/langsec)](https://img.shields.io/github/license/langsec-ai/langsec)
[![Stars](https://img.shields.io/github/stars/langsec-ai/langsec?style=social)](https://github.com/langsec-ai/langsec/stargazers)


# LangSec: A Security Framework for Text-to-SQL
A security framework for validating and securing LLM-generated SQL queries. LangSec helps prevent SQL injection, unauthorized access, and other security vulnerabilities when working with language models that generate SQL.

![Text To SQL Abuse](https://raw.githubusercontent.com/langsec-ai/langsec/main/assets/langsecgif.gif)

Demonstration of making a malicious query using [Vanna](https://github.com/vanna-ai/vanna).
LangSec helps prevent such attacks by validating generated queries against a security schema.

![LangSec](https://raw.githubusercontent.com/langsec-ai/langsec/main/assets/image.png)

## Installation

```bash
pip install langsec
```

## Documentation
For a detailed guide on how to use LangSec, please refer to the [documentation](https://docs.lang-sec.com).

## Contributing

Contributions are welcome! Please feel free to submit a Pull Request.

## License

APACHE 2.0 © 2024 LangSec

## Support

For issues and feature requests, please create an issue on GitHub or contact dev@lang-sec.com.
