Skip to content

Commit

Permalink
first commit
Browse files Browse the repository at this point in the history
  • Loading branch information
anupammaurya6767 committed Nov 12, 2023
0 parents commit 486c1d3
Show file tree
Hide file tree
Showing 63 changed files with 4,069 additions and 0 deletions.
28 changes: 28 additions & 0 deletions .github/workflows/test.yml
Original file line number Diff line number Diff line change
@@ -0,0 +1,28 @@
name: Run Tests

on:
push:
branches:
- main

jobs:
test:
runs-on: ubuntu-latest

steps:
- name: Checkout repository
uses: actions/checkout@v2

- name: Set up Python
uses: actions/setup-python@v2
with:
python-version: 3.11

- name: Install dependencies
run: |
python -m pip install --upgrade pip
pip install -r requirements.txt # Adjust as needed
- name: Run tests
run: |
pytest test_tanji.py
2 changes: 2 additions & 0 deletions .gitignore
Original file line number Diff line number Diff line change
@@ -0,0 +1,2 @@
/.pytest_cache
/venv
20 changes: 20 additions & 0 deletions Makefile
Original file line number Diff line number Diff line change
@@ -0,0 +1,20 @@
# Minimal makefile for Sphinx documentation
#

# You can set these variables from the command line, and also
# from the environment for the first two.
SPHINXOPTS ?=
SPHINXBUILD ?= sphinx-build
SOURCEDIR = source
BUILDDIR = build

# Put it first so that "make" without argument is like "make help".
help:
@$(SPHINXBUILD) -M help "$(SOURCEDIR)" "$(BUILDDIR)" $(SPHINXOPTS) $(O)

.PHONY: help Makefile

# Catch-all target: route all unknown targets to Sphinx using the new
# "make mode" option. $(O) is meant as a shortcut for $(SPHINXOPTS).
%: Makefile
@$(SPHINXBUILD) -M $@ "$(SOURCEDIR)" "$(BUILDDIR)" $(SPHINXOPTS) $(O)
51 changes: 51 additions & 0 deletions README.md
Original file line number Diff line number Diff line change
@@ -0,0 +1,51 @@
# Tanji Encryption Library 👩‍💻🔐

Tanji is a Python encryption library that provides a secure and flexible solution for encrypting and decrypting messages. It leverages both symmetric and asymmetric encryption techniques to ensure the confidentiality and integrity of your data.

## Features 🚀

- **Symmetric Encryption:** Utilizes the Advanced Encryption Standard (AES) algorithm for symmetric key encryption.
- **Asymmetric Encryption:** Employs RSA algorithm for secure asymmetric key encryption.
- **Base64 Encoding:** Efficiently encodes encrypted data using Base64 for safe transmission.
- **Key Pair Generation:** Automatically generates RSA key pairs for secure communication.
- **Random Initialization Vectors (IV):** Uses random IVs to enhance security.
- **Ease of Use:** Simple and straightforward interface for encrypting and decrypting messages.

## How Tanji Differs 🤔

- **Robust Security:** Tanji prioritizes the security of your data by combining symmetric and asymmetric encryption methods.
- **Key Pair Generation:** Automatically generates and manages RSA key pairs, simplifying the encryption process.
- **Dynamic Initialization Vectors:** Randomly generated IVs for each encryption enhance the resistance against cryptographic attacks.
- **Base64 Encoding:** Encoded data ensures compatibility and safe transmission across different systems.
- **Developer-Friendly:** Designed to be user-friendly and easily integrated into various Python projects.

## Getting Started 🏁

1. Install Tanji:

```bash
pip install tanji
```

2. Use Tanji in your Python project:

```python
from tanji import Tanji
# Example Usage
tanji = Tanji()
encrypted_message, ciphertext = tanji.encrypt_message("Hello, Tanji!")
decrypted_message = tanji.decrypt_message(encrypted_message, ciphertext)
print("Original Message:", "Hello, Tanji!")
print("Encrypted Message:", encrypted_message)
print("Decrypted Message:", decrypted_message)
```

## Contributing 🤝

Contributions are welcome! Feel free to submit issues or pull requests.

## License 📄

This project is licensed under the MIT License - see the [LICENSE](LICENSE) file for details.
4 changes: 4 additions & 0 deletions build/.buildinfo
Original file line number Diff line number Diff line change
@@ -0,0 +1,4 @@
# Sphinx build info version 1
# This file hashes the configuration used when building these files. When it is not found, a full rebuild will be done.
config: 009433cc63dc96753b2cf1a0b5040b49
tags: 645f666f9bcd5a90fca523b33c5a78b7
Binary file added build/.doctrees/environment.pickle
Binary file not shown.
Binary file added build/.doctrees/index.doctree
Binary file not shown.
Binary file added build/.doctrees/modules/asymmetric.doctree
Binary file not shown.
Binary file added build/.doctrees/modules/symmetric.doctree
Binary file not shown.
Binary file added build/.doctrees/modules/tanji.doctree
Binary file not shown.
Binary file added build/.doctrees/readme.doctree
Binary file not shown.
18 changes: 18 additions & 0 deletions build/_sources/index.rst.txt
Original file line number Diff line number Diff line change
@@ -0,0 +1,18 @@
Welcome to Tanji's Documentation
===============================

.. toctree::
:maxdepth: 2
:caption: Contents:

readme
modules/tanji
modules/symmetric
modules/asymmetric

Indices and tables
==================

* :ref:`genindex`
* :ref:`modindex`
* :ref:`search`
7 changes: 7 additions & 0 deletions build/_sources/modules/asymmetric.rst.txt
Original file line number Diff line number Diff line change
@@ -0,0 +1,7 @@
Asymmetric Module
==================

.. automodule:: tanji.asymmetric
:members:
:undoc-members:
:show-inheritance:
7 changes: 7 additions & 0 deletions build/_sources/modules/symmetric.rst.txt
Original file line number Diff line number Diff line change
@@ -0,0 +1,7 @@
Symmetric Module
================

.. automodule:: tanji.symmetric
:members:
:undoc-members:
:show-inheritance:
7 changes: 7 additions & 0 deletions build/_sources/modules/tanji.rst.txt
Original file line number Diff line number Diff line change
@@ -0,0 +1,7 @@
Tanji Module
=============

.. automodule:: tanji.tanji
:members:
:undoc-members:
:show-inheritance:
4 changes: 4 additions & 0 deletions build/_sources/readme.rst.txt
Original file line number Diff line number Diff line change
@@ -0,0 +1,4 @@
Readme
======

.. include:: ../README.md
Loading

0 comments on commit 486c1d3

Please sign in to comment.