kellanb-cryptography


Namekellanb-cryptography JSON
Version 1.2.3 PyPI version JSON
download
home_page
Summaryencryption libray
upload_time2023-01-05 20:50:11
maintainer
docs_urlNone
authorKellan Butler
requires_python
license
keywords python encryption aes chacha20 hmac
VCS
bugtrack_url
requirements No requirements were recorded.
Travis-CI No Travis.
coveralls test coverage No coveralls.
            # kellanb-cryptography 

## an easy-to-use wrapper ontop of pycryptodome

### installation
`pip install kellanb-cryptography`

### use 
### kellanb-cryptography easy 

a tool for quick and simple encryption

`from kellanb-cryptography import easy`


`encrypted = easy.encrypt(data,key)   `<br>
data: string<br>
key: string

`decrypted = easy.decrypt(encrypted,key) `<br>
encrypted: string<br>
key: string

### kellanb-cryptography key
generate a key from password

`from kellanb_cryptography import key`

`key = key.gen_key_from_password(password, length=256)`<br>

password: string<br>
length in bits: int

### kellanb-cryptography aes
encrypt in aes
`from kellanb_cryptography import aes`

`encrypted = aes.encrypt_aes(data, key,mode='GCM')`<br>
data: string<br>
key: string, length 16,24,or 32
mode: 'GCM','EAX',or 'CCM', shows mode of operation

`decrypted = aes.decrypt_aes(encrypted, key)`<br>
encrypted: string<br>
key: string, length 16,24,or 32


### kellanb-cryptography chacha20
encrypt in chacha20
`from kellanb_cryptography import chacha20`

`encrypted = chacha20.encrypt_chacha_20(data, key)`<br>
data: string<br>
key: string, 32 <br>

`decrypted = aes.decrypt_chacha20(encrypted, key)`<br>
encrypted: string<br>
key: string, length 32


### kellanb-cryptography hash
generate a key from password

`from kellanb_cryptography import hash`


`hash.sha256(data)`
data: string, data to be hashed 

`hash.sha256(data)`  
data: string, data to be hashed 

`hash.512(data)`  
data: string, data to be hashed 

`hash.sha3_256(data)`  
data: string, data to be hashed 

`hash.sha3_512(data)`  
data: string, data to be hashed 


### kellanb-cryptography hmac
tamper-proof your messages

`from kellanb_cryptography import hmac`

`mac = hmac.create_hmac(data,password)`

data: string,
password: password to verify with

### NOTE: THIS WILL NOT ENCRYPT YOUR DATA

`hmac.verify_hmac(data,mac,password)`
returns 1 for not tampered, a zero for check fail (data tampered)

data: data to verify
mac: HMAC code
password: password to verify with




            

