The CTX defense library.
Project description
ctx
==============
The CTX defense library.
Installation
============
- Install the latest stable version using ``pip``:
```sh
pip install ctx-defense
```
Basic Usage
===========
- Import the CTX class from ctx and initialize the ctx object:
```python
from ctx_defense import CTX
ctx_object = CTX()
```
- Protect a secret from an origin with a specific alphabet:
```python
protected_secret = ctx_object.protect(secret, origin, alphabet)
```
- Retrieve the permutations for all origins:
```python
permutations = ctx_object.get_permutations()
```
- For more information on the CTX library and the classes it implements visit the defense's [website](https://github.com/dimkarakostas/ctx).
Example
=======
```python
from ctx_defense import CTX
secret = 'A secret string'
origin = 'user1'
alphabet = 'ASCII'
ctx_object = CTX()
protected_secret = ctx_object.protect(secret, origin, alphabet)
permutations = ctx_object.get_permutations()
```
==============
The CTX defense library.
Installation
============
- Install the latest stable version using ``pip``:
```sh
pip install ctx-defense
```
Basic Usage
===========
- Import the CTX class from ctx and initialize the ctx object:
```python
from ctx_defense import CTX
ctx_object = CTX()
```
- Protect a secret from an origin with a specific alphabet:
```python
protected_secret = ctx_object.protect(secret, origin, alphabet)
```
- Retrieve the permutations for all origins:
```python
permutations = ctx_object.get_permutations()
```
- For more information on the CTX library and the classes it implements visit the defense's [website](https://github.com/dimkarakostas/ctx).
Example
=======
```python
from ctx_defense import CTX
secret = 'A secret string'
origin = 'user1'
alphabet = 'ASCII'
ctx_object = CTX()
protected_secret = ctx_object.protect(secret, origin, alphabet)
permutations = ctx_object.get_permutations()
```
Project details
Release history Release notifications | RSS feed
Download files
Download the file for your platform. If you're not sure which to choose, learn more about installing packages.
Source Distributions
No source distribution files available for this release.See tutorial on generating distribution archives.
Built Distribution
Close
Hashes for ctx_defense-1.0.0-py2.py3-none-any.whl
Algorithm | Hash digest | |
---|---|---|
SHA256 | 3f3f28d4ddee75fa8553a25104cf0af35927f2328ab9bce063131eb33e5921b5 |
|
MD5 | 677d382df544b5c1c98d270c5335ddb9 |
|
BLAKE2b-256 | 989e72eef70a75b6490cb126d9526bcd1c45d500b58716a6e730e20f250724f6 |