Product
Introducing License Enforcement in Socket
Ensure open-source compliance with Socket’s License Enforcement Beta. Set up your License Policy and secure your software!
.. image:: https://github.com/manicmaniac/arc4/actions/workflows/test.yml/badge.svg :target: https://github.com/manicmaniac/arc4/actions/workflows/test.yml :alt: Test
.. image:: https://api.codeclimate.com/v1/badges/e7c21db66865a6d487d0/test_coverage.svg :target: https://codeclimate.com/github/manicmaniac/arc4/test_coverage :alt: Test Coverage
.. image:: https://api.codeclimate.com/v1/badges/e7c21db66865a6d487d0/maintainability.svg :target: https://codeclimate.com/github/manicmaniac/arc4/maintainability :alt: Maintainability
.. image:: https://readthedocs.org/projects/arc4/badge/?version=latest :target: https://arc4.readthedocs.io/en/latest/?badge=latest :alt: Documentation Status
A small and insanely fast ARCFOUR (RC4) cipher implementation of Python.
Below is benchmark metrics against 3 major RC4 implementations.
.. image:: https://gist.githubusercontent.com/manicmaniac/991d0c197e1cb62eec81edec65363187/raw/benchmark.svg :alt: Benchmark
The whole benchmark code is in ./benchmark.py
.
.. note::
arc4 supports multi-threading but it is too fast to ignore the overhead of context-switching, in most cases.
Install from PyPI
.. code:: sh
pip install arc4
Or clone the repo and do install
.. code:: sh
git clone https://github.com/manicmaniac/arc4.git cd arc4 python setup.py install
.. code:: python
from arc4 import ARC4 arc4 = ARC4(b'key') cipher = arc4.encrypt(b'some plain text to encrypt')
Because RC4 is a stream cipher, you must initialize RC4 object in the beginning of each operations.
.. code:: python
arc4 = ARC4(b'key') arc4.decrypt(cipher) b'some plain text to encrypt'
Here is the API reference.
https://arc4.readthedocs.io/en/latest/
.. code:: sh
python -m unittest discover
This software is under the MIT License.
FAQs
A small and insanely fast ARCFOUR (RC4) cipher implementation of Python
We found that arc4 demonstrated a healthy version release cadence and project activity because the last version was released less than a year ago. It has 1 open source maintainer collaborating on the project.
Did you know?
Socket for GitHub automatically highlights issues in each pull request and monitors the health of all your open source dependencies. Discover the contents of your packages and block harmful activity before you install or update your dependencies.
Product
Ensure open-source compliance with Socket’s License Enforcement Beta. Set up your License Policy and secure your software!
Product
We're launching a new set of license analysis and compliance features for analyzing, managing, and complying with licenses across a range of supported languages and ecosystems.
Product
We're excited to introduce Socket Optimize, a powerful CLI command to secure open source dependencies with tested, optimized package overrides.