RACHUS


NameRACHUS JSON
Version 0.1.0 PyPI version JSON
download
home_pageNone
SummaryA custom encryption library that compresses data
upload_time2024-05-21 01:48:35
maintainerNone
docs_urlNone
authorRey
requires_python>=3.6
licenseNone
keywords
VCS
bugtrack_url
requirements No requirements were recorded.
Travis-CI No Travis.
coveralls test coverage No coveralls.
            
# ARCHUS

A custom encryption library that compresses data by mapping every 2 bits to a single character, effectively reducing the size of the binary representation.
## Installation

You can install the package via pip:

```sh
pip install rachus
```
# Usage 
## Encrypting Text
To encrypt a text string, use the encrypt_text function from the RACHUS package. This function returns the original binary representation of the text and the encrypted string.
```
from rachus import encrypt_text

s = "he"
binary_text, encrypted_text = encrypt_text(s, r=3)
print(f"Original text: {s}")
print(f"Original binary: {binary_text}")
print(f"Encrypted custom: {encrypted_text}")
```
## Decrypting Text
To decrypt an encrypted string, use the decrypt_text function from the RACHUS package. This function returns the binary representation of the encrypted text and the decrypted original text.
```
from rachus import decrypt_text

encrypted_text = '1!"#$'
binary_text, decrypted_text = decrypt_text(encrypted_text, r=3)
print(f"Encrypted text: {encrypted_text}")
print(f"Decrypted binary: {binary_text}")
print(f"Decrypted text: {decrypted_text}")
```
# How It Works
## Encryption 
1. **Text to Binary Conversion**: The text is converted to its binary representation.
Permutation: The binary string is permuted randomly multiple times.
Mapping: Each pair of bits is mapped to a specific character according to a predefined mapping.

2. **Permutation**: The binary string is permuted randomly multiple times.

3. **Mapping**: Each pair of bits is mapped to a specific character according to a predefined mapping.
## Decryption 
1. **Reverse Mapping**: Each character in the encrypted string is mapped back to its original pair of bits.

2. **Reverse Permutation**: The binary string is permuted back to its original order (assuming the same permutation was used in reverse).

3. **Binary to Text Conversion**: The binary string is converted back to the original text.

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

# Author 
Rey - rey@cock.lu

            

