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
Filter files by name, interpreter, ABI, and platform.
If you're not sure about the file name format, learn more about wheel file names.
Copy a direct link to the current filters
File details
Details for the file ctx_defense-1.0.0-py2.py3-none-any.whl.
File metadata
- Download URL: ctx_defense-1.0.0-py2.py3-none-any.whl
- Upload date:
- Size: 6.1 kB
- Tags: Python 2, Python 3
- Uploaded using Trusted Publishing? No
File hashes
| Algorithm | Hash digest | |
|---|---|---|
| SHA256 |
3f3f28d4ddee75fa8553a25104cf0af35927f2328ab9bce063131eb33e5921b5
|
|
| MD5 |
677d382df544b5c1c98d270c5335ddb9
|
|
| BLAKE2b-256 |
989e72eef70a75b6490cb126d9526bcd1c45d500b58716a6e730e20f250724f6
|