codecipher


Namecodecipher JSON
Version 1.4.5 PyPI version JSON
download
home_pagehttps://electux.github.io/codecipher
SummaryPython Cipher Utilities
upload_time2024-01-05 18:12:15
maintainer
docs_urlNone
authorVladimir Roncevic
requires_python>=3.10
licenseGPL 2024 Free software to use and distributed it.
keywords cipher encryption decryption cryptology cryptography
VCS
bugtrack_url
requirements No requirements were recorded.
Travis-CI No Travis.
coveralls test coverage No coveralls.
            <img align="right" src="https://raw.githubusercontent.com/electux/codecipher/dev/docs/codecipher_logo.png" width="25%">

# CODECipher

**codecipher** is package for cipher utilities.

Developed in **[python](https://www.python.org/)** code.

The README is used to introduce the modules and provide instructions on
how to install the modules, any machine dependencies it may have and any
other information that should be provided before the modules are installed.

[![codecipher python checker](https://github.com/electux/codecipher/actions/workflows/codecipher_python_checker.yml/badge.svg)](https://github.com/electux/codecipher/actions/workflows/codecipher_python_checker.yml) [![codecipher package checker](https://github.com/electux/codecipher/actions/workflows/codecipher_package_checker.yml/badge.svg)](https://github.com/electux/codecipher/actions/workflows/codecipher_package.yml) [![GitHub issues open](https://img.shields.io/github/issues/electux/codecipher.svg)](https://github.com/electux/codecipher/issues) [![GitHub contributors](https://img.shields.io/github/contributors/electux/codecipher.svg)](https://github.com/electux/codecipher/graphs/contributors)

<!-- START doctoc generated TOC please keep comment here to allow auto update -->
<!-- DON'T EDIT THIS SECTION, INSTEAD RE-RUN doctoc TO UPDATE -->
**Table of Contents**

- [Installation](#installation)
    - [Install using pip](#install-using-pip)
    - [Install using build](#install-using-build)
    - [Install using py setup](#install-using-py-setup)
    - [Install using docker](#install-using-docker)
- [Dependencies](#dependencies)
- [Usage](#usage)
- [Package structure](#package-structure)
- [Docs](#docs)
- [Contributing](#contributing)
- [Copyright and Licence](#copyright-and-licence)

<!-- END doctoc generated TOC please keep comment here to allow auto update -->

### Installation

Used next development environment

Used next development environment

![debian linux os](https://raw.githubusercontent.com/electux/codecipher/dev/docs/debtux.png)

[![codecipher python3 build](https://github.com/electux/codecipher/actions/workflows/codecipher_python3_build.yml/badge.svg)](https://github.com/electux/codecipher/actions/workflows/codecipher_python3_build.yml)

Currently there are three ways to install package
* Install process based on using pip mechanism
* Install process based on build mechanism
* Install process based on setup.py mechanism
* Install process based on docker mechanism

##### Install using pip

**codecipher** is located at **[pypi.org](https://pypi.org/project/codecipher/)**.

You can install by using pip

```bash
# python3
pip3 install codecipher
```

##### Install using build

Navigate to **[release page](https://github.com/electux/codecipher/releases)** download and extract release archive.

To install **codecipher**, run

```bash
tar xvzf codecipher-x.y.z.tar.gz
cd codecipher-x.y.z
# python3
wget https://bootstrap.pypa.io/get-pip.py
python3 get-pip.py 
python3 -m pip install --upgrade setuptools
python3 -m pip install --upgrade pip
python3 -m pip install --upgrade build
pip3 install -r requirements.txt
python3 -m build --no-isolation --wheel
pip3 install codecipher-x.y.z-py3-none-any.whl
rm -f get-pip.py
```

##### Install using py setup

Navigate to **[release page](https://github.com/electux/codecipher/releases)** download and extract release archive.

To install **codecipher**, locate and run setup.py with arguments

```bash
tar xvzf codecipher-x.y.z.tar.gz
cd codecipher-x.y.z
# python3
pip3 install -r requirements.txt
python3 setup.py install_lib
python3 setup.py install_egg_info
```

##### Install using docker

You can use Dockerfile to create image/container.

### Dependencies

**codecipher** requires other modules and libraries (Python 3.x)
* None

### Usage

```python
from codecipher.a1z52n62 import A1z52N62
from codecipher.atbs import AlephTawBetShin
from codecipher.b64 import B64
from codecipher.caesar import Caesar
from codecipher.vigenere import Vigenere
from codecipher.vernam import Vernam

print("A1z52N62 cipher")
cipher = A1z52N62()
data = "More Human Than Human01 Is Our Motto"
# encoding data
cipher.encode(data)
# encoded data
print(cipher.encode_data)
# decoding data
cipher.decode(cipher.encode_data)
# decoded data
print(cipher.decode_data)
print(50*'=')

print("AlephTawBetShin cipher")
cipher = AlephTawBetShin()
data = "More Human Than Human01 Is Our Motto"
# encoding data
cipher.encode(data)
# encoded data
print(cipher.encode_data)
# decoding data
cipher.decode(cipher.encode_data)
# decoded data
print(cipher.decode_data)
print(50*'=')

print("B64 cipher")
cipher = B64()
data = "More Human Than Human01 Is Our Motto"
# encoding data
cipher.encode(data)
# encoded data
print(cipher.encode_data)
# decoding data
cipher.decode(cipher.encode_data)
# decoded data
print(cipher.decode_data)
print(50*'=')

print("Caesar cipher")
cipher = Caesar()
data = "More Human Than Human01 Is Our Motto"
# encoding data
cipher.encode(data, 3)
# encoded data
print(cipher.encode_data)
# decoding data
cipher.decode(cipher.encode_data, 3)
# decoded data
print(cipher.decode_data)
print(50*'=')

print("Vigenere cipher")
cipher = Vigenere()
data = "More Human Than Human01 Is Our Motto"
cipher.data_len = len(data)
cipher.key = "AYUSH"
cipher.generate_key()
# encoding data
cipher.encode(data, cipher.key)
# encoded data
print(cipher.encode_data)
# decoding data
cipher.decode(cipher.encode_data, cipher.key)
# decoded data
print(cipher.decode_data)
print(50*'=')

print("Vernam cipher")
cipher = Vernam()
data = "More Human Than Human01 Is Our Motto"
# encoding data
cipher.encode(data, "randomrandomrandom")
# encoded data
print(cipher.encode_data)
# decoding data
cipher.decode(cipher.encode_data, "randomrandomrandom")
# decoded data
print(cipher.decode_data)
print(50*'=')
```

### Package structure

**codecipher** is based on OOP.

Package structure

```bash
    codecipher/
        ├── a1z52n62/
        │   ├── decode.py
        │   ├── encode.py
        │   └── __init__.py
        ├── atbs/
        │   ├── decode.py
        │   ├── encode.py
        │   ├── __init__.py
        │   └── lookup_table.py
        ├── b64/
        │   ├── decode.py
        │   ├── encode.py
        │   └── __init__.py
        ├── caesar/
        │   ├── decode.py
        │   ├── encode.py
        │   └── __init__.py
        ├── __init__.py
        ├── vernam/
        │   ├── decode.py
        │   ├── encode.py
        │   └── __init__.py
        └── vigenere/
            ├── decode.py
            ├── encode.py
            ├── __init__.py
            ├── key_generator.py
            └── lookup_table.py
```

### Docs

[![documentation status](https://readthedocs.org/projects/codecipher/badge/?version=latest)](https://codecipher.readthedocs.io/en/latest/?badge=latest)

More documentation and info at

* [codecipher.readthedocs.io](https://codecipher.readthedocs.io/en/latest/)
* [www.python.org](https://www.python.org/)

### Contributing

[Contributing to codecipher](CONTRIBUTING.md)

### Copyright and Licence

[![License: GPL v3](https://img.shields.io/badge/License-GPLv3-blue.svg)](https://www.gnu.org/licenses/gpl-3.0) [![License](https://img.shields.io/badge/License-Apache%202.0-blue.svg)](https://opensource.org/licenses/Apache-2.0)

Copyright (C) 2021 - 2024 by [electux.github.io/codecipher](https://electux.github.io/codecipher/)

**codecipher** is free software; you can redistribute it and/or modify
it under the same terms as Python itself, either Python version 3.x or,
at your option, any later version of Python 3 you may have available.

Lets help and support PSF.

[![Python Software Foundation](https://raw.githubusercontent.com/electux/codecipher/dev/docs/psf-logo-alpha.png)](https://www.python.org/psf/)

[![Donate](https://www.paypalobjects.com/en_US/i/btn/btn_donateCC_LG.gif)](https://www.python.org/psf/donations/)

            

Raw data

            {
    "_id": null,
    "home_page": "https://electux.github.io/codecipher",
    "name": "codecipher",
    "maintainer": "",
    "docs_url": null,
    "requires_python": ">=3.10",
    "maintainer_email": "",
    "keywords": "cipher,encryption,decryption,cryptology,cryptography",
    "author": "Vladimir Roncevic",
    "author_email": "elektron.ronca@gmail.com",
    "download_url": "https://files.pythonhosted.org/packages/2b/a6/b4c377c58e8902a4d50d034d583c579956c7bdf04c7414a4b789ef8c29fe/codecipher-1.4.5.tar.gz",
    "platform": "any",
    "description": "<img align=\"right\" src=\"https://raw.githubusercontent.com/electux/codecipher/dev/docs/codecipher_logo.png\" width=\"25%\">\n\n# CODECipher\n\n**codecipher** is package for cipher utilities.\n\nDeveloped in **[python](https://www.python.org/)** code.\n\nThe README is used to introduce the modules and provide instructions on\nhow to install the modules, any machine dependencies it may have and any\nother information that should be provided before the modules are installed.\n\n[![codecipher python checker](https://github.com/electux/codecipher/actions/workflows/codecipher_python_checker.yml/badge.svg)](https://github.com/electux/codecipher/actions/workflows/codecipher_python_checker.yml) [![codecipher package checker](https://github.com/electux/codecipher/actions/workflows/codecipher_package_checker.yml/badge.svg)](https://github.com/electux/codecipher/actions/workflows/codecipher_package.yml) [![GitHub issues open](https://img.shields.io/github/issues/electux/codecipher.svg)](https://github.com/electux/codecipher/issues) [![GitHub contributors](https://img.shields.io/github/contributors/electux/codecipher.svg)](https://github.com/electux/codecipher/graphs/contributors)\n\n<!-- START doctoc generated TOC please keep comment here to allow auto update -->\n<!-- DON'T EDIT THIS SECTION, INSTEAD RE-RUN doctoc TO UPDATE -->\n**Table of Contents**\n\n- [Installation](#installation)\n    - [Install using pip](#install-using-pip)\n    - [Install using build](#install-using-build)\n    - [Install using py setup](#install-using-py-setup)\n    - [Install using docker](#install-using-docker)\n- [Dependencies](#dependencies)\n- [Usage](#usage)\n- [Package structure](#package-structure)\n- [Docs](#docs)\n- [Contributing](#contributing)\n- [Copyright and Licence](#copyright-and-licence)\n\n<!-- END doctoc generated TOC please keep comment here to allow auto update -->\n\n### Installation\n\nUsed next development environment\n\nUsed next development environment\n\n![debian linux os](https://raw.githubusercontent.com/electux/codecipher/dev/docs/debtux.png)\n\n[![codecipher python3 build](https://github.com/electux/codecipher/actions/workflows/codecipher_python3_build.yml/badge.svg)](https://github.com/electux/codecipher/actions/workflows/codecipher_python3_build.yml)\n\nCurrently there are three ways to install package\n* Install process based on using pip mechanism\n* Install process based on build mechanism\n* Install process based on setup.py mechanism\n* Install process based on docker mechanism\n\n##### Install using pip\n\n**codecipher** is located at **[pypi.org](https://pypi.org/project/codecipher/)**.\n\nYou can install by using pip\n\n```bash\n# python3\npip3 install codecipher\n```\n\n##### Install using build\n\nNavigate to **[release page](https://github.com/electux/codecipher/releases)** download and extract release archive.\n\nTo install **codecipher**, run\n\n```bash\ntar xvzf codecipher-x.y.z.tar.gz\ncd codecipher-x.y.z\n# python3\nwget https://bootstrap.pypa.io/get-pip.py\npython3 get-pip.py \npython3 -m pip install --upgrade setuptools\npython3 -m pip install --upgrade pip\npython3 -m pip install --upgrade build\npip3 install -r requirements.txt\npython3 -m build --no-isolation --wheel\npip3 install codecipher-x.y.z-py3-none-any.whl\nrm -f get-pip.py\n```\n\n##### Install using py setup\n\nNavigate to **[release page](https://github.com/electux/codecipher/releases)** download and extract release archive.\n\nTo install **codecipher**, locate and run setup.py with arguments\n\n```bash\ntar xvzf codecipher-x.y.z.tar.gz\ncd codecipher-x.y.z\n# python3\npip3 install -r requirements.txt\npython3 setup.py install_lib\npython3 setup.py install_egg_info\n```\n\n##### Install using docker\n\nYou can use Dockerfile to create image/container.\n\n### Dependencies\n\n**codecipher** requires other modules and libraries (Python 3.x)\n* None\n\n### Usage\n\n```python\nfrom codecipher.a1z52n62 import A1z52N62\nfrom codecipher.atbs import AlephTawBetShin\nfrom codecipher.b64 import B64\nfrom codecipher.caesar import Caesar\nfrom codecipher.vigenere import Vigenere\nfrom codecipher.vernam import Vernam\n\nprint(\"A1z52N62 cipher\")\ncipher = A1z52N62()\ndata = \"More Human Than Human01 Is Our Motto\"\n# encoding data\ncipher.encode(data)\n# encoded data\nprint(cipher.encode_data)\n# decoding data\ncipher.decode(cipher.encode_data)\n# decoded data\nprint(cipher.decode_data)\nprint(50*'=')\n\nprint(\"AlephTawBetShin cipher\")\ncipher = AlephTawBetShin()\ndata = \"More Human Than Human01 Is Our Motto\"\n# encoding data\ncipher.encode(data)\n# encoded data\nprint(cipher.encode_data)\n# decoding data\ncipher.decode(cipher.encode_data)\n# decoded data\nprint(cipher.decode_data)\nprint(50*'=')\n\nprint(\"B64 cipher\")\ncipher = B64()\ndata = \"More Human Than Human01 Is Our Motto\"\n# encoding data\ncipher.encode(data)\n# encoded data\nprint(cipher.encode_data)\n# decoding data\ncipher.decode(cipher.encode_data)\n# decoded data\nprint(cipher.decode_data)\nprint(50*'=')\n\nprint(\"Caesar cipher\")\ncipher = Caesar()\ndata = \"More Human Than Human01 Is Our Motto\"\n# encoding data\ncipher.encode(data, 3)\n# encoded data\nprint(cipher.encode_data)\n# decoding data\ncipher.decode(cipher.encode_data, 3)\n# decoded data\nprint(cipher.decode_data)\nprint(50*'=')\n\nprint(\"Vigenere cipher\")\ncipher = Vigenere()\ndata = \"More Human Than Human01 Is Our Motto\"\ncipher.data_len = len(data)\ncipher.key = \"AYUSH\"\ncipher.generate_key()\n# encoding data\ncipher.encode(data, cipher.key)\n# encoded data\nprint(cipher.encode_data)\n# decoding data\ncipher.decode(cipher.encode_data, cipher.key)\n# decoded data\nprint(cipher.decode_data)\nprint(50*'=')\n\nprint(\"Vernam cipher\")\ncipher = Vernam()\ndata = \"More Human Than Human01 Is Our Motto\"\n# encoding data\ncipher.encode(data, \"randomrandomrandom\")\n# encoded data\nprint(cipher.encode_data)\n# decoding data\ncipher.decode(cipher.encode_data, \"randomrandomrandom\")\n# decoded data\nprint(cipher.decode_data)\nprint(50*'=')\n```\n\n### Package structure\n\n**codecipher** is based on OOP.\n\nPackage structure\n\n```bash\n    codecipher/\n        \u251c\u2500\u2500 a1z52n62/\n        \u2502\u00a0\u00a0 \u251c\u2500\u2500 decode.py\n        \u2502\u00a0\u00a0 \u251c\u2500\u2500 encode.py\n        \u2502\u00a0\u00a0 \u2514\u2500\u2500 __init__.py\n        \u251c\u2500\u2500 atbs/\n        \u2502\u00a0\u00a0 \u251c\u2500\u2500 decode.py\n        \u2502\u00a0\u00a0 \u251c\u2500\u2500 encode.py\n        \u2502\u00a0\u00a0 \u251c\u2500\u2500 __init__.py\n        \u2502\u00a0\u00a0 \u2514\u2500\u2500 lookup_table.py\n        \u251c\u2500\u2500 b64/\n        \u2502\u00a0\u00a0 \u251c\u2500\u2500 decode.py\n        \u2502\u00a0\u00a0 \u251c\u2500\u2500 encode.py\n        \u2502\u00a0\u00a0 \u2514\u2500\u2500 __init__.py\n        \u251c\u2500\u2500 caesar/\n        \u2502\u00a0\u00a0 \u251c\u2500\u2500 decode.py\n        \u2502\u00a0\u00a0 \u251c\u2500\u2500 encode.py\n        \u2502\u00a0\u00a0 \u2514\u2500\u2500 __init__.py\n        \u251c\u2500\u2500 __init__.py\n        \u251c\u2500\u2500 vernam/\n        \u2502\u00a0\u00a0 \u251c\u2500\u2500 decode.py\n        \u2502\u00a0\u00a0 \u251c\u2500\u2500 encode.py\n        \u2502\u00a0\u00a0 \u2514\u2500\u2500 __init__.py\n        \u2514\u2500\u2500 vigenere/\n            \u251c\u2500\u2500 decode.py\n            \u251c\u2500\u2500 encode.py\n            \u251c\u2500\u2500 __init__.py\n            \u251c\u2500\u2500 key_generator.py\n            \u2514\u2500\u2500 lookup_table.py\n```\n\n### Docs\n\n[![documentation status](https://readthedocs.org/projects/codecipher/badge/?version=latest)](https://codecipher.readthedocs.io/en/latest/?badge=latest)\n\nMore documentation and info at\n\n* [codecipher.readthedocs.io](https://codecipher.readthedocs.io/en/latest/)\n* [www.python.org](https://www.python.org/)\n\n### Contributing\n\n[Contributing to codecipher](CONTRIBUTING.md)\n\n### Copyright and Licence\n\n[![License: GPL v3](https://img.shields.io/badge/License-GPLv3-blue.svg)](https://www.gnu.org/licenses/gpl-3.0) [![License](https://img.shields.io/badge/License-Apache%202.0-blue.svg)](https://opensource.org/licenses/Apache-2.0)\n\nCopyright (C) 2021 - 2024 by [electux.github.io/codecipher](https://electux.github.io/codecipher/)\n\n**codecipher** is free software; you can redistribute it and/or modify\nit under the same terms as Python itself, either Python version 3.x or,\nat your option, any later version of Python 3 you may have available.\n\nLets help and support PSF.\n\n[![Python Software Foundation](https://raw.githubusercontent.com/electux/codecipher/dev/docs/psf-logo-alpha.png)](https://www.python.org/psf/)\n\n[![Donate](https://www.paypalobjects.com/en_US/i/btn/btn_donateCC_LG.gif)](https://www.python.org/psf/donations/)\n",
    "bugtrack_url": null,
    "license": "GPL 2024 Free software to use and distributed it.",
    "summary": "Python Cipher Utilities",
    "version": "1.4.5",
    "project_urls": {
        "Homepage": "https://electux.github.io/codecipher"
    },
    "split_keywords": [
        "cipher",
        "encryption",
        "decryption",
        "cryptology",
        "cryptography"
    ],
    "urls": [
        {
            "comment_text": "",
            "digests": {
                "blake2b_256": "1d7cd36c6259ad714018a2e89500cb5b6c396d27867d0f60124f1a09ee19a401",
                "md5": "12c1ca2f8a4e3a1ef1199b86cc0323f7",
                "sha256": "ea637786fc9834bc84e767e224214ac4d9bfc9583ad4d8ae7e279fdcfc89158e"
            },
            "downloads": -1,
            "filename": "codecipher-1.4.5-py3-none-any.whl",
            "has_sig": false,
            "md5_digest": "12c1ca2f8a4e3a1ef1199b86cc0323f7",
            "packagetype": "bdist_wheel",
            "python_version": "py3",
            "requires_python": ">=3.10",
            "size": 43833,
            "upload_time": "2024-01-05T18:12:14",
            "upload_time_iso_8601": "2024-01-05T18:12:14.164434Z",
            "url": "https://files.pythonhosted.org/packages/1d/7c/d36c6259ad714018a2e89500cb5b6c396d27867d0f60124f1a09ee19a401/codecipher-1.4.5-py3-none-any.whl",
            "yanked": false,
            "yanked_reason": null
        },
        {
            "comment_text": "",
            "digests": {
                "blake2b_256": "2ba6b4c377c58e8902a4d50d034d583c579956c7bdf04c7414a4b789ef8c29fe",
                "md5": "e757a6343b30afc7fdb393f8fbd2fddd",
                "sha256": "69d90f9c4dd97fad7ea53c0472949075a7a11f0216fe2fad2ffc1bbb3e7e9732"
            },
            "downloads": -1,
            "filename": "codecipher-1.4.5.tar.gz",
            "has_sig": false,
            "md5_digest": "e757a6343b30afc7fdb393f8fbd2fddd",
            "packagetype": "sdist",
            "python_version": "source",
            "requires_python": ">=3.10",
            "size": 24079,
            "upload_time": "2024-01-05T18:12:15",
            "upload_time_iso_8601": "2024-01-05T18:12:15.759301Z",
            "url": "https://files.pythonhosted.org/packages/2b/a6/b4c377c58e8902a4d50d034d583c579956c7bdf04c7414a4b789ef8c29fe/codecipher-1.4.5.tar.gz",
            "yanked": false,
            "yanked_reason": null
        }
    ],
    "upload_time": "2024-01-05 18:12:15",
    "github": false,
    "gitlab": false,
    "bitbucket": false,
    "codeberg": false,
    "lcname": "codecipher"
}
        
Elapsed time: 0.21546s