Raw data

            {
    "_id": null,
    "home_page": null,
    "name": "RACHUS",
    "maintainer": null,
    "docs_url": null,
    "requires_python": ">=3.6",
    "maintainer_email": null,
    "keywords": null,
    "author": "Rey",
    "author_email": "rey@cock.lu",
    "download_url": "https://files.pythonhosted.org/packages/26/05/76b158f08b72473c7a76c7745e746777e85e728eac9a7ba7128a1510b273/rachus-0.1.0.tar.gz",
    "platform": null,
    "description": "\r\n# ARCHUS\r\n\r\nA custom encryption library that compresses data by mapping every 2 bits to a single character, effectively reducing the size of the binary representation.\r\n## Installation\r\n\r\nYou can install the package via pip:\r\n\r\n```sh\r\npip install rachus\r\n```\r\n# Usage \r\n## Encrypting Text\r\nTo encrypt a text string, use the encrypt_text function from the RACHUS package. This function returns the original binary representation of the text and the encrypted string.\r\n```\r\nfrom rachus import encrypt_text\r\n\r\ns = \"he\"\r\nbinary_text, encrypted_text = encrypt_text(s, r=3)\r\nprint(f\"Original text: {s}\")\r\nprint(f\"Original binary: {binary_text}\")\r\nprint(f\"Encrypted custom: {encrypted_text}\")\r\n```\r\n## Decrypting Text\r\nTo decrypt an encrypted string, use the decrypt_text function from the RACHUS package. This function returns the binary representation of the encrypted text and the decrypted original text.\r\n```\r\nfrom rachus import decrypt_text\r\n\r\nencrypted_text = '1!\"#$'\r\nbinary_text, decrypted_text = decrypt_text(encrypted_text, r=3)\r\nprint(f\"Encrypted text: {encrypted_text}\")\r\nprint(f\"Decrypted binary: {binary_text}\")\r\nprint(f\"Decrypted text: {decrypted_text}\")\r\n```\r\n# How It Works\r\n## Encryption \r\n1. **Text to Binary Conversion**: The text is converted to its binary representation.\r\nPermutation: The binary string is permuted randomly multiple times.\r\nMapping: Each pair of bits is mapped to a specific character according to a predefined mapping.\r\n\r\n2. **Permutation**: The binary string is permuted randomly multiple times.\r\n\r\n3. **Mapping**: Each pair of bits is mapped to a specific character according to a predefined mapping.\r\n## Decryption \r\n1. **Reverse Mapping**: Each character in the encrypted string is mapped back to its original pair of bits.\r\n\r\n2. **Reverse Permutation**: The binary string is permuted back to its original order (assuming the same permutation was used in reverse).\r\n\r\n3. **Binary to Text Conversion**: The binary string is converted back to the original text.\r\n\r\n# License\r\nThis project is licensed under the MIT License - see the LICENSE file for details.\r\n\r\n# Author \r\nRey - rey@cock.lu\r\n",
    "bugtrack_url": null,
    "license": null,
    "summary": "A custom encryption library that compresses data",
    "version": "0.1.0",
    "project_urls": null,
    "split_keywords": [],
    "urls": [
        {
            "comment_text": "",
            "digests": {
                "blake2b_256": "eb1430bb8048ae1448517048f99020277362322ff8aa17438a9f04c7011d9ac5",
                "md5": "a9e7a39c555dc2f515361a2983541b75",
                "sha256": "5a0e37c0e2191d76e4cc4a780b42b04c0e6525242e146649913d81edfcc24e1a"
            },
            "downloads": -1,
            "filename": "RACHUS-0.1.0-py3-none-any.whl",
            "has_sig": false,
            "md5_digest": "a9e7a39c555dc2f515361a2983541b75",
            "packagetype": "bdist_wheel",
            "python_version": "py3",
            "requires_python": ">=3.6",
            "size": 2675,
            "upload_time": "2024-05-21T01:48:33",
            "upload_time_iso_8601": "2024-05-21T01:48:33.747159Z",
            "url": "https://files.pythonhosted.org/packages/eb/14/30bb8048ae1448517048f99020277362322ff8aa17438a9f04c7011d9ac5/RACHUS-0.1.0-py3-none-any.whl",
            "yanked": false,
            "yanked_reason": null
        },
        {
            "comment_text": "",
            "digests": {
                "blake2b_256": "260576b158f08b72473c7a76c7745e746777e85e728eac9a7ba7128a1510b273",
                "md5": "1032e8abca0a05a39ebad18e6bed8c44",
                "sha256": "4d0baa7aa056f70631d95477d6c21b1c737ba02eec5348b2b9e35a5e2f1426c4"
            },
            "downloads": -1,
            "filename": "rachus-0.1.0.tar.gz",
            "has_sig": false,
            "md5_digest": "1032e8abca0a05a39ebad18e6bed8c44",
            "packagetype": "sdist",
            "python_version": "source",
            "requires_python": ">=3.6",
            "size": 2515,
            "upload_time": "2024-05-21T01:48:35",
            "upload_time_iso_8601": "2024-05-21T01:48:35.616305Z",
            "url": "https://files.pythonhosted.org/packages/26/05/76b158f08b72473c7a76c7745e746777e85e728eac9a7ba7128a1510b273/rachus-0.1.0.tar.gz",
            "yanked": false,
            "yanked_reason": null
        }
    ],
    "upload_time": "2024-05-21 01:48:35",
    "github": false,
    "gitlab": false,
    "bitbucket": false,
    "codeberg": false,
    "lcname": "rachus"
}
        
Rey
Elapsed time: 0.26903s