Metadata-Version: 2.1
Name: herbal
Version: 0.1.0
Summary: Python package for the Tiny Encryption Algorithm (TEA).
Home-page: https://gitlab.com/lunardev/herbal
License: MIT
Keywords: python,python3,block cipher,cryptography,tiny encryption algorithm,tea
Author: T. Rodriguez
Requires-Python: >=3.9,<4.0
Classifier: Development Status :: 1 - Planning
Classifier: Environment :: Console
Classifier: Intended Audience :: Developers
Classifier: Intended Audience :: End Users/Desktop
Classifier: License :: OSI Approved :: MIT License
Classifier: Natural Language :: English
Classifier: Operating System :: MacOS :: MacOS X
Classifier: Operating System :: Microsoft :: Windows :: Windows 10
Classifier: Operating System :: Microsoft :: Windows :: Windows 11
Classifier: Operating System :: POSIX :: Linux
Classifier: Programming Language :: Python :: 3
Classifier: Programming Language :: Python :: 3.9
Classifier: Programming Language :: Python :: 3.10
Classifier: Programming Language :: Python :: 3.11
Classifier: Programming Language :: Python :: 3.12
Classifier: Programming Language :: Python :: Implementation :: CPython
Classifier: Topic :: Security :: Cryptography
Classifier: Topic :: Utilities
Classifier: Typing :: Typed
Project-URL: Repository, https://gitlab.com/lunardev/herbal
Description-Content-Type: text/markdown

<h1 align="center">
Herbal TEA

[![Gitlab](https://img.shields.io/badge/gitlab-%23181717.svg?logo=gitlab)](https://gitlab.com/lunardev/herbal)
[![MIT License](https://img.shields.io/badge/license-MIT-blue.svg)](./LICENSE)
[![Python Version](https://img.shields.io/badge/cpython-3.9%20|%203.10%20|%203.11%20|%203.12-blue.svg)](https://python.org)
[![Code Style](https://img.shields.io/badge/code%20style-black-000000.svg)](https://gothub.no-logs.com/psf/black)
</h1>

### Python package for the Tiny Encryption Algorithm (TEA).
> The Tiny Encryption Algorithm (TEA) is a simple and efficient block cipher algorithm.

## Features
- Supports Python 3.9+.
- Simple Python API.
- No third-party dependencies.
- Uses [scrypt](https://wikipedia.org/wiki/Scrypt) to derive encryption keys.

## Installation
```shell
python3 -m pip install git+https://gitlab.com/lunardev/herbal.git
```

## Usage
```python
import herbal

password = "secret"
cipher = herbal.encrypt("example message!", password=password)
plain = herbal.decrypt(cipher, password=password)
print(plain)  # example message!
```

## To-Do
- [x] Implement the Tiny Encryption Algorithm.
- [ ] Pad input to allow for encoding data of any length.
- [ ] Implement extended algorithms.
  - [ ] XTEA
  - [ ] XXTEA
- [ ] Add unit tests.
  - [ ] GitLab CI pipeline
  - [ ] Code coverage
- [ ] Write documentation.
- [ ] Upload project to the [Python Package Index](https://pypi.org).

## References

1. Wheeler, David J.; Needham, Roger M. *TEA, a Tiny Encryption Algorithm*. 16 Dec. 1994 https://link.springer.com/content/pdf/10.1007/3-540-60590-8_29.pdf.
2. Shepherd, Simon. *The Tiny Encryption Algorithm (TEA)*. https://www.tayloredge.com/reference/Mathematics/TEA-XTEA.pdf.
3. Andem, Vikram Reddy. *A Cryptanalysis of the Tiny Encryption Algorithm*, 2003, https://tayloredge.com/reference/Mathematics/VRAndem.pdf.
4. Wikipedia. *Tiny Encryption Algorithm*, 6 Nov. 2023, https://wikipedia.org/wiki/Tiny_Encryption_Algorithm.
5. Fandom. *Tiny Encryption Algorithm*, 24 Sept. 2010, https://antifandom.com/cryptography/wiki/Tiny_Encryption_Algorithm.

## License

This project is licensed under the [MIT License](./LICENSE). Copyright (c) 2024.