Raw data

            {
    "_id": null,
    "home_page": "",
    "name": "kellanb-cryptography",
    "maintainer": "",
    "docs_url": null,
    "requires_python": "",
    "maintainer_email": "",
    "keywords": "python,encryption,aes,chacha20,hmac",
    "author": "Kellan Butler",
    "author_email": "kellanbulter52@gmial.com",
    "download_url": "https://files.pythonhosted.org/packages/76/89/cdbedb3b85755db7de86daddd172b6e0fa5f462ca1872d6c6d1914687b76/kellanb_cryptography-1.2.3.tar.gz",
    "platform": null,
    "description": "# kellanb-cryptography \n\n## an easy-to-use wrapper ontop of pycryptodome\n\n### installation\n`pip install kellanb-cryptography`\n\n### use \n### kellanb-cryptography easy \n\na tool for quick and simple encryption\n\n`from kellanb-cryptography import easy`\n\n\n`encrypted = easy.encrypt(data,key)   `<br>\ndata: string<br>\nkey: string\n\n`decrypted = easy.decrypt(encrypted,key) `<br>\nencrypted: string<br>\nkey: string\n\n### kellanb-cryptography key\ngenerate a key from password\n\n`from kellanb_cryptography import key`\n\n`key = key.gen_key_from_password(password, length=256)`<br>\n\npassword: string<br>\nlength in bits: int\n\n### kellanb-cryptography aes\nencrypt in aes\n`from kellanb_cryptography import aes`\n\n`encrypted = aes.encrypt_aes(data, key,mode='GCM')`<br>\ndata: string<br>\nkey: string, length 16,24,or 32\nmode: 'GCM','EAX',or 'CCM', shows mode of operation\n\n`decrypted = aes.decrypt_aes(encrypted, key)`<br>\nencrypted: string<br>\nkey: string, length 16,24,or 32\n\n\n### kellanb-cryptography chacha20\nencrypt in chacha20\n`from kellanb_cryptography import chacha20`\n\n`encrypted = chacha20.encrypt_chacha_20(data, key)`<br>\ndata: string<br>\nkey: string, 32 <br>\n\n`decrypted = aes.decrypt_chacha20(encrypted, key)`<br>\nencrypted: string<br>\nkey: string, length 32\n\n\n### kellanb-cryptography hash\ngenerate a key from password\n\n`from kellanb_cryptography import hash`\n\n\n`hash.sha256(data)`\ndata: string, data to be hashed \n\n`hash.sha256(data)`  \ndata: string, data to be hashed \n\n`hash.512(data)`  \ndata: string, data to be hashed \n\n`hash.sha3_256(data)`  \ndata: string, data to be hashed \n\n`hash.sha3_512(data)`  \ndata: string, data to be hashed \n\n\n### kellanb-cryptography hmac\ntamper-proof your messages\n\n`from kellanb_cryptography import hmac`\n\n`mac = hmac.create_hmac(data,password)`\n\ndata: string,\npassword: password to verify with\n\n### NOTE: THIS WILL NOT ENCRYPT YOUR DATA\n\n`hmac.verify_hmac(data,mac,password)`\nreturns 1 for not tampered, a zero for check fail (data tampered)\n\ndata: data to verify\nmac: HMAC code\npassword: password to verify with\n\n\n\n",
    "bugtrack_url": null,
    "license": "",
    "summary": "encryption libray",
    "version": "1.2.3",
    "split_keywords": [
        "python",
        "encryption",
        "aes",
        "chacha20",
        "hmac"
    ],
    "urls": [
        {
            "comment_text": "",
            "digests": {
                "blake2b_256": "f8cb33f19493a0c89c057fe1c06241d4c9e3597c0c0997785aa565bd24cf6699",
                "md5": "1f7560a921b2188ca5f478eceae8ed27",
                "sha256": "3181b969cb5fcd413ea7ecf53b5a986dbb7d3c1930edb3bed664b5a0132cc5b4"
            },
            "downloads": -1,
            "filename": "kellanb_cryptography-1.2.3-py3-none-any.whl",
            "has_sig": false,
            "md5_digest": "1f7560a921b2188ca5f478eceae8ed27",
            "packagetype": "bdist_wheel",
            "python_version": "py3",
            "requires_python": null,
            "size": 5139,
            "upload_time": "2023-01-05T20:50:10",
            "upload_time_iso_8601": "2023-01-05T20:50:10.005330Z",
            "url": "https://files.pythonhosted.org/packages/f8/cb/33f19493a0c89c057fe1c06241d4c9e3597c0c0997785aa565bd24cf6699/kellanb_cryptography-1.2.3-py3-none-any.whl",
            "yanked": false,
            "yanked_reason": null
        },
        {
            "comment_text": "",
            "digests": {
                "blake2b_256": "7689cdbedb3b85755db7de86daddd172b6e0fa5f462ca1872d6c6d1914687b76",
                "md5": "0c7284084e404c725dd92aadf449ce1b",
                "sha256": "0b112f0df16e127561b2bedb0f5804d27ebb3440ff6a27bac531ab2a7b0db3d5"
            },
            "downloads": -1,
            "filename": "kellanb_cryptography-1.2.3.tar.gz",
            "has_sig": false,
            "md5_digest": "0c7284084e404c725dd92aadf449ce1b",
            "packagetype": "sdist",
            "python_version": "source",
            "requires_python": null,
            "size": 3777,
            "upload_time": "2023-01-05T20:50:11",
            "upload_time_iso_8601": "2023-01-05T20:50:11.435059Z",
            "url": "https://files.pythonhosted.org/packages/76/89/cdbedb3b85755db7de86daddd172b6e0fa5f462ca1872d6c6d1914687b76/kellanb_cryptography-1.2.3.tar.gz",
            "yanked": false,
            "yanked_reason": null
        }
    ],
    "upload_time": "2023-01-05 20:50:11",
    "github": false,
    "gitlab": false,
    "bitbucket": false,
    "lcname": "kellanb-cryptography"
}
        
Elapsed time: 0.02658s