# BluffPadding Cipher Algorithm
🔒 **BluffPadding Cipher Algorithm** is a Python-based encryption tool that combines random prefixes and suffixes with character shifts to provide enhanced text obfuscation. Ideal for lightweight data security. 🛡️
## Features
- Generates random prefixes and suffixes for added security
- Shifts characters by a random value for encoding
- Simple encryption and decryption functions
## Installation
You can install the `bluffpadding-cypher-algorithm` package from PyPI using pip:
```sh
pip install bluffpaddingcypher
```
## Usage
Here is how you can use the bluffpaddingcypher package to encrypt and decrypt text:
- Encrypting Text :
```python
from bluffpaddingcypher.cypher import encrypt
text = "Hello, World!"
encrypted_text = encrypt(text)
print("Encrypted:", encrypted_text)
```
- Decrypting Text :
```python
from bluffpaddingcypher.cypher import decrypt
encrypted_text = """MI{~rCb6o'PS\ZfRovvy6*ay|vn+)S'h,3YvNs*=]yz,c{]SWeC5^.:syM|Xt}^$I(G9%W:NL]b?VTLZ+-OY3_$},Lf?*p<=L5F0T6S~'Bkhv82S""" # Use the output from the encryption step
decrypted_text = decrypt(encrypted_text)
print("Decrypted:", decrypted_text)
```
- Example :
```python
from bluffpaddingcypher.cypher import encrypt, decrypt
# Original text
text = "Hello, World!"
# Encrypt the text
encrypted_text = encrypt(text)
print("Encrypted Text:", encrypted_text)
# Decrypt the text
decrypted_text = decrypt(encrypted_text)
print("Decrypted Text:", decrypted_text)
```
- Expected Output :
```python
Encrypted: =Hzw@<UXf!x{9Rovvy6*ay|vn+VJx!RIG@XGZ)'af&>pbG8/O|q6B$YxP"\nP*fbI)/xUd$pf!do2
Decrypted: Hello, World!
```
# How It Works :
1. Encrypt Function
- Generates a random prefix and suffix of random lengths (between 2 and 100 characters).
- Shifts each character in the input text by a random value (between 1 and 10).
- Combines the prefix, shifted text, suffix, and the shift value into the final encoded text.
2. Decrypt Function
- Extracts the prefix length and removes the prefix.
- Extracts the suffix length and removes the suffix.
- Extracts the shift value.
- Reverses the character shift to retrieve the original text.
# Contribution :
Contributions are welcome! Please open an issue or submit a pull request on GitHub [Repository](https://github.com/neuqs90/bluffpadding-cypher-algorithm.git).
# Author :
Name : Bhavya Padaliya
Raw data
{
"_id": null,
"home_page": "https://github.com/neuqs90/bluffpadding-cypher-algorithm.git",
"name": "bluffpaddingcypher",
"maintainer": null,
"docs_url": null,
"requires_python": ">=3.6",
"maintainer_email": null,
"keywords": "encryption, cipher, obfuscation, security",
"author": "Bhavya Padaliya",
"author_email": null,
"download_url": "https://files.pythonhosted.org/packages/a7/81/36f4d1c8799227464d0859099163ed13c845686eb2d2d2fe4368d7a2d958/bluffpaddingcypher-1.0.tar.gz",
"platform": null,
"description": "# BluffPadding Cipher Algorithm\r\n\r\n\ud83d\udd12 **BluffPadding Cipher Algorithm** is a Python-based encryption tool that combines random prefixes and suffixes with character shifts to provide enhanced text obfuscation. Ideal for lightweight data security. \ud83d\udee1\ufe0f\r\n\r\n## Features\r\n\r\n- Generates random prefixes and suffixes for added security\r\n- Shifts characters by a random value for encoding\r\n- Simple encryption and decryption functions\r\n\r\n## Installation\r\n\r\nYou can install the `bluffpadding-cypher-algorithm` package from PyPI using pip:\r\n\r\n```sh\r\npip install bluffpaddingcypher\r\n```\r\n\r\n## Usage\r\n\r\nHere is how you can use the bluffpaddingcypher package to encrypt and decrypt text:\r\n\r\n- Encrypting Text :\r\n\r\n ```python\r\n from bluffpaddingcypher.cypher import encrypt\r\n\r\n text = \"Hello, World!\"\r\n encrypted_text = encrypt(text)\r\n print(\"Encrypted:\", encrypted_text)\r\n ```\r\n- Decrypting Text : \r\n\r\n ```python\r\n from bluffpaddingcypher.cypher import decrypt\r\n\r\n encrypted_text = \"\"\"\u000fMI{~rCb6o'PS\\ZfRovvy6*ay|vn+)S'h,3YvNs*=]yz,c{]SWeC5^.:syM|Xt}^$I(G9%W:NL]b?VTLZ+-OY3_$},Lf?*p<=L5F0T6S~'Bkhv82S\"\"\" # Use the output from the encryption step\r\n decrypted_text = decrypt(encrypted_text)\r\n print(\"Decrypted:\", decrypted_text)\r\n ```\r\n\r\n- Example : \r\n\r\n ```python\r\n from bluffpaddingcypher.cypher import encrypt, decrypt\r\n\r\n # Original text\r\n text = \"Hello, World!\"\r\n\r\n # Encrypt the text\r\n encrypted_text = encrypt(text)\r\n print(\"Encrypted Text:\", encrypted_text)\r\n\r\n # Decrypt the text\r\n decrypted_text = decrypt(encrypted_text)\r\n print(\"Decrypted Text:\", decrypted_text)\r\n ```\r\n\r\n- Expected Output : \r\n\r\n ```python\r\n Encrypted: =Hzw@<UXf!x{9Rovvy6*ay|vn+VJx!RIG@XGZ)'af&>pbG8/O|q6B$YxP\"\\nP*fbI)/xUd$pf!do2\r\n\r\n Decrypted: Hello, World!\r\n ```\r\n\r\n# How It Works :\r\n\r\n1. Encrypt Function\r\n\r\n - Generates a random prefix and suffix of random lengths (between 2 and 100 characters).\r\n - Shifts each character in the input text by a random value (between 1 and 10).\r\n - Combines the prefix, shifted text, suffix, and the shift value into the final encoded text.\r\n\r\n2. Decrypt Function\r\n\r\n - Extracts the prefix length and removes the prefix.\r\n - Extracts the suffix length and removes the suffix.\r\n - Extracts the shift value.\r\n - Reverses the character shift to retrieve the original text.\r\n\r\n# Contribution : \r\n\r\nContributions are welcome! Please open an issue or submit a pull request on GitHub [Repository](https://github.com/neuqs90/bluffpadding-cypher-algorithm.git).\r\n\r\n# Author : \r\n\r\nName : Bhavya Padaliya\r\n",
"bugtrack_url": null,
"license": "MIT",
"summary": "BluffPadding Cipher Algorithm: A Python-based encryption tool combining random prefixes/suffixes with character shifts for enhanced text obfuscation.",
"version": "1.0",
"project_urls": {
"Homepage": "https://github.com/neuqs90/bluffpadding-cypher-algorithm.git"
},
"split_keywords": [
"encryption",
" cipher",
" obfuscation",
" security"
],
"urls": [
{
"comment_text": "",
"digests": {
"blake2b_256": "a78136f4d1c8799227464d0859099163ed13c845686eb2d2d2fe4368d7a2d958",
"md5": "809947c5505a566eb7fddee1d9159d52",
"sha256": "1ef2fd58e9e3e974c41d0ca4fb1ccc9e90fd3956b4c985cfea4497f6166a0417"
},
"downloads": -1,
"filename": "bluffpaddingcypher-1.0.tar.gz",
"has_sig": false,
"md5_digest": "809947c5505a566eb7fddee1d9159d52",
"packagetype": "sdist",
"python_version": "source",
"requires_python": ">=3.6",
"size": 2915,
"upload_time": "2024-05-29T03:02:15",
"upload_time_iso_8601": "2024-05-29T03:02:15.068830Z",
"url": "https://files.pythonhosted.org/packages/a7/81/36f4d1c8799227464d0859099163ed13c845686eb2d2d2fe4368d7a2d958/bluffpaddingcypher-1.0.tar.gz",
"yanked": false,
"yanked_reason": null
}
],
"upload_time": "2024-05-29 03:02:15",
"github": true,
"gitlab": false,
"bitbucket": false,
"codeberg": false,
"github_user": "neuqs90",
"github_project": "bluffpadding-cypher-algorithm",
"travis_ci": false,
"coveralls": false,
"github_actions": false,
"lcname": "bluffpaddingcypher"
}