pax_global_header00006660000000000000000000000064143717700460014523gustar00rootroot0000000000000052 comment=e7c7737c65d74ce188bcb9b95c674d7f1a47faf4 unicrypto-0.0.10/000077500000000000000000000000001437177004600136355ustar00rootroot00000000000000unicrypto-0.0.10/.gitignore000066400000000000000000000034071437177004600156310ustar00rootroot00000000000000# Byte-compiled / optimized / DLL files __pycache__/ *.py[cod] *$py.class # C extensions *.so # Distribution / packaging .Python build/ develop-eggs/ dist/ downloads/ eggs/ .eggs/ lib/ lib64/ parts/ sdist/ var/ wheels/ pip-wheel-metadata/ share/python-wheels/ *.egg-info/ .installed.cfg *.egg MANIFEST # PyInstaller # Usually these files are written by a python script from a template # before PyInstaller builds the exe, so as to inject date/other infos into it. *.manifest *.spec # Installer logs pip-log.txt pip-delete-this-directory.txt # Unit test / coverage reports htmlcov/ .tox/ .nox/ .coverage .coverage.* .cache nosetests.xml coverage.xml *.cover *.py,cover .hypothesis/ .pytest_cache/ # Translations *.mo *.pot # Django stuff: *.log local_settings.py db.sqlite3 db.sqlite3-journal # Flask stuff: instance/ .webassets-cache # Scrapy stuff: .scrapy # Sphinx documentation docs/_build/ # PyBuilder target/ # Jupyter Notebook .ipynb_checkpoints # IPython profile_default/ ipython_config.py # pyenv .python-version # pipenv # According to pypa/pipenv#598, it is recommended to include Pipfile.lock in version control. # However, in case of collaboration, if having platform-specific dependencies or dependencies # having no cross-platform support, pipenv may install dependencies that don't work, or not # install all needed dependencies. #Pipfile.lock # PEP 582; used by e.g. github.com/David-OConnor/pyflow __pypackages__/ # Celery stuff celerybeat-schedule celerybeat.pid # SageMath parsed files *.sage.py # Environments .env .venv env/ venv/ ENV/ env.bak/ venv.bak/ # Spyder project settings .spyderproject .spyproject # Rope project settings .ropeproject # mkdocs documentation /site # mypy .mypy_cache/ .dmypy.json dmypy.json # Pyre type checker .pyre/ unicrypto-0.0.10/LICENSE000066400000000000000000000020651437177004600146450ustar00rootroot00000000000000MIT License Copyright (c) 2022 Tamas Jos (@skelsec) Permission is hereby granted, free of charge, to any person obtaining a copy of this software and associated documentation files (the "Software"), to deal in the Software without restriction, including without limitation the rights to use, copy, modify, merge, publish, distribute, sublicense, and/or sell copies of the Software, and to permit persons to whom the Software is furnished to do so, subject to the following conditions: The above copyright notice and this permission notice shall be included in all copies or substantial portions of the Software. THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY, FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE SOFTWARE. unicrypto-0.0.10/Makefile000066400000000000000000000005171437177004600153000ustar00rootroot00000000000000clean: rm -f -r build/ rm -f -r dist/ rm -f -r *.egg-info find . -name '*.pyc' -exec rm -f {} + find . -name '*.pyo' -exec rm -f {} + find . -name '*~' -exec rm -f {} + publish: clean python3 setup.py sdist bdist_wheel python3 -m twine upload dist/* rebuild: clean python3 setup.py install build: python3 setup.py installunicrypto-0.0.10/README.md000066400000000000000000000000641437177004600151140ustar00rootroot00000000000000# unicrypto Unified interface for some crypto algos unicrypto-0.0.10/pyproject.toml000066400000000000000000000001201437177004600165420ustar00rootroot00000000000000[build-system] requires = ["setuptools"] build-backend = "setuptools.build_meta"unicrypto-0.0.10/setup.py000066400000000000000000000021431437177004600153470ustar00rootroot00000000000000from setuptools import setup, find_packages import re VERSIONFILE="unicrypto/_version.py" verstrline = open(VERSIONFILE, "rt").read() VSRE = r"^__version__ = ['\"]([^'\"]*)['\"]" mo = re.search(VSRE, verstrline, re.M) if mo: verstr = mo.group(1) else: raise RuntimeError("Unable to find version string in %s." % (VERSIONFILE,)) setup( # Application name: name="unicrypto", # Version number (initial): version=verstr, # Application author details: author="Tamas Jos", author_email="info@skelsecprojects.com", # Packages packages=find_packages(), # Include additional files into the package include_package_data=True, # Details url="https://github.com/skelsec/unicrypto", zip_safe=True, # # license="LICENSE.txt", description="Unified interface for cryptographic libraries", # long_description=open("README.txt").read(), python_requires='>=3.6', classifiers=[ "Programming Language :: Python :: 3.6", "Operating System :: OS Independent", ], ## these libraries are optional ## lib can work without additional deps but it will be slow install_requires=[ 'pycryptodomex', ], ) unicrypto-0.0.10/tests/000077500000000000000000000000001437177004600147775ustar00rootroot00000000000000unicrypto-0.0.10/tests/__init__.py000066400000000000000000000000001437177004600170760ustar00rootroot00000000000000unicrypto-0.0.10/tests/coverage.sh000077500000000000000000000001051437177004600171250ustar00rootroot00000000000000pytest --cov-config=.coveragerc --cov-report html --cov=unicrypto ../unicrypto-0.0.10/tests/coveragerc000066400000000000000000000000201437177004600170320ustar00rootroot00000000000000[run] omit = ./*unicrypto-0.0.10/tests/test_aes.py000066400000000000000000001551271437177004600171730ustar00rootroot00000000000000 import pytest from unicrypto import get_cipher_by_name from unicrypto import symmetric # NOTE: python-mbedtls has issues with CFB and GCM modes, issue has been sent to the maintainer # old crypto backend is not supported anymore # https://github.com/weidai11/cryptopp/blob/master/TestVectors/aes.txt aes_128_ecb = [ #plaintext, key, ciphertext ('6bc1bee22e409f96e93d7e117393172a', '2b7e151628aed2a6abf7158809cf4f3c', '3ad77bb40d7a3660a89ecaf32466ef97'), ('ae2d8a571e03ac9c9eb76fac45af8e51', '2b7e151628aed2a6abf7158809cf4f3c', 'f5d3d58503b9699de785895a96fdbaaf'), ('30c81c46a35ce411e5fbc1191a0a52ef', '2b7e151628aed2a6abf7158809cf4f3c', '43b1cd7f598ece23881b00e3ed030688'), ('f69f2445df4f9b17ad2b417be66c3710', '2b7e151628aed2a6abf7158809cf4f3c', '7b0c785e27e8ad3f8223207104725dd4'), ] aes_192_ecb = [ ('6bc1bee22e409f96e93d7e117393172a', '8e73b0f7da0e6452c810f32b809079e562f8ead2522c6b7b', 'bd334f1d6e45f25ff712a214571fa5cc'), ('ae2d8a571e03ac9c9eb76fac45af8e51', '8e73b0f7da0e6452c810f32b809079e562f8ead2522c6b7b', '974104846d0ad3ad7734ecb3ecee4eef'), ('30c81c46a35ce411e5fbc1191a0a52ef', '8e73b0f7da0e6452c810f32b809079e562f8ead2522c6b7b', 'ef7afd2270e2e60adce0ba2face6444e'), ('f69f2445df4f9b17ad2b417be66c3710', '8e73b0f7da0e6452c810f32b809079e562f8ead2522c6b7b', '9a4b41ba738d6c72fb16691603c18e0e'), ] aes_256_ecb = [ ('6bc1bee22e409f96e93d7e117393172a', '603deb1015ca71be2b73aef0857d77811f352c073b6108d72d9810a30914dff4', 'f3eed1bdb5d2a03c064b5a7e3db181f8'), ('ae2d8a571e03ac9c9eb76fac45af8e51', '603deb1015ca71be2b73aef0857d77811f352c073b6108d72d9810a30914dff4', '591ccb10d410ed26dc5ba74a31362870'), ('30c81c46a35ce411e5fbc1191a0a52ef', '603deb1015ca71be2b73aef0857d77811f352c073b6108d72d9810a30914dff4', 'b6ed21b99ca6f4f9f153e7b1beafed1d'), ('f69f2445df4f9b17ad2b417be66c3710', '603deb1015ca71be2b73aef0857d77811f352c073b6108d72d9810a30914dff4', '23304b7a39f9f3ff067d8d8f9e24ecc7'), ] aes_ecb_long = [ ('006bc1bee22e409f96e93d7e117393172aae2d8a571e03ac9c9eb76fac45af8e5130c81c46a35ce411e5fbc1191a0a52eff69f2445df4f9b17ad2b417be66c371000'*8,'2b7e151628aed2a6abf7158809cf4f3c','84C6CBDC2B5A39985774B23BAB066A6AF8CB66C08E4F058E5D3E7C351EA845CEC7B209210EE7EFD38269628687F21CB9BCEA349DC0418ADBA2BF2364DF4DB1A11AD84CF6A422CE95C37B2CF81196245CD857D0B954B83985C1888230F3C301847AAF714253EF768C17E89E4F5513DBD5BEE1266A2B2D7063CE3D0BA8716252C5BCBB9922CD46F374B52FDFF1FEBF155FF4AFEE18788999BC74234A3FFBA7B2858BB2552F172E56EC47456878440ABB5ADAE49941C1E43616AC5D6E31A011611B829F6A77BE1F50754F81F35D24ED89FDE804B17363F9A81C3F12AE067FDD41A2984912CAE1926C5FB3AC18E541FA4AD1E171888E61428F2A8F2E981AE16D0D4E41D33E5E675F446DAE0F454FC4CA056F41F3CC4744A9E948428B2280F96663B7230C09692503C95B3E34F8DE8DF23157F45BDF689B258D994D9E6CE5D4DD6BDB96763CCC41DBBE57A4778D5A9E90226D614C335E44CA8AB41EFEA898BC170C65412F77194A43A1305EF23AC70B059E6E047796EF518D7696BC3DAD5E2634F92DD1C90D206A2B6D3A7CE88668BEAD64614E9000ACFBA79EB3601606214E21E08F14CE77E36BB66FE4A0FCD2A21BCAA2391A9C2016AC3BC7CDF1438EB6DD26696644583E2B0A0C68629D736F6723DF66859CF80B4E5B5C5BF03F334D65C48DB3B2660E2CE33B510FD60C912B85D16AEE7CDBFDF6285B0A77BAE07D987F9CE172A548E6BF0A30CF099AA82BE0A25E0E8919') ] aes_cbc_128 = [ # plaintext, key, ciphertext, iv ('6bc1bee22e409f96e93d7e117393172a','2b7e151628aed2a6abf7158809cf4f3c','7649abac8119b246cee98e9b12e9197d','000102030405060708090a0b0c0d0e0f'), ('ae2d8a571e03ac9c9eb76fac45af8e51','2b7e151628aed2a6abf7158809cf4f3c','5086cb9b507219ee95db113a917678b2','000102030405060708090a0b0c0d0e0f'), ('30c81c46a35ce411e5fbc1191a0a52ef','2b7e151628aed2a6abf7158809cf4f3c','73bed6b8e3c1743b7116e69e22229516','000102030405060708090a0b0c0d0e0f'), ('f69f2445df4f9b17ad2b417be66c3710','2b7e151628aed2a6abf7158809cf4f3c','3ff1caa1681fac09120eca307586e1a7','000102030405060708090a0b0c0d0e0f'), ] aes_cbc_192 = [ # plaintext, key, ciphertext, iv ('6bc1bee22e409f96e93d7e117393172a','8e73b0f7da0e6452c810f32b809079e562f8ead2522c6b7b','4f021db243bc633d7178183a9fa071e8','000102030405060708090a0b0c0d0e0f'), ('ae2d8a571e03ac9c9eb76fac45af8e51','8e73b0f7da0e6452c810f32b809079e562f8ead2522c6b7b','b4d9ada9ad7dedf4e5e738763f69145a','000102030405060708090a0b0c0d0e0f'), ('30c81c46a35ce411e5fbc1191a0a52ef','8e73b0f7da0e6452c810f32b809079e562f8ead2522c6b7b','571b242012fb7ae07fa9baac3df102e0','000102030405060708090a0b0c0d0e0f'), ('f69f2445df4f9b17ad2b417be66c3710','8e73b0f7da0e6452c810f32b809079e562f8ead2522c6b7b','08b0e27988598881d920a9e64f5615cd','000102030405060708090a0b0c0d0e0f'), ] aes_cbc_256 = [ # plaintext, key, ciphertext, iv ('6bc1bee22e409f96e93d7e117393172a','603deb1015ca71be2b73aef0857d77811f352c073b6108d72d9810a30914dff4','f58c4c04d6e5f1ba779eabfb5f7bfbd6','000102030405060708090a0b0c0d0e0f'), ('ae2d8a571e03ac9c9eb76fac45af8e51','603deb1015ca71be2b73aef0857d77811f352c073b6108d72d9810a30914dff4','9cfc4e967edb808d679f777bc6702c7d','000102030405060708090a0b0c0d0e0f'), ('30c81c46a35ce411e5fbc1191a0a52ef','603deb1015ca71be2b73aef0857d77811f352c073b6108d72d9810a30914dff4','39f23369a9d9bacfa530e26304231461','000102030405060708090a0b0c0d0e0f'), ('f69f2445df4f9b17ad2b417be66c3710','603deb1015ca71be2b73aef0857d77811f352c073b6108d72d9810a30914dff4','b2eb05e2c39be9fcda6c19078c6a9d1b','000102030405060708090a0b0c0d0e0f'), ] aes_cbc_long = [ ('006bc1bee22e409f96e93d7e117393172aae2d8a571e03ac9c9eb76fac45af8e5130c81c46a35ce411e5fbc1191a0a52eff69f2445df4f9b17ad2b417be66c371000'*8,'2b7e151628aed2a6abf7158809cf4f3c','6544CCA076C4D67C1A69DD7E504C6586FBD22912505E187D8628E19FA067D6C339D078E3032B8596DA74BB0E23434F83E153D5ACD5DEF7D264F58EC685317BF50C93430791718D6E09CCC4804FFE4EEB5C6AD8E9B5DFD456EDE81081627A97FC2FAE9F1955377D7774E68EAB541B20CE3C915185BCA208EE08428C400043F2DC90B0390756762C9271946FCE214B9576F74399E466DAC48C6DD10B420F302941DCC27D55CF1FB59D71954950CAD893FFFA70970D128C77BFA34F3C84B0B64A01194A086ACDD9847D6B91B7F870D0E7591CA07F0B407005F1473C37A648F6E18044336F30418BA43FD7AA5B5BAE01A0E33B1EDA4487730F043E202DE44CB901BD3AED13D790D05F325C414831EB601BD918678C1B8E116877CE1167F87204B49619D323713F95C04CA9621FDCF44BD21C5E36A299C486C8FC0D3043EDFF424B9A7AA5500DC3BD7BF6FAB256E6B45B458058DC933F1FF8C5E841BFC7F405761E14B12B48C1C108F33BF8D65BB8DBB9ED7E92398E779333730F4C68922AA76409E842E76B649B981B8269186220ACFF9DFA198D62CBF4CFA0FE05C1427CE63A345A61FE460D14EF25D7A89E2E228B415757B4E4110B6AFA7D85D48C3BCF184FDD7366F06D9E3D29896B0D3C0D83FCFA881E6EC5F29B0294628EDFF284E58B7BE19D37A6B28D70DC0F165A4B60CE5536D76D1A71849C36B0837E4E5082A05208CEEB320C57F0F5B86DC3CAAC8A32DEA9552D','f0f1f2f3f4f5f6f7f8f9fafbfcfdfeff') ] aes_cfb_feedbacksize_1 = [ # plaintext, key, ciphertext, iv ('6bc1bee22e409f96e93d7e117393172aae2d','2b7e151628aed2a6abf7158809cf4f3c','3b79424c9c0dd436bace9e0ed4586a4f32b9','000102030405060708090a0b0c0d0e0f'), ('6bc1bee22e409f96e93d7e117393172aae2d','8e73b0f7da0e6452c810f32b809079e562f8ead2522c6b7b','cda2521ef0a905ca44cd057cbf0d47a0678a','000102030405060708090a0b0c0d0e0f'), ('6bc1bee22e409f96e93d7e117393172aae2d','603deb1015ca71be2b73aef0857d77811f352c073b6108d72d9810a30914dff4','dc1f1a8520a64db55fcc8ac554844e889700','000102030405060708090a0b0c0d0e0f'), ] aes_cfb_128_feedbacksize_16 = [ # plaintext, key, ciphertext, iv ('6bc1bee22e409f96e93d7e117393172a','2b7e151628aed2a6abf7158809cf4f3c','3b3fd92eb72dad20333449f8e83cfb4a','000102030405060708090a0b0c0d0e0f'), ('ae2d8a571e03ac9c9eb76fac45af8e51','2b7e151628aed2a6abf7158809cf4f3c','c8a64537a0b3a93fcde3cdad9f1ce58b','000102030405060708090a0b0c0d0e0f'), ('30c81c46a35ce411e5fbc1191a0a52ef','2b7e151628aed2a6abf7158809cf4f3c','26751f67a3cbb140b1808cf187a4f4df','000102030405060708090a0b0c0d0e0f'), ('f69f2445df4f9b17ad2b417be66c3710','2b7e151628aed2a6abf7158809cf4f3c','c04b05357c5d1c0eeac4c66f9ff7f2e6','000102030405060708090a0b0c0d0e0f'), ] aes_cfb_192_feedbacksize_16 = [ # plaintext, key, ciphertext, iv ('6bc1bee22e409f96e93d7e117393172a','8e73b0f7da0e6452c810f32b809079e562f8ead2522c6b7b','cdc80d6fddf18cab34c25909c99a4174','000102030405060708090a0b0c0d0e0f'), ('ae2d8a571e03ac9c9eb76fac45af8e51','8e73b0f7da0e6452c810f32b809079e562f8ead2522c6b7b','67ce7f7f81173621961a2b70171d3d7a','000102030405060708090a0b0c0d0e0f'), ('30c81c46a35ce411e5fbc1191a0a52ef','8e73b0f7da0e6452c810f32b809079e562f8ead2522c6b7b','2e1e8a1dd59b88b1c8e60fed1efac4c9','000102030405060708090a0b0c0d0e0f'), ('f69f2445df4f9b17ad2b417be66c3710','8e73b0f7da0e6452c810f32b809079e562f8ead2522c6b7b','c05f9f9ca9834fa042ae8fba584b09ff','000102030405060708090a0b0c0d0e0f'), ] aes_cfb_256_feedbacksize_16 = [ # plaintext, key, ciphertext, iv ('6bc1bee22e409f96e93d7e117393172a','603deb1015ca71be2b73aef0857d77811f352c073b6108d72d9810a30914dff4','dc7e84bfda79164b7ecd8486985d3860','000102030405060708090a0b0c0d0e0f'), ('ae2d8a571e03ac9c9eb76fac45af8e51','603deb1015ca71be2b73aef0857d77811f352c073b6108d72d9810a30914dff4','39ffed143b28b1c832113c6331e5407b','000102030405060708090a0b0c0d0e0f'), ('30c81c46a35ce411e5fbc1191a0a52ef','603deb1015ca71be2b73aef0857d77811f352c073b6108d72d9810a30914dff4','df10132415e54b92a13ed0a8267ae2f9','000102030405060708090a0b0c0d0e0f'), ('f69f2445df4f9b17ad2b417be66c3710','603deb1015ca71be2b73aef0857d77811f352c073b6108d72d9810a30914dff4','75a385741ab9cef82031623d55b1e471','000102030405060708090a0b0c0d0e0f'), ] aes_cfb_long = [ ('006bc1bee22e409f96e93d7e117393172aae2d8a571e03ac9c9eb76fac45af8e5130c81c46a35ce411e5fbc1191a0a52eff69f2445df4f9b17ad2b417be66c3710'*11,'2b7e151628aed2a6abf7158809cf4f3c','ECE71ECD7A4E3C2F643B2B0BFBED32F365C96D626048D13C65962ED08445B5EE74B11203E24C0ACCD3CC13F39963632D8F4B8F8BB16B7901373C32FFD27472957A8448E414A26BB10CAE9BCFBF332BA677D59C0CCD4CCE5B34298E2B1F3250092CF602B5476922D9FA13D4AE9F54841D889FE71D67A79315A621BDAECB2FD3F1ECDAB0DC9FBDFB85AE1633038A44E15DEF1B6DDBC4AB47BB128E1C2DE8A17FD1107D8587CE96088709E17DA23DE6993973A43DFB59801A9691B7EBF5565C4FF842F5132E99288FA4CE3E6CE9333DEE052212E71EF08C5E2E385A787F1567C0CD05A4D11BF40CA19B8D49A231AA55CDE1B8C531C9FCD3B9C70AABD65372E582FCE7528B6BD8F89AA6489B1F085AE024D5A964CAEC4F3F5726CBACDB5D8429F6741FE102BC27E10724C30A64A7D3ED11F6FF41908920A1326793C7C7EDDDD2F79D8A3CE804AE53E59E43B2E0E69AF69A79D7A97A12C0A1AC7331369FCE4072879AA998CD1DC6296CB02D4B97803F1F3713F922796148E2263AFA6A72CF30C3C00297ABF2AD2D559AC4D0011A839FAAA261BB17966E80FF243B65B6209C2732F294F33936A3B8FE7C9BEBE50686BBE7F0FDCF9E24281242B10844037D9AB8A342B954B69E6456243CC13959E1B014A1389BA69B9C4E1C0869C7FE3292ED72FCF183B216F7F5EB5A7CD0A2493BCA160AE6142F4CF03110CA4782CA6C8ED558CA8AF4B14ADC4C368FF0C0CD014F7E117F56D797EF45294C8D3BCED9D5D4E3FA60592031E2925ABA72DFE5AC1D88081DB6CF68DCB256A822CE891AD12F5BB34F39CE974F7D23C0B7AB3BF12D854DA60617EB5E479A9740E00A1DCA267A3D1D212F25A06B83106CBD624CC745ACB31E0EA774F6E0D765D6134F74A3AF5B3846649C14539B7C01B484C54F71B2C5016C2EA57B16472145511130D79E23271151F370DB8A626DB218F73FF0ABFE066E2782696F6984923AA074AEA9E059AEC18F50D4E03F4B17BAD856E6C962604A02','f0f1f2f3f4f5f6f7f8f9fafbfcfdfeff'), ] aes_ofb_128 = [ # plaintext, key, ciphertext, iv ('6bc1bee22e409f96e93d7e117393172a','2b7e151628aed2a6abf7158809cf4f3c','3b3fd92eb72dad20333449f8e83cfb4a','000102030405060708090a0b0c0d0e0f'), ('ae2d8a571e03ac9c9eb76fac45af8e51','2b7e151628aed2a6abf7158809cf4f3c','7789508d16918f03f53c52dac54ed825','000102030405060708090a0b0c0d0e0f'), ('30c81c46a35ce411e5fbc1191a0a52ef','2b7e151628aed2a6abf7158809cf4f3c','9740051e9c5fecf64344f7a82260edcc','000102030405060708090a0b0c0d0e0f'), ('f69f2445df4f9b17ad2b417be66c3710','2b7e151628aed2a6abf7158809cf4f3c','304c6528f659c77866a510d9c1d6ae5e','000102030405060708090a0b0c0d0e0f'), ] aes_ofb_192 = [ # plaintext, key, ciphertext, iv ('6bc1bee22e409f96e93d7e117393172a','8e73b0f7da0e6452c810f32b809079e562f8ead2522c6b7b','cdc80d6fddf18cab34c25909c99a4174','000102030405060708090a0b0c0d0e0f'), ('ae2d8a571e03ac9c9eb76fac45af8e51','8e73b0f7da0e6452c810f32b809079e562f8ead2522c6b7b','fcc28b8d4c63837c09e81700c1100401','000102030405060708090a0b0c0d0e0f'), ('30c81c46a35ce411e5fbc1191a0a52ef','8e73b0f7da0e6452c810f32b809079e562f8ead2522c6b7b','8d9a9aeac0f6596f559c6d4daf59a5f2','000102030405060708090a0b0c0d0e0f'), ('f69f2445df4f9b17ad2b417be66c3710','8e73b0f7da0e6452c810f32b809079e562f8ead2522c6b7b','6d9f200857ca6c3e9cac524bd9acc92a','000102030405060708090a0b0c0d0e0f'), ] aes_ofb_256 = [ # plaintext, key, ciphertext, iv ('6bc1bee22e409f96e93d7e117393172a','603deb1015ca71be2b73aef0857d77811f352c073b6108d72d9810a30914dff4','dc7e84bfda79164b7ecd8486985d3860','000102030405060708090a0b0c0d0e0f'), ('ae2d8a571e03ac9c9eb76fac45af8e51','603deb1015ca71be2b73aef0857d77811f352c073b6108d72d9810a30914dff4','4febdc6740d20b3ac88f6ad82a4fb08d','000102030405060708090a0b0c0d0e0f'), ('30c81c46a35ce411e5fbc1191a0a52ef','603deb1015ca71be2b73aef0857d77811f352c073b6108d72d9810a30914dff4','71ab47a086e86eedf39d1c5bba97c408','000102030405060708090a0b0c0d0e0f'), ('f69f2445df4f9b17ad2b417be66c3710','603deb1015ca71be2b73aef0857d77811f352c073b6108d72d9810a30914dff4','0126141d67f37be8538f5a8be740e484','000102030405060708090a0b0c0d0e0f'), ] aes_ofb_long = [ ('006bc1bee22e409f96e93d7e117393172aae2d8a571e03ac9c9eb76fac45af8e5130c81c46a35ce411e5fbc1191a0a52eff69f2445df4f9b17ad2b417be66c3710'*11,'2b7e151628aed2a6abf7158809cf4f3c','ECE71ECD7A4E3C2F643B2B0BFBED32F3B3D63D91F8B99D5EA9D0AA2D977A8675EDD972802EB60B3D8FA629EF94358D46861CF60D9F89F481632F937182C78E49D53D132260CFC3A80943E0FD169C6091FF4BBBBDEC35F4A31DDB61AFA087750D6CFCF86DAB13330125D60A2732E43A2AF3E47ABE4824C5B17DD747F267149A321ADA13409D51D4FC685ADA6789D5785FCA5EF199FD96A03879B4147C4936CC32DE864520C98DD55408CA8ED4AF1BE1F133ED53CA9FF58E6862D3E900AE66EEF75272B547BBC8919CE5503981684FEBA088F5E73BF272C820656CC9627FB4E4FC3A92A6B815CAC558B3257614AA9BB2CF2409D3633B6570EEF67A9343502D2B528078E561782917D977E6F76B13CD6526512D3D4C803BBB58E54EED5B4057EAF85DE83A7EC53FACBCA7E03EB7E027910C8DA25B75BE33B41C0C594DF6D781E821193963C9F658D380A460561B2F0C9C3D7639A4E4EE2DA87653DA86FAD6D5280857CEC28CC40D082C81C672D9B36CD169A6803ACA4C8DAAD77953B296FBAF480FA146F8B41DCBD487A368851A207C90228DBF7BAEEB38F23F98520E52145D809DB530D3E690C2A91B8367B815C4FFC0AE7171582169D6A7FD073A1F9DE1182FC98D1D5B3E39B44E054218B80091333D5B751C0530BADF4361C5A95CB26634AE788F7B6D2CCA543FDE48172A24E4D991F9262CFB8ED09FFE4E1506DA6478EF879847F8CE44569A9AC66E124CEE5944D2DC87742CA1B598B3C7D54662F8A5783A0C6689C949C54E148C2C88DFBA4F10F0234BA62E4DDEA30F5AD3D209829CCB73C22141D56050FB75E0E7D1B822F6FFC6AB92E8DB12A5C6B62064B692F8B118CC38F0436433B5370CE5A79D09A7081703EEA59F64B7361AA50476DD2F7074CA37C51935DCBC78A806F92C1186033070D5C3FABACAAE39CB7FBA0654D13413E94F6E9FDDB7D2D4EC1985CCF2E2011C186BD0C16AA95A0C7FDDF1B36490780EB646EEB7B0B377E970FD7D2E9A06','f0f1f2f3f4f5f6f7f8f9fafbfcfdfeff'), ] aes_ctr_128 = [ # plaintext, key, ciphertext, iv ('6bc1bee22e409f96e93d7e117393172a','2b7e151628aed2a6abf7158809cf4f3c','874d6191b620e3261bef6864990db6ce','f0f1f2f3f4f5f6f7f8f9fafbfcfdfeff'), ('ae2d8a571e03ac9c9eb76fac45af8e51','2b7e151628aed2a6abf7158809cf4f3c','9806f66b7970fdff8617187bb9fffdff','f0f1f2f3f4f5f6f7f8f9fafbfcfdfeff'), ('30c81c46a35ce411e5fbc1191a0a52ef','2b7e151628aed2a6abf7158809cf4f3c','5ae4df3edbd5d35e5b4f09020db03eab','f0f1f2f3f4f5f6f7f8f9fafbfcfdfeff'), ('f69f2445df4f9b17ad2b417be66c3710','2b7e151628aed2a6abf7158809cf4f3c','1e031dda2fbe03d1792170a0f3009cee','f0f1f2f3f4f5f6f7f8f9fafbfcfdfeff'), ] aes_ctr_192 = [ # plaintext, key, ciphertext, iv ('6bc1bee22e409f96e93d7e117393172a','8e73b0f7da0e6452c810f32b809079e562f8ead2522c6b7b','1abc932417521ca24f2b0459fe7e6e0b','f0f1f2f3f4f5f6f7f8f9fafbfcfdfeff'), ('ae2d8a571e03ac9c9eb76fac45af8e51','8e73b0f7da0e6452c810f32b809079e562f8ead2522c6b7b','090339ec0aa6faefd5ccc2c6f4ce8e94','f0f1f2f3f4f5f6f7f8f9fafbfcfdfeff'), ('30c81c46a35ce411e5fbc1191a0a52ef','8e73b0f7da0e6452c810f32b809079e562f8ead2522c6b7b','1e36b26bd1ebc670d1bd1d665620abf7','f0f1f2f3f4f5f6f7f8f9fafbfcfdfeff'), ('f69f2445df4f9b17ad2b417be66c3710','8e73b0f7da0e6452c810f32b809079e562f8ead2522c6b7b','4f78a7f6d29809585a97daec58c6b050','f0f1f2f3f4f5f6f7f8f9fafbfcfdfeff'), ] aes_ctr_256 = [ # plaintext, key, ciphertext, iv ('6bc1bee22e409f96e93d7e117393172a','603deb1015ca71be2b73aef0857d77811f352c073b6108d72d9810a30914dff4','601ec313775789a5b7a7f504bbf3d228','f0f1f2f3f4f5f6f7f8f9fafbfcfdfeff'), ('ae2d8a571e03ac9c9eb76fac45af8e51','603deb1015ca71be2b73aef0857d77811f352c073b6108d72d9810a30914dff4','f443e3ca4d62b59aca84e990cacaf5c5','f0f1f2f3f4f5f6f7f8f9fafbfcfdfeff'), ('30c81c46a35ce411e5fbc1191a0a52ef','603deb1015ca71be2b73aef0857d77811f352c073b6108d72d9810a30914dff4','2b0930daa23de94ce87017ba2d84988d','f0f1f2f3f4f5f6f7f8f9fafbfcfdfeff'), ('f69f2445df4f9b17ad2b417be66c3710','603deb1015ca71be2b73aef0857d77811f352c073b6108d72d9810a30914dff4','dfc9c58db67aada613c2dd08457941a6','f0f1f2f3f4f5f6f7f8f9fafbfcfdfeff'), ] aes_ctr_long = [ ('006bc1bee22e409f96e93d7e117393172aae2d8a571e03ac9c9eb76fac45af8e5130c81c46a35ce411e5fbc1191a0a52eff69f2445df4f9b17ad2b417be66c3710'*11,'2b7e151628aed2a6abf7158809cf4f3c','ECE71ECD7A4E3C2F643B2B0BFBED32F31C8551B6306D52CF843EC0B85015DC203B1C0B643E2A6BABAF5133DA0EA06616076AA6BBB52ED75DC3A71A9A6E8AC7C9A00D2C39AA68BF4E6FFED9AAEE5AD6914FB3EA77C7B61FF6BF564F2F1225ACB4B5889CB1559888A5817849C382E168482F75381F63868C468E4D1583B1FE71DD808CB94D8150AAB9D530A0FC17CDE748E95545D8A033B2F61F1954D0C0226168022E1CD7E031C57D048AC560F152960F47705E174D956D4BB53AE80BFFCD1BD569ED8EFFA223C00558B702405F33E6E0EDB2D9B0C148A1441CC80D6ABBCE785AA1B9DAB7CB8832F1B12D2EE60EE2DFCA37942CA1724E5602B7B70525AC9662028A22DB234676615DB474538CBC8D197F38C88BCC4F9E8D207538CA18DE5F095420A2E4D5868CEBB8B34A9377DC52D119790B65210F1B346F5E00D9BD00A8847048913D80726B9B745D565E6284B986DBAEA997FFC5A0DE5051527D44B2C1266DBC9130A6EB15F37A0F00B6286D6678CA651C07743BD37F2E8F6A94F5ED8C63428AE4883A9695183807E104BC335C64FEAAC40A605913DF98FF44E0801B31A968CCE5DCAFADE1E017FA711E05FF5A54BFA1999C2C463F97A3A66B30211BD306C8911C98F8EE5EF47A54746A4D16B7C7424A6954B4FC3BCF1A41BDE8A19CE1027AE86A320D0E5E7D3C7E50CFD0C4665B811D86C313F09ADE5B4DBE017231859881E5873E9EDB2011CF5920D2F7277C4DE1AC430A1849F0B870A69ABE701B6D0B5123E5FF53395409177CF84BF41EC33C5E4BCC2CF29258DC7C260471AABDA49FDE62915758EE4E578D0F7698E6456BC144573739D5D508CC76B389359D2A0ECB5B7EE5FCB4C3151D5AF7C71819EA3DD5F36C7B27E551FD2373D07FFDC76A13FC4B10A6F29A83D6F465ACB6960671EACF21A3E1CB4411C4DAA0C2A87DAED28AEE60B7EC0258A9AF125F2DDC80B9877EFE0F372D9B832C786770A84EA1A07CB6E1A9907D651BBD0EFDEF2AFFC3','f0f1f2f3f4f5f6f7f8f9fafbfcfdfeff'), ] aes_ccm = [ #plain, key, cipher, nonce, adata, asize ('08090A0B0C0D0E0F101112131415161718191A1B1C1D1E', 'C0C1C2C3C4C5C6C7C8C9CACBCCCDCECF', '588C979A61C663D2F066D0C2C0F989806D5F6B61DAC38417E8D12CFDF926E0', '00000003020100A0A1A2A3A4A5', '0001020304050607', 8), ('08090A0B0C0D0E0F101112131415161718191A1B1C1D1E1F', 'C0C1C2C3C4C5C6C7C8C9CACBCCCDCECF', '72C91A36E135F8CF291CA894085C87E3CC15C439C9E43A3BA091D56E10400916', '00000004030201A0A1A2A3A4A5', '0001020304050607', 8), #???('08090A0B0C0D0E0F101112131415161718191A1B1C1D1E1F20', 'C0C1C2C3C4C5C6C7C8C9CACBCCCDCECF', '51B1E5F44A197D1DA46B0F8E2D282AE871E838BB64DA8596574ADAA76FBD9FB0C5', '00000003020100A0A1A2A3A4A5', '0001020304050607', 8), ('0C0D0E0F101112131415161718191A1B1C1D1E', 'C0C1C2C3C4C5C6C7C8C9CACBCCCDCECF', 'A28C6865939A9A79FAAA5C4C2A9D4A91CDAC8C96C861B9C9E61EF1', '00000006050403A0A1A2A3A4A5', '000102030405060708090A0B', 8), ('0C0D0E0F101112131415161718191A1B1C1D1E1F', 'C0C1C2C3C4C5C6C7C8C9CACBCCCDCECF', 'DCF1FB7B5D9E23FB9D4E131253658AD86EBDCA3E51E83F077D9C2D93', '00000007060504A0A1A2A3A4A5', '000102030405060708090A0B', 8), ('0C0D0E0F101112131415161718191A1B1C1D1E1F20', 'C0C1C2C3C4C5C6C7C8C9CACBCCCDCECF', '6FC1B011F006568B5171A42D953D469B2570A4BD87405A0443AC91CB94', '00000008070605A0A1A2A3A4A5', '000102030405060708090A0B', 8), ('08090A0B0C0D0E0F101112131415161718191A1B1C1D1E', 'C0C1C2C3C4C5C6C7C8C9CACBCCCDCECF', '0135D1B2C95F41D5D1D4FEC185D166B8094E999DFED96C048C56602C97ACBB7490', '00000009080706A0A1A2A3A4A5', '0001020304050607', 10), ('08090A0B0C0D0E0F101112131415161718191A1B1C1D1E1F', 'C0C1C2C3C4C5C6C7C8C9CACBCCCDCECF', '7B75399AC0831DD2F0BBD75879A2FD8F6CAE6B6CD9B7DB24C17B4433F434963F34B4', '0000000A090807A0A1A2A3A4A5', '0001020304050607', 10), ('08E8CF97D820EA258460E96AD9CF5289054D895CEAC47C', 'D7828D13B2B0BDC325A76236DF93CC6B', '4CB97F86A2A4689A877947AB8091EF5386A6FFBDD080F8E78CF7CB0CDDD7B3', '00412B4EA9CDBE3C9696766CFA', '0BE1A88BACE018B1', 8), ('ABF21C0B02FEB88F856DF4A37381BCE3CC128517D4', 'D7828D13B2B0BDC325A76236DF93CC6B', 'F32905B88A641B04B9C9FFB58CC390900F3DA12AB16DCE9E82EFA16DA62059', '008D493B30AE8B3C9696766CFA', '6E37A6EF546D955D34AB6059', 10), ] aes_gcm_128 = [ ('00000000000000000000000000000000','000000000000000000000000','','','','58e2fccefa7e3061367f1d57a4e7455a'), ('00000000000000000000000000000000','000000000000000000000000','00000000000000000000000000000000','0388dace60b6a392f328c2b971b2fe78','','ab6e47d42cec13bdf53a67b21257bddf'), ('feffe9928665731c6d6a8f9467308308','cafebabefacedbaddecaf888','d9313225f88406e5a55909c5aff5269a86a7a9531534f7da2e4c303d8a318a721c3c0c95956809532fcf0e2449a6b525b16aedf5aa0de657ba637b391aafd255','42831ec2217774244b7221b784d0d49ce3aa212f2c02a4e035c17e2329aca12e21d514b25466931c7d8f6a5aac84aa051ba30b396a0aac973d58e091473f5985','','4d5c2af327cd64a62cf35abd2ba6fab4'), ('feffe9928665731c6d6a8f9467308308','cafebabefacedbaddecaf888','d9313225f88406e5a55909c5aff5269a86a7a9531534f7da2e4c303d8a318a721c3c0c95956809532fcf0e2449a6b525b16aedf5aa0de657ba637b39','42831ec2217774244b7221b784d0d49ce3aa212f2c02a4e035c17e2329aca12e21d514b25466931c7d8f6a5aac84aa051ba30b396a0aac973d58e091','feedfacedeadbeeffeedfacedeadbeefabaddad2','5bc94fbc3221a5db94fae95ae7121a47'), ('feffe9928665731c6d6a8f9467308308','cafebabefacedbad','d9313225f88406e5a55909c5aff5269a86a7a9531534f7da2e4c303d8a318a721c3c0c95956809532fcf0e2449a6b525b16aedf5aa0de657ba637b39','61353b4c2806934a777ff51fa22a4755699b2a714fcdc6f83766e5f97b6c742373806900e49f24b22b097544d4896b424989b5e1ebac0f07c23f4598','feedfacedeadbeeffeedfacedeadbeefabaddad2','3612d2e79e3b0785561be14aaca2fccb'), ('feffe9928665731c6d6a8f9467308308','9313225df88406e555909c5aff5269aa6a7a9538534f7da1e4c303d2a318a728c3c0c95156809539fcf0e2429a6b525416aedbf5a0de6a57a637b39b','d9313225f88406e5a55909c5aff5269a86a7a9531534f7da2e4c303d8a318a721c3c0c95956809532fcf0e2449a6b525b16aedf5aa0de657ba637b39','8ce24998625615b603a033aca13fb894be9112a5c3a211a8ba262a3cca7e2ca701e4a9a4fba43c90ccdcb281d48c7c6fd62875d2aca417034c34aee5','feedfacedeadbeeffeedfacedeadbeefabaddad2','619cc5aefffe0bfa462af43c1699d050'), ('00000000000000000000000000000000','000000000000000000000000','','','d9313225f88406e5a55909c5aff5269a86a7a9531534f7da2e4c303d8a318a721c3c0c95956809532fcf0e2449a6b525b16aedf5aa0de657ba637b391aafd255522dc1f099567d07f47f37a32a84427d643a8cdcbfe5c0c97598a2bd2555d1aa8cb08e48590dbb3da7b08b1056828838c5f61e6393ba7a0abcc9f662898015ad','5fea793a2d6f974d37e68e0cb8ff9492'), ('00000000000000000000000000000000','000000000000000000000000','000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000','0388dace60b6a392f328c2b971b2fe78f795aaab494b5923f7fd89ff948bc1e0200211214e7394da2089b6acd093abe0','','9dd0a376b08e40eb00c35f29f9ea61a4'), ('00000000000000000000000000000000','000000000000000000000000','0000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000','0388dace60b6a392f328c2b971b2fe78f795aaab494b5923f7fd89ff948bc1e0200211214e7394da2089b6acd093abe0c94da219118e297d7b7ebcbcc9c388f28ade7d85a8ee35616f7124a9d5270291','','98885a3a22bd4742fe7b72172193b163'), ('00000000000000000000000000000000','000000000000000000000000','0000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000','0388dace60b6a392f328c2b971b2fe78f795aaab494b5923f7fd89ff948bc1e0200211214e7394da2089b6acd093abe0c94da219118e297d7b7ebcbcc9c388f28ade7d85a8ee35616f7124a9d527029195b84d1b96c690ff2f2de30bf2ec89e00253786e126504f0dab90c48a30321de3345e6b0461e7c9e6c6b7afedde83f40','','cac45f60e31efd3b5a43b98a22ce1aa1'), ('00000000000000000000000000000000','ffffffff000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000','000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000','56b3373ca9ef6e4a2b64fe1e9a17b61425f10d47a75a5fce13efc6bc784af24f4141bdd48cf7c770887afd573cca5418a9aeffcd7c5ceddfc6a78397b9a85b499da558257267caab2ad0b23ca476a53cb17fb41c4b8b475cb4f3f7165094c229c9e8c4dc0a2a5ff1903e501511221376a1cdb8364c5061a20cae74bc4acd76ceb0abc9fd3217ef9f8c90be402ddf6d8697f4f880dff15bfb7a6b28241ec8fe183c2d59e3f9dfff653c7126f0acb9e64211f42bae12af462b1070bef1ab5e3606','','566f8ef683078bfdeeffa869d751a017'), ('843ffcf5d2b72694d19ed01d01249412','dbcca32ebf9b804617c3aa9e','000102030405060708090a0b0c0d0e0f101112131415161718191a1b1c1d1e1f202122232425262728292a2b2c2d2e2f303132333435363738393a3b3c3d3e3f404142434445464748494a4b4c4d4e4f','6268c6fa2a80b2d137467f092f657ac04d89be2beaa623d61b5a868c8f03ff95d3dcee23ad2f1ab3a6c80eaf4b140eb05de3457f0fbc111a6b43d0763aa422a3013cf1dc37fe417d1fbfc449b75d4cc5','00000000000000000000000000000000101112131415161718191a1b1c1d1e1f','3b629ccfbc1119b7319e1dce2cd6fd6d'), ] aes_gcm_256 = [ ('0000000000000000000000000000000000000000000000000000000000000000','000000000000000000000000','','','','530f8afbc74536b9a963b4f1c4cb738b'), ('0000000000000000000000000000000000000000000000000000000000000000','000000000000000000000000','00000000000000000000000000000000','cea7403d4d606b6e074ec5d3baf39d18','','d0d1c8a799996bf0265b98b5d48ab919'), ('feffe9928665731c6d6a8f9467308308feffe9928665731c6d6a8f9467308308','cafebabefacedbaddecaf888','d9313225f88406e5a55909c5aff5269a86a7a9531534f7da2e4c303d8a318a721c3c0c95956809532fcf0e2449a6b525b16aedf5aa0de657ba637b391aafd255','522dc1f099567d07f47f37a32a84427d643a8cdcbfe5c0c97598a2bd2555d1aa8cb08e48590dbb3da7b08b1056828838c5f61e6393ba7a0abcc9f662898015ad','','b094dac5d93471bdec1a502270e3cc6c'), ('feffe9928665731c6d6a8f9467308308feffe9928665731c6d6a8f9467308308','cafebabefacedbaddecaf888','d9313225f88406e5a55909c5aff5269a86a7a9531534f7da2e4c303d8a318a721c3c0c95956809532fcf0e2449a6b525b16aedf5aa0de657ba637b39','522dc1f099567d07f47f37a32a84427d643a8cdcbfe5c0c97598a2bd2555d1aa8cb08e48590dbb3da7b08b1056828838c5f61e6393ba7a0abcc9f662','feedfacedeadbeeffeedfacedeadbeefabaddad2','76fc6ece0f4e1768cddf8853bb2d551b'), ('feffe9928665731c6d6a8f9467308308feffe9928665731c6d6a8f9467308308','cafebabefacedbad','d9313225f88406e5a55909c5aff5269a86a7a9531534f7da2e4c303d8a318a721c3c0c95956809532fcf0e2449a6b525b16aedf5aa0de657ba637b39','c3762df1ca787d32ae47c13bf19844cbaf1ae14d0b976afac52ff7d79bba9de0feb582d33934a4f0954cc2363bc73f7862ac430e64abe499f47c9b1f','feedfacedeadbeeffeedfacedeadbeefabaddad2','3a337dbf46a792c45e454913fe2ea8f2'), ('feffe9928665731c6d6a8f9467308308feffe9928665731c6d6a8f9467308308','9313225df88406e555909c5aff5269aa6a7a9538534f7da1e4c303d2a318a728c3c0c95156809539fcf0e2429a6b525416aedbf5a0de6a57a637b39b','d9313225f88406e5a55909c5aff5269a86a7a9531534f7da2e4c303d8a318a721c3c0c95956809532fcf0e2449a6b525b16aedf5aa0de657ba637b39','5a8def2f0c9e53f1f75d7853659e2a20eeb2b22aafde6419a058ab4f6f746bf40fc0c3b780f244452da3ebf1c5d82cdea2418997200ef82e44ae7e3f','feedfacedeadbeeffeedfacedeadbeefabaddad2','a44a8266ee1c8eb0c8b5d4cf5ae9f19a'), ] def cfb_enc(cipherobj:symmetric.symmetricBASE, vector, segment_size = 8): data_total = b'' enc_data_total = b'' ctx = None key = None for i, res in enumerate(vector): plaintext, key, ciphertext, iv = res plaintext = bytes.fromhex(plaintext) key = bytes.fromhex(key) ciphertext = bytes.fromhex(ciphertext) iv = bytes.fromhex(iv) if i == 0: ctx = cipherobj(key, symmetric.MODE_CFB, iv, segment_size = segment_size) data_total += plaintext enc_data = ctx.encrypt(plaintext) enc_data_total += enc_data if enc_data != ciphertext: raise Exception('Ciphertext doesnt match to vector! CFB %s Cipher: \r\n%s \r\nVector: \r\n%s' % (i, enc_data.hex(), ciphertext.hex())) ctx = cipherobj(key, symmetric.MODE_CFB, iv, segment_size = segment_size) dec_data = ctx.decrypt(enc_data_total) if dec_data != data_total: raise Exception('Decrypted data doesnt match plaintext! CFB Cipher: \r\n%s \r\nPlaintext: \r\n%s' % (dec_data.hex(), plaintext.hex())) return True def cfb_8_enc(cipherobj:symmetric.symmetricBASE, vector, segment_size = 8): ctx = None for i, res in enumerate(vector): plaintext, key, ciphertext, iv = res plaintext = bytes.fromhex(plaintext) key = bytes.fromhex(key) ciphertext = bytes.fromhex(ciphertext) iv = bytes.fromhex(iv) ctx = cipherobj(key, symmetric.MODE_CFB, iv, segment_size = segment_size) enc_data = ctx.encrypt(plaintext) if enc_data != ciphertext: raise Exception('Ciphertext doesnt match to vector! CFB %s Cipher: \r\n%s \r\nVector: \r\n%s' % (i, enc_data.hex(), ciphertext.hex())) return True def ctr_enc(cipherobj:symmetric.symmetricBASE, vector): data_total = b'' enc_data_total = b'' ctx = None key = None for i, res in enumerate(vector): plaintext, key, ciphertext, iv = res plaintext = bytes.fromhex(plaintext.replace(' ', '')) key = bytes.fromhex(key.replace(' ', '')) ciphertext = bytes.fromhex(ciphertext.replace(' ', '')) iv = bytes.fromhex(iv.replace(' ', '')) if i == 0: ctx = cipherobj(key, symmetric.MODE_CTR, iv) data_total += plaintext enc_data = ctx.encrypt(plaintext) enc_data_total += enc_data if enc_data != ciphertext: raise Exception('Ciphertext doesnt match to vector! CTR %s Cipher: \r\n%s \r\nVector: \r\n%s' % (i, enc_data.hex(), ciphertext.hex())) ctx = cipherobj(key, symmetric.MODE_CTR, iv) dec_data = ctx.decrypt(enc_data_total) if dec_data != data_total: raise Exception('Decrypted data doesnt match plaintext! OFB Cipher: \r\n%s \r\nPlaintext: \r\n%s' % (dec_data.hex(), plaintext.hex())) return True def ofb_enc(cipherobj, vector): data_total = b'' enc_data_total = b'' ctx = None key = None for i, res in enumerate(vector): plaintext, key, ciphertext, iv = res plaintext = bytes.fromhex(plaintext) key = bytes.fromhex(key) ciphertext = bytes.fromhex(ciphertext) iv = bytes.fromhex(iv) if i == 0: ctx = cipherobj(key, symmetric.MODE_OFB, iv) data_total += plaintext enc_data = ctx.encrypt(plaintext) enc_data_total += enc_data if enc_data != ciphertext: raise Exception('Ciphertext doesnt match to vector! OFB %s Cipher: \r\n%s \r\nVector: \r\n%s' % (i, enc_data.hex(), ciphertext.hex())) ctx = cipherobj(key, symmetric.MODE_OFB, iv) dec_data = ctx.decrypt(enc_data_total) if dec_data != data_total: raise Exception('Decrypted data doesnt match plaintext! OFB Cipher: \r\n%s \r\nPlaintext: \r\n%s' % (dec_data.hex(), plaintext.hex())) return True def cbc_enc(cipherobj, vector): data_total = b'' enc_data_total = b'' ctx = None key = None for i, res in enumerate(vector): plaintext, key, ciphertext, iv = res plaintext = bytes.fromhex(plaintext) key = bytes.fromhex(key) ciphertext = bytes.fromhex(ciphertext) iv = bytes.fromhex(iv) if i == 0: ctx = cipherobj(key, symmetric.MODE_CBC, iv) data_total += plaintext enc_data = ctx.encrypt(plaintext) enc_data_total += enc_data if enc_data != ciphertext: raise Exception('Ciphertext doesnt match to vector! CBC %s Cipher: \r\n%s \r\nVector: \r\n%s' % (i, enc_data.hex(), ciphertext.hex())) ctx = cipherobj(key, symmetric.MODE_CBC, iv) dec_data = ctx.decrypt(enc_data_total) if dec_data != data_total: raise Exception('Decrypted data doesnt match plaintext! CBC Cipher: \r\n%s \r\nPlaintext: \r\n%s' % (dec_data.hex(), plaintext.hex())) return True def ccm_enc(cipherobj, vector): for i, res in enumerate(vector): plaintext, key, ciphertext, nonce,adata, asize = res plaintext = bytes.fromhex(plaintext) key = bytes.fromhex(key) ciphertext = bytes.fromhex(ciphertext) nonce = bytes.fromhex(nonce) adata = bytes.fromhex(adata) ctx = cipherobj(key, symmetric.MODE_CCM, nonce, segment_size=asize) enc_data, mac = ctx.encrypt(plaintext, adata) if (enc_data+mac) != ciphertext: raise Exception('Ciphertext doesnt match to vector! CCM %s Cipher: %s Vector: %s' % (i, enc_data, ciphertext)) ctx = cipherobj(key, symmetric.MODE_CCM, nonce, segment_size=asize) dec_data = ctx.decrypt(enc_data, adata, mac) if dec_data != plaintext: raise Exception('Decrypted data doesnt match plaintext! CCM %s Cipher: \r\n%s \r\nPlaintext: \r\n%s' % (i, dec_data.hex(), plaintext.hex())) return True def gcm_enc(cipherobj, vector, skip = 0): for i, res in enumerate(vector[skip:]): key, nonce, plaintext, ciphertext, adata, mac = res plaintext = bytes.fromhex(plaintext) key = bytes.fromhex(key) ciphertext = bytes.fromhex(ciphertext) nonce = bytes.fromhex(nonce) adata = bytes.fromhex(adata) mac = bytes.fromhex(mac) ctx = cipherobj(key, symmetric.MODE_GCM, nonce, segment_size=len(mac)) # size= 16 enc_data, mac_res = ctx.encrypt(plaintext, adata) if (enc_data+mac_res) != (ciphertext + mac): raise Exception('Ciphertext doesnt match to vector! GCM %s Cipher: %s Vector: %s' % (i, enc_data+mac_res, ciphertext + mac)) ctx = cipherobj(key, symmetric.MODE_GCM, nonce, segment_size=len(mac)) dec_data = ctx.decrypt(enc_data, adata, mac_res) if dec_data != plaintext: raise Exception('Decrypted data doesnt match plaintext! GCM %s Cipher: \r\n%s \r\nPlaintext: \r\n%s' % (i, dec_data.hex(), plaintext.hex())) return True def ecb_enc(cipherobj, vector): for i, res in enumerate(vector): plaintext, key, ciphertext = res plaintext = bytes.fromhex(plaintext) key = bytes.fromhex(key) ciphertext = bytes.fromhex(ciphertext) ctx = cipherobj(key, symmetric.MODE_ECB) if len(key) != len(plaintext): enc_data = b'' n = len(key) for chunk in [plaintext[i:i+n] for i in range(0, len(plaintext), n)]: enc_data += ctx.encrypt(chunk) else: enc_data = ctx.encrypt(plaintext) if enc_data != ciphertext: raise Exception('Ciphertext doesnt match to vector! ECB %s Cipher: %s Vector: %s' % (i, enc_data, ciphertext)) return True @pytest.mark.parametrize("cipherobj", [get_cipher_by_name('AES', 'pycryptodome')]) def test_ecb_128(cipherobj): ecb_enc(cipherobj, aes_128_ecb) @pytest.mark.parametrize("cipherobj", [get_cipher_by_name('AES', 'pycryptodome')]) def test_ecb_192(cipherobj): ecb_enc(cipherobj, aes_192_ecb) @pytest.mark.parametrize("cipherobj", [get_cipher_by_name('AES', 'pycryptodome')]) def test_ecb_256(cipherobj): ecb_enc(cipherobj, aes_256_ecb) @pytest.mark.parametrize("cipherobj", [get_cipher_by_name('AES', 'pycryptodome')]) def test_ecb_long(cipherobj): ecb_enc(cipherobj, aes_ecb_long) @pytest.mark.parametrize("cipherobj", [get_cipher_by_name('AES', 'pycryptodome')]) def test_cbc_128(cipherobj): cbc_enc(cipherobj, aes_cbc_128) @pytest.mark.parametrize("cipherobj", [get_cipher_by_name('AES', 'pycryptodome')]) def test_cbc_192(cipherobj): cbc_enc(cipherobj, aes_cbc_192) @pytest.mark.parametrize("cipherobj", [get_cipher_by_name('AES', 'pycryptodome')]) def test_cbc_256(cipherobj): cbc_enc(cipherobj, aes_cbc_256) @pytest.mark.parametrize("cipherobj", [get_cipher_by_name('AES', 'pycryptodome')]) def test_cbc_long(cipherobj): cbc_enc(cipherobj, aes_cbc_long) @pytest.mark.parametrize("cipherobj", [get_cipher_by_name('AES', 'pycryptodome')]) def test_cfb_fb1(cipherobj): cfb_8_enc(cipherobj, aes_cfb_feedbacksize_1, 8) @pytest.mark.parametrize("cipherobj", [get_cipher_by_name('AES', 'pycryptodome')]) def test_cfb_128_fb16(cipherobj): cfb_enc(cipherobj, aes_cfb_128_feedbacksize_16, 128) @pytest.mark.parametrize("cipherobj", [get_cipher_by_name('AES', 'pycryptodome')]) def test_cfb_192_fb16(cipherobj): cfb_enc(cipherobj, aes_cfb_192_feedbacksize_16, 128) @pytest.mark.parametrize("cipherobj", [get_cipher_by_name('AES', 'pycryptodome')]) def test_cfb_256_fb16(cipherobj): cfb_enc(cipherobj, aes_cfb_256_feedbacksize_16, 128) @pytest.mark.parametrize("cipherobj", [get_cipher_by_name('AES', 'pycryptodome')]) def test_cfb_long_fb16(cipherobj): cfb_enc(cipherobj, aes_cfb_long, 128) @pytest.mark.parametrize("cipherobj", [get_cipher_by_name('AES', 'pycryptodome')]) def test_ofb_128(cipherobj): ofb_enc(cipherobj, aes_ofb_128) @pytest.mark.parametrize("cipherobj", [get_cipher_by_name('AES', 'pycryptodome')]) def test_ofb_192(cipherobj): ofb_enc(cipherobj, aes_ofb_192) @pytest.mark.parametrize("cipherobj", [get_cipher_by_name('AES', 'pycryptodome')]) def test_ofb_256(cipherobj): ofb_enc(cipherobj, aes_ofb_256) @pytest.mark.parametrize("cipherobj", [get_cipher_by_name('AES', 'pycryptodome')]) def test_ofb_long(cipherobj): ofb_enc(cipherobj, aes_ofb_long) @pytest.mark.parametrize("cipherobj", [get_cipher_by_name('AES', 'pycryptodome')]) def test_ctr_128(cipherobj): ctr_enc(cipherobj, aes_ctr_128) @pytest.mark.parametrize("cipherobj", [get_cipher_by_name('AES', 'pycryptodome')]) def test_ctr_192(cipherobj): ctr_enc(cipherobj, aes_ctr_192) @pytest.mark.parametrize("cipherobj", [get_cipher_by_name('AES', 'pycryptodome')]) def test_ctr_256(cipherobj): ctr_enc(cipherobj, aes_ctr_256) @pytest.mark.parametrize("cipherobj", [get_cipher_by_name('AES', 'pycryptodome')]) def test_ctr_long(cipherobj): ctr_enc(cipherobj, aes_ctr_long) @pytest.mark.parametrize("cipherobj", [get_cipher_by_name('AES', 'pycryptodome')]) def test_ccm(cipherobj): ccm_enc(cipherobj, aes_ccm) @pytest.mark.parametrize("cipherobj", [get_cipher_by_name('AES', 'pycryptodome')]) def test_gcm_128(cipherobj): gcm_enc(cipherobj, aes_gcm_128) @pytest.mark.parametrize("cipherobj", [get_cipher_by_name('AES', 'pycryptodome')]) def test_gcm_256(cipherobj): gcm_enc(cipherobj, aes_gcm_256) @pytest.mark.parametrize("cipherobj", [get_cipher_by_name('AES', 'pycryptodomex')]) def test_ecb_128(cipherobj): ecb_enc(cipherobj, aes_128_ecb) @pytest.mark.parametrize("cipherobj", [get_cipher_by_name('AES', 'pycryptodomex')]) def test_ecb_192(cipherobj): ecb_enc(cipherobj, aes_192_ecb) @pytest.mark.parametrize("cipherobj", [get_cipher_by_name('AES', 'pycryptodomex')]) def test_ecb_256(cipherobj): ecb_enc(cipherobj, aes_256_ecb) @pytest.mark.parametrize("cipherobj", [get_cipher_by_name('AES', 'pycryptodomex')]) def test_ecb_long(cipherobj): ecb_enc(cipherobj, aes_ecb_long) @pytest.mark.parametrize("cipherobj", [get_cipher_by_name('AES', 'pycryptodomex')]) def test_cbc_128(cipherobj): cbc_enc(cipherobj, aes_cbc_128) @pytest.mark.parametrize("cipherobj", [get_cipher_by_name('AES', 'pycryptodomex')]) def test_cbc_192(cipherobj): cbc_enc(cipherobj, aes_cbc_192) @pytest.mark.parametrize("cipherobj", [get_cipher_by_name('AES', 'pycryptodomex')]) def test_cbc_256(cipherobj): cbc_enc(cipherobj, aes_cbc_256) @pytest.mark.parametrize("cipherobj", [get_cipher_by_name('AES', 'pycryptodomex')]) def test_cbc_long(cipherobj): cbc_enc(cipherobj, aes_cbc_long) @pytest.mark.parametrize("cipherobj", [get_cipher_by_name('AES', 'pycryptodomex')]) def test_cfb_fb1(cipherobj): cfb_8_enc(cipherobj, aes_cfb_feedbacksize_1, 8) @pytest.mark.parametrize("cipherobj", [get_cipher_by_name('AES', 'pycryptodomex')]) def test_cfb_128_fb16(cipherobj): cfb_enc(cipherobj, aes_cfb_128_feedbacksize_16, 128) @pytest.mark.parametrize("cipherobj", [get_cipher_by_name('AES', 'pycryptodomex')]) def test_cfb_192_fb16(cipherobj): cfb_enc(cipherobj, aes_cfb_192_feedbacksize_16, 128) @pytest.mark.parametrize("cipherobj", [get_cipher_by_name('AES', 'pycryptodomex')]) def test_cfb_256_fb16(cipherobj): cfb_enc(cipherobj, aes_cfb_256_feedbacksize_16, 128) @pytest.mark.parametrize("cipherobj", [get_cipher_by_name('AES', 'pycryptodomex')]) def test_cfb_long_fb16(cipherobj): cfb_enc(cipherobj, aes_cfb_long, 128) @pytest.mark.parametrize("cipherobj", [get_cipher_by_name('AES', 'pycryptodomex')]) def test_ofb_128(cipherobj): ofb_enc(cipherobj, aes_ofb_128) @pytest.mark.parametrize("cipherobj", [get_cipher_by_name('AES', 'pycryptodomex')]) def test_ofb_192(cipherobj): ofb_enc(cipherobj, aes_ofb_192) @pytest.mark.parametrize("cipherobj", [get_cipher_by_name('AES', 'pycryptodomex')]) def test_ofb_256(cipherobj): ofb_enc(cipherobj, aes_ofb_256) @pytest.mark.parametrize("cipherobj", [get_cipher_by_name('AES', 'pycryptodomex')]) def test_ofb_long(cipherobj): ofb_enc(cipherobj, aes_ofb_long) @pytest.mark.parametrize("cipherobj", [get_cipher_by_name('AES', 'pycryptodomex')]) def test_ctr_128(cipherobj): ctr_enc(cipherobj, aes_ctr_128) @pytest.mark.parametrize("cipherobj", [get_cipher_by_name('AES', 'pycryptodomex')]) def test_ctr_192(cipherobj): ctr_enc(cipherobj, aes_ctr_192) @pytest.mark.parametrize("cipherobj", [get_cipher_by_name('AES', 'pycryptodomex')]) def test_ctr_256(cipherobj): ctr_enc(cipherobj, aes_ctr_256) @pytest.mark.parametrize("cipherobj", [get_cipher_by_name('AES', 'pycryptodomex')]) def test_ctr_long(cipherobj): ctr_enc(cipherobj, aes_ctr_long) @pytest.mark.parametrize("cipherobj", [get_cipher_by_name('AES', 'pycryptodomex')]) def test_ccm(cipherobj): ccm_enc(cipherobj, aes_ccm) @pytest.mark.parametrize("cipherobj", [get_cipher_by_name('AES', 'pycryptodomex')]) def test_gcm_128(cipherobj): gcm_enc(cipherobj, aes_gcm_128) @pytest.mark.parametrize("cipherobj", [get_cipher_by_name('AES', 'pycryptodomex')]) def test_gcm_256(cipherobj): gcm_enc(cipherobj, aes_gcm_256) @pytest.mark.parametrize("cipherobj", [get_cipher_by_name('AES', 'cryptography')]) def test_ecb_128(cipherobj): ecb_enc(cipherobj, aes_128_ecb) @pytest.mark.parametrize("cipherobj", [get_cipher_by_name('AES', 'cryptography')]) def test_ecb_192(cipherobj): ecb_enc(cipherobj, aes_192_ecb) @pytest.mark.parametrize("cipherobj", [get_cipher_by_name('AES', 'cryptography')]) def test_ecb_256(cipherobj): ecb_enc(cipherobj, aes_256_ecb) @pytest.mark.parametrize("cipherobj", [get_cipher_by_name('AES', 'cryptography')]) def test_ecb_long(cipherobj): ecb_enc(cipherobj, aes_ecb_long) @pytest.mark.parametrize("cipherobj", [get_cipher_by_name('AES', 'cryptography')]) def test_cbc_128(cipherobj): cbc_enc(cipherobj, aes_cbc_128) @pytest.mark.parametrize("cipherobj", [get_cipher_by_name('AES', 'cryptography')]) def test_cbc_192(cipherobj): cbc_enc(cipherobj, aes_cbc_192) @pytest.mark.parametrize("cipherobj", [get_cipher_by_name('AES', 'cryptography')]) def test_cbc_256(cipherobj): cbc_enc(cipherobj, aes_cbc_256) @pytest.mark.parametrize("cipherobj", [get_cipher_by_name('AES', 'cryptography')]) def test_cbc_long(cipherobj): cbc_enc(cipherobj, aes_cbc_long) @pytest.mark.parametrize("cipherobj", [get_cipher_by_name('AES', 'cryptography')]) def test_cfb_fb1(cipherobj): cfb_8_enc(cipherobj, aes_cfb_feedbacksize_1, 8) @pytest.mark.parametrize("cipherobj", [get_cipher_by_name('AES', 'cryptography')]) def test_cfb_128_fb16(cipherobj): cfb_enc(cipherobj, aes_cfb_128_feedbacksize_16, 128) @pytest.mark.parametrize("cipherobj", [get_cipher_by_name('AES', 'cryptography')]) def test_cfb_192_fb16(cipherobj): cfb_enc(cipherobj, aes_cfb_192_feedbacksize_16, 128) @pytest.mark.parametrize("cipherobj", [get_cipher_by_name('AES', 'cryptography')]) def test_cfb_256_fb16(cipherobj): cfb_enc(cipherobj, aes_cfb_256_feedbacksize_16, 128) @pytest.mark.parametrize("cipherobj", [get_cipher_by_name('AES', 'cryptography')]) def test_cfb_long_fb16(cipherobj): cfb_enc(cipherobj, aes_cfb_long, 128) @pytest.mark.parametrize("cipherobj", [get_cipher_by_name('AES', 'cryptography')]) def test_ofb_128(cipherobj): ofb_enc(cipherobj, aes_ofb_128) @pytest.mark.parametrize("cipherobj", [get_cipher_by_name('AES', 'cryptography')]) def test_ofb_192(cipherobj): ofb_enc(cipherobj, aes_ofb_192) @pytest.mark.parametrize("cipherobj", [get_cipher_by_name('AES', 'cryptography')]) def test_ofb_256(cipherobj): ofb_enc(cipherobj, aes_ofb_256) @pytest.mark.parametrize("cipherobj", [get_cipher_by_name('AES', 'cryptography')]) def test_ofb_long(cipherobj): ofb_enc(cipherobj, aes_ofb_long) @pytest.mark.parametrize("cipherobj", [get_cipher_by_name('AES', 'cryptography')]) def test_ctr_128(cipherobj): ctr_enc(cipherobj, aes_ctr_128) @pytest.mark.parametrize("cipherobj", [get_cipher_by_name('AES', 'cryptography')]) def test_ctr_192(cipherobj): ctr_enc(cipherobj, aes_ctr_192) @pytest.mark.parametrize("cipherobj", [get_cipher_by_name('AES', 'cryptography')]) def test_ctr_256(cipherobj): ctr_enc(cipherobj, aes_ctr_256) @pytest.mark.parametrize("cipherobj", [get_cipher_by_name('AES', 'cryptography')]) def test_ctr_long(cipherobj): ctr_enc(cipherobj, aes_ctr_long) @pytest.mark.parametrize("cipherobj", [get_cipher_by_name('AES', 'cryptography')]) def test_ccm(cipherobj): ccm_enc(cipherobj, aes_ccm) @pytest.mark.parametrize("cipherobj", [get_cipher_by_name('AES', 'cryptography')]) def test_gcm_128(cipherobj): gcm_enc(cipherobj, aes_gcm_128) @pytest.mark.parametrize("cipherobj", [get_cipher_by_name('AES', 'cryptography')]) def test_gcm_256(cipherobj): gcm_enc(cipherobj, aes_gcm_256) #@pytest.mark.parametrize("cipherobj", [get_cipher_by_name('AES', 'crypto')]) #def test_ecb_128(cipherobj): # ecb_enc(cipherobj, aes_128_ecb) # #@pytest.mark.parametrize("cipherobj", [get_cipher_by_name('AES', 'crypto')]) #def test_ecb_192(cipherobj): # ecb_enc(cipherobj, aes_192_ecb) # #@pytest.mark.parametrize("cipherobj", [get_cipher_by_name('AES', 'crypto')]) #def test_ecb_256(cipherobj): # ecb_enc(cipherobj, aes_256_ecb) # #@pytest.mark.parametrize("cipherobj", [get_cipher_by_name('AES', 'crypto')]) #def test_ecb_long(cipherobj): # ecb_enc(cipherobj, aes_ecb_long) # #@pytest.mark.parametrize("cipherobj", [get_cipher_by_name('AES', 'crypto')]) #def test_cbc_128(cipherobj): # cbc_enc(cipherobj, aes_cbc_128) # #@pytest.mark.parametrize("cipherobj", [get_cipher_by_name('AES', 'crypto')]) #def test_cbc_192(cipherobj): # cbc_enc(cipherobj, aes_cbc_192) # #@pytest.mark.parametrize("cipherobj", [get_cipher_by_name('AES', 'crypto')]) #def test_cbc_256(cipherobj): # cbc_enc(cipherobj, aes_cbc_256) # #@pytest.mark.parametrize("cipherobj", [get_cipher_by_name('AES', 'crypto')]) #def test_cbc_long(cipherobj): # cbc_enc(cipherobj, aes_cbc_long) # #@pytest.mark.parametrize("cipherobj", [get_cipher_by_name('AES', 'crypto')]) #def test_cfb_fb1(cipherobj): # cfb_8_enc(cipherobj, aes_cfb_feedbacksize_1, 8) # #@pytest.mark.parametrize("cipherobj", [get_cipher_by_name('AES', 'crypto')]) #def test_cfb_128_fb16(cipherobj): # cfb_enc(cipherobj, aes_cfb_128_feedbacksize_16, 128) # #@pytest.mark.parametrize("cipherobj", [get_cipher_by_name('AES', 'crypto')]) #def test_cfb_192_fb16(cipherobj): # cfb_enc(cipherobj, aes_cfb_192_feedbacksize_16, 128) # #@pytest.mark.parametrize("cipherobj", [get_cipher_by_name('AES', 'crypto')]) #def test_cfb_256_fb16(cipherobj): # cfb_enc(cipherobj, aes_cfb_256_feedbacksize_16, 128) # #@pytest.mark.parametrize("cipherobj", [get_cipher_by_name('AES', 'crypto')]) #def test_cfb_long_fb16(cipherobj): # cfb_enc(cipherobj, aes_cfb_long, 128) # #@pytest.mark.parametrize("cipherobj", [get_cipher_by_name('AES', 'crypto')]) #def test_ofb_128(cipherobj): # ofb_enc(cipherobj, aes_ofb_128) # #@pytest.mark.parametrize("cipherobj", [get_cipher_by_name('AES', 'crypto')]) #def test_ofb_192(cipherobj): # ofb_enc(cipherobj, aes_ofb_192) # #@pytest.mark.parametrize("cipherobj", [get_cipher_by_name('AES', 'crypto')]) #def test_ofb_256(cipherobj): # ofb_enc(cipherobj, aes_ofb_256) # #@pytest.mark.parametrize("cipherobj", [get_cipher_by_name('AES', 'crypto')]) #def test_ofb_long(cipherobj): # ofb_enc(cipherobj, aes_ofb_long) # #@pytest.mark.parametrize("cipherobj", [get_cipher_by_name('AES', 'crypto')]) #def test_ctr_128(cipherobj): # ctr_enc(cipherobj, aes_ctr_128) # #@pytest.mark.parametrize("cipherobj", [get_cipher_by_name('AES', 'crypto')]) #def test_ctr_192(cipherobj): # ctr_enc(cipherobj, aes_ctr_192) # #@pytest.mark.parametrize("cipherobj", [get_cipher_by_name('AES', 'crypto')]) #def test_ctr_256(cipherobj): # ctr_enc(cipherobj, aes_ctr_256) # #@pytest.mark.parametrize("cipherobj", [get_cipher_by_name('AES', 'crypto')]) #def test_ctr_long(cipherobj): # ctr_enc(cipherobj, aes_ctr_long) # #@pytest.mark.parametrize("cipherobj", [get_cipher_by_name('AES', 'crypto')]) #def test_ccm(cipherobj): # ccm_enc(cipherobj, aes_ccm) # #@pytest.mark.parametrize("cipherobj", [get_cipher_by_name('AES', 'crypto')]) #def test_gcm_128(cipherobj): # gcm_enc(cipherobj, aes_gcm_128) # #@pytest.mark.parametrize("cipherobj", [get_cipher_by_name('AES', 'crypto')]) #def test_gcm_256(cipherobj): # gcm_enc(cipherobj, aes_gcm_256) # # @pytest.mark.parametrize("cipherobj", [get_cipher_by_name('AES', 'pure')]) def test_ecb_128(cipherobj): ecb_enc(cipherobj, aes_128_ecb) @pytest.mark.parametrize("cipherobj", [get_cipher_by_name('AES', 'pure')]) def test_ecb_192(cipherobj): ecb_enc(cipherobj, aes_192_ecb) @pytest.mark.parametrize("cipherobj", [get_cipher_by_name('AES', 'pure')]) def test_ecb_256(cipherobj): ecb_enc(cipherobj, aes_256_ecb) @pytest.mark.parametrize("cipherobj", [get_cipher_by_name('AES', 'pure')]) def test_ecb_long(cipherobj): ecb_enc(cipherobj, aes_ecb_long) @pytest.mark.parametrize("cipherobj", [get_cipher_by_name('AES', 'pure')]) def test_cbc_128(cipherobj): cbc_enc(cipherobj, aes_cbc_128) @pytest.mark.parametrize("cipherobj", [get_cipher_by_name('AES', 'pure')]) def test_cbc_192(cipherobj): cbc_enc(cipherobj, aes_cbc_192) @pytest.mark.parametrize("cipherobj", [get_cipher_by_name('AES', 'pure')]) def test_cbc_256(cipherobj): cbc_enc(cipherobj, aes_cbc_256) @pytest.mark.parametrize("cipherobj", [get_cipher_by_name('AES', 'pure')]) def test_cbc_long(cipherobj): cbc_enc(cipherobj, aes_cbc_long) @pytest.mark.parametrize("cipherobj", [get_cipher_by_name('AES', 'pure')]) def test_cfb_fb1(cipherobj): cfb_8_enc(cipherobj, aes_cfb_feedbacksize_1, 8) @pytest.mark.parametrize("cipherobj", [get_cipher_by_name('AES', 'pure')]) def test_cfb_128_fb16(cipherobj): cfb_enc(cipherobj, aes_cfb_128_feedbacksize_16, 128) @pytest.mark.parametrize("cipherobj", [get_cipher_by_name('AES', 'pure')]) def test_cfb_192_fb16(cipherobj): cfb_enc(cipherobj, aes_cfb_192_feedbacksize_16, 128) @pytest.mark.parametrize("cipherobj", [get_cipher_by_name('AES', 'pure')]) def test_cfb_256_fb16(cipherobj): cfb_enc(cipherobj, aes_cfb_256_feedbacksize_16, 128) @pytest.mark.parametrize("cipherobj", [get_cipher_by_name('AES', 'pure')]) def test_cfb_long_fb16(cipherobj): cfb_enc(cipherobj, aes_cfb_long, 128) @pytest.mark.parametrize("cipherobj", [get_cipher_by_name('AES', 'pure')]) def test_ofb_128(cipherobj): ofb_enc(cipherobj, aes_ofb_128) @pytest.mark.parametrize("cipherobj", [get_cipher_by_name('AES', 'pure')]) def test_ofb_192(cipherobj): ofb_enc(cipherobj, aes_ofb_192) @pytest.mark.parametrize("cipherobj", [get_cipher_by_name('AES', 'pure')]) def test_ofb_256(cipherobj): ofb_enc(cipherobj, aes_ofb_256) @pytest.mark.parametrize("cipherobj", [get_cipher_by_name('AES', 'pure')]) def test_ofb_long(cipherobj): ofb_enc(cipherobj, aes_ofb_long) @pytest.mark.parametrize("cipherobj", [get_cipher_by_name('AES', 'pure')]) def test_ctr_128(cipherobj): ctr_enc(cipherobj, aes_ctr_128) @pytest.mark.parametrize("cipherobj", [get_cipher_by_name('AES', 'pure')]) def test_ctr_192(cipherobj): ctr_enc(cipherobj, aes_ctr_192) @pytest.mark.parametrize("cipherobj", [get_cipher_by_name('AES', 'pure')]) def test_ctr_256(cipherobj): ctr_enc(cipherobj, aes_ctr_256) @pytest.mark.parametrize("cipherobj", [get_cipher_by_name('AES', 'pure')]) def test_ctr_long(cipherobj): ctr_enc(cipherobj, aes_ctr_long) @pytest.mark.parametrize("cipherobj", [get_cipher_by_name('AES', 'pure')]) def test_ccm(cipherobj): ccm_enc(cipherobj, aes_ccm) @pytest.mark.parametrize("cipherobj", [get_cipher_by_name('AES', 'pure')]) def test_gcm_128(cipherobj): gcm_enc(cipherobj, aes_gcm_128) @pytest.mark.parametrize("cipherobj", [get_cipher_by_name('AES', 'pure')]) def test_gcm_256(cipherobj): gcm_enc(cipherobj, aes_gcm_256) @pytest.mark.parametrize("cipherobj", [get_cipher_by_name('AES', 'mbedtls')]) def test_ecb_128(cipherobj): ecb_enc(cipherobj, aes_128_ecb) @pytest.mark.parametrize("cipherobj", [get_cipher_by_name('AES', 'mbedtls')]) def test_ecb_192(cipherobj): ecb_enc(cipherobj, aes_192_ecb) @pytest.mark.parametrize("cipherobj", [get_cipher_by_name('AES', 'mbedtls')]) def test_ecb_256(cipherobj): ecb_enc(cipherobj, aes_256_ecb) @pytest.mark.parametrize("cipherobj", [get_cipher_by_name('AES', 'mbedtls')]) def test_ecb_long(cipherobj): ecb_enc(cipherobj, aes_ecb_long) @pytest.mark.parametrize("cipherobj", [get_cipher_by_name('AES', 'mbedtls')]) def test_cbc_128(cipherobj): cbc_enc(cipherobj, aes_cbc_128) @pytest.mark.parametrize("cipherobj", [get_cipher_by_name('AES', 'mbedtls')]) def test_cbc_192(cipherobj): cbc_enc(cipherobj, aes_cbc_192) @pytest.mark.parametrize("cipherobj", [get_cipher_by_name('AES', 'mbedtls')]) def test_cbc_256(cipherobj): cbc_enc(cipherobj, aes_cbc_256) @pytest.mark.parametrize("cipherobj", [get_cipher_by_name('AES', 'mbedtls')]) def test_cbc_long(cipherobj): cbc_enc(cipherobj, aes_cbc_long) #@pytest.mark.parametrize("cipherobj", [get_cipher_by_name('AES', 'mbedtls')]) #def test_cfb_fb1(cipherobj): # cfb_8_enc(cipherobj, aes_cfb_feedbacksize_1, 8) @pytest.mark.parametrize("cipherobj", [get_cipher_by_name('AES', 'mbedtls')]) def test_cfb_128_fb16(cipherobj): cfb_enc(cipherobj, aes_cfb_128_feedbacksize_16, 128) @pytest.mark.parametrize("cipherobj", [get_cipher_by_name('AES', 'mbedtls')]) def test_cfb_192_fb16(cipherobj): cfb_enc(cipherobj, aes_cfb_192_feedbacksize_16, 128) @pytest.mark.parametrize("cipherobj", [get_cipher_by_name('AES', 'mbedtls')]) def test_cfb_256_fb16(cipherobj): cfb_enc(cipherobj, aes_cfb_256_feedbacksize_16, 128) @pytest.mark.parametrize("cipherobj", [get_cipher_by_name('AES', 'mbedtls')]) def test_cfb_long_fb16(cipherobj): cfb_enc(cipherobj, aes_cfb_long, 128) @pytest.mark.parametrize("cipherobj", [get_cipher_by_name('AES', 'mbedtls')]) def test_ofb_128(cipherobj): ofb_enc(cipherobj, aes_ofb_128) @pytest.mark.parametrize("cipherobj", [get_cipher_by_name('AES', 'mbedtls')]) def test_ofb_192(cipherobj): ofb_enc(cipherobj, aes_ofb_192) @pytest.mark.parametrize("cipherobj", [get_cipher_by_name('AES', 'mbedtls')]) def test_ofb_256(cipherobj): ofb_enc(cipherobj, aes_ofb_256) @pytest.mark.parametrize("cipherobj", [get_cipher_by_name('AES', 'mbedtls')]) def test_ofb_long(cipherobj): ofb_enc(cipherobj, aes_ofb_long) @pytest.mark.parametrize("cipherobj", [get_cipher_by_name('AES', 'mbedtls')]) def test_ctr_128(cipherobj): ctr_enc(cipherobj, aes_ctr_128) @pytest.mark.parametrize("cipherobj", [get_cipher_by_name('AES', 'mbedtls')]) def test_ctr_192(cipherobj): ctr_enc(cipherobj, aes_ctr_192) @pytest.mark.parametrize("cipherobj", [get_cipher_by_name('AES', 'mbedtls')]) def test_ctr_256(cipherobj): ctr_enc(cipherobj, aes_ctr_256) @pytest.mark.parametrize("cipherobj", [get_cipher_by_name('AES', 'mbedtls')]) def test_ctr_long(cipherobj): ctr_enc(cipherobj, aes_ctr_long) @pytest.mark.parametrize("cipherobj", [get_cipher_by_name('AES', 'mbedtls')]) def test_ccm(cipherobj): ccm_enc(cipherobj, aes_ccm) #@pytest.mark.parametrize("cipherobj", [get_cipher_by_name('AES', 'mbedtls')]) #def test_gcm_128(cipherobj): # gcm_enc(cipherobj, aes_gcm_128) # #@pytest.mark.parametrize("cipherobj", [get_cipher_by_name('AES', 'mbedtls')]) #def test_gcm_256(cipherobj): # gcm_enc(cipherobj, aes_gcm_256) unicrypto-0.0.10/tests/test_des.py000066400000000000000000000071551437177004600171730ustar00rootroot00000000000000 import pytest from unicrypto import get_cipher_by_name from unicrypto import symmetric des_ecb = [ ('0000000000000000', '0000000000000000', '8CA64DE9C1B123A7'), ('FFFFFFFFFFFFFFFF', 'FFFFFFFFFFFFFFFF', '7359B2163E4EDC58'), ('3000000000000000', '1000000000000001', '958E6E627A05557B'), ('1111111111111111', '1111111111111111', 'F40379AB9E0EC533'), ('0123456789ABCDEF', '1111111111111111', '17668DFC7292532D'), ('1111111111111111', '0123456789ABCDEF', '8A5AE1F81AB8F2DD'), ('FEDCBA9876543210', '0123456789ABCDEF', 'ED39D950FA74BCC4'), ('FEDCBA9876543210', '0123456789ABCDEF0123456789ABCDEF', 'ED39D950FA74BCC4ED39D950FA74BCC4'), ] des_cbc = [ ('0123456789abcdef','fedcba9876543210' , '37363534333231204E6F77206973207468652074696D6520', 'ccd173ffab2039f4acd8aefddfd8a1eb468e91157888ba68'), ] def ecb_enc(cipherobj:symmetric.symmetricBASE, vector): for i, res in enumerate(vector): key, plaintext, ciphertext = res plaintext = bytes.fromhex(plaintext) key = bytes.fromhex(key) ciphertext = bytes.fromhex(ciphertext) ctx = cipherobj(key) enc_data = ctx.encrypt(plaintext) if enc_data != ciphertext: raise Exception('Ciphertext doesnt match to vector! DES %s Cipher: \r\n%s \r\nVector: \r\n%s' % (i, enc_data, ciphertext)) ctx = cipherobj(key) dec_data = ctx.decrypt(enc_data) if dec_data != plaintext: raise Exception('Decrypted data doesnt match plaintext! DES-ECB Cipher: \r\n%s \r\nPlaintext: \r\n%s' % (dec_data.hex(), plaintext.hex())) return True def cbc_enc(cipherobj:symmetric.symmetricBASE, vector): for i, res in enumerate(vector): key, iv, plaintext, ciphertext = res plaintext = bytes.fromhex(plaintext) key = bytes.fromhex(key) ciphertext = bytes.fromhex(ciphertext) iv = bytes.fromhex(iv) ctx = cipherobj(key, symmetric.MODE_CBC, iv) enc_data = ctx.encrypt(plaintext) if enc_data != ciphertext: raise Exception('Ciphertext doesnt match to vector! DES %s Cipher: \r\n%s \r\nVector: \r\n%s' % (i, enc_data, ciphertext)) ctx = cipherobj(key, symmetric.MODE_CBC, iv) dec_data = ctx.decrypt(enc_data) if dec_data != plaintext: raise Exception('Decrypted data doesnt match plaintext! DES-CBC Cipher: \r\n%s \r\nPlaintext: \r\n%s' % (dec_data.hex(), plaintext.hex())) return True @pytest.mark.parametrize("cipherobj", [get_cipher_by_name('DES', 'pure')]) def test_ecb(cipherobj): from unicrypto.backends.pure import DES assert isinstance(cipherobj, DES) ecb_enc(cipherobj, des_ecb) @pytest.mark.parametrize("cipherobj", [get_cipher_by_name('DES', 'pure')]) def test_cbc(cipherobj): cbc_enc(cipherobj, des_cbc) #@pytest.mark.parametrize("cipherobj", [get_cipher_by_name('DES', 'crypto')]) #def test_ecb(cipherobj): # ecb_enc(cipherobj, des_ecb) # #@pytest.mark.parametrize("cipherobj", [get_cipher_by_name('DES', 'crypto')]) #def test_cbc(cipherobj): # cbc_enc(cipherobj, des_cbc) @pytest.mark.parametrize("cipherobj", [get_cipher_by_name('DES', 'pycryptodome')]) def test_ecb(cipherobj): ecb_enc(cipherobj, des_ecb) @pytest.mark.parametrize("cipherobj", [get_cipher_by_name('DES', 'pycryptodome')]) def test_cbc(cipherobj): cbc_enc(cipherobj, des_cbc) @pytest.mark.parametrize("cipherobj", [get_cipher_by_name('DES', 'cryptography')]) def test_ecb(cipherobj): ecb_enc(cipherobj, des_ecb) @pytest.mark.parametrize("cipherobj", [get_cipher_by_name('DES', 'cryptography')]) def test_cbc(cipherobj): cbc_enc(cipherobj, des_cbc) @pytest.mark.parametrize("cipherobj", [get_cipher_by_name('DES', 'mbedtls')]) def test_ecb(cipherobj): ecb_enc(cipherobj, des_ecb) @pytest.mark.parametrize("cipherobj", [get_cipher_by_name('DES', 'mbedtls')]) def test_cbc(cipherobj): cbc_enc(cipherobj, des_cbc) unicrypto-0.0.10/tests/test_import.py000066400000000000000000000115031437177004600177220ustar00rootroot00000000000000from unicrypto import get_cipher_by_name def test_aes_mbedtls(): obj = get_cipher_by_name('AES', 'mbedtls') if str(obj).find('unicrypto.backends.mbedtls.AES') == -1: raise Exception('Wrong backend selected!') def test_aes_pycryptodome(): obj = get_cipher_by_name('AES', 'pycryptodome') if str(obj).find('unicrypto.backends.pycryptodome.AES') == -1: raise Exception('Wrong backend selected!') def test_aes_pycryptodome(): obj = get_cipher_by_name('AES', 'pycryptodomex') if str(obj).find('unicrypto.backends.pycryptodomex.AES') == -1: raise Exception('Wrong backend selected!') def test_aes_cryptography(): obj = get_cipher_by_name('AES', 'cryptography') if str(obj).find('unicrypto.backends.cryptography.AES') == -1: raise Exception('Wrong backend selected!') def test_aes_pure(): obj = get_cipher_by_name('AES', 'pure') if str(obj).find('unicrypto.backends.pure.AES') == -1: raise Exception('Wrong backend selected!') def test_rc4_mbedtls(): obj = get_cipher_by_name('RC4', 'mbedtls') if str(obj).find('unicrypto.backends.mbedtls.RC4') == -1: raise Exception('Wrong backend selected!') def test_rc4_pycryptodome(): obj = get_cipher_by_name('RC4', 'pycryptodome') if str(obj).find('unicrypto.backends.pycryptodome.RC4') == -1: raise Exception('Wrong backend selected!') def test_rc4_cryptography(): obj = get_cipher_by_name('RC4', 'cryptography') if str(obj).find('unicrypto.backends.cryptography.RC4') == -1: raise Exception('Wrong backend selected!') def test_rc4_pure(): obj = get_cipher_by_name('RC4', 'pure') if str(obj).find('unicrypto.backends.pure.RC4') == -1: raise Exception('Wrong backend selected!') def test_rc4_pycryptodomex(): obj = get_cipher_by_name('RC4', 'pycryptodomex') if str(obj).find('unicrypto.backends.pycryptodomex.RC4') == -1: raise Exception('Wrong backend selected!') def test_des_mbedtls(): obj = get_cipher_by_name('DES', 'mbedtls') if str(obj).find('unicrypto.backends.mbedtls.DES') == -1: raise Exception('Wrong backend selected!') def test_des_pycryptodome(): obj = get_cipher_by_name('DES', 'pycryptodome') if str(obj).find('unicrypto.backends.pycryptodome.DES') == -1: raise Exception('Wrong backend selected!') def test_des_cryptography(): obj = get_cipher_by_name('DES', 'cryptography') if str(obj).find('unicrypto.backends.cryptography.DES') == -1: raise Exception('Wrong backend selected!') def test_des_pure(): obj = get_cipher_by_name('DES', 'pure') if str(obj).find('unicrypto.backends.pure.DES') == -1: raise Exception('Wrong backend selected!') def test_des_pycryptodomex(): obj = get_cipher_by_name('DES', 'pycryptodomex') if str(obj).find('unicrypto.backends.pycryptodomex.DES') == -1: raise Exception('Wrong backend selected!') def test_tdes_mbedtls(): obj = get_cipher_by_name('TDES', 'mbedtls') if str(obj).find('unicrypto.backends.mbedtls.TDES') == -1: raise Exception('Wrong backend selected!') def test_tdes_pycryptodome(): obj = get_cipher_by_name('TDES', 'pycryptodome') if str(obj).find('unicrypto.backends.pycryptodome.TDES') == -1: raise Exception('Wrong backend selected!') def test_tdes_cryptography(): obj = get_cipher_by_name('TDES', 'cryptography') if str(obj).find('unicrypto.backends.cryptography.TDES') == -1: raise Exception('Wrong backend selected!') def test_tdes_pure(): obj = get_cipher_by_name('TDES', 'pure') if str(obj).find('unicrypto.backends.pure.TDES') == -1: raise Exception('Wrong backend selected!') def test_tdes_pycryptodomex(): obj = get_cipher_by_name('TDES', 'pycryptodomex') if str(obj).find('unicrypto.backends.pycryptodomex.TDES') == -1: raise Exception('Wrong backend selected!') def test_rc4_mbedtls(): obj = get_cipher_by_name('RC4', 'mbedtls') if str(obj).find('unicrypto.backends.mbedtls.RC4') == -1: raise Exception('Wrong backend selected!') def test_rc4_pycryptodome(): obj = get_cipher_by_name('RC4', 'pycryptodome') if str(obj).find('unicrypto.backends.pycryptodome.RC4') == -1: raise Exception('Wrong backend selected!') def test_rc4_cryptography(): obj = get_cipher_by_name('RC4', 'cryptography') if str(obj).find('unicrypto.backends.cryptography.RC4') == -1: raise Exception('Wrong backend selected!') def test_rc4_pure(): obj = get_cipher_by_name('RC4', 'pure') if str(obj).find('unicrypto.backends.pure.RC4') == -1: raise Exception('Wrong backend selected!') def test_rc4_pycryptodomex(): obj = get_cipher_by_name('RC4', 'pycryptodomex') if str(obj).find('unicrypto.backends.pycryptodomex.RC4') == -1: raise Exception('Wrong backend selected!') if __name__ == '__main__': test_aes_mbedtls()unicrypto-0.0.10/tests/test_pbkdf2.py000066400000000000000000000022751437177004600175660ustar00rootroot00000000000000import pytest from unicrypto import hashlib from unicrypto.pbkdf2 import pbkdf2 #https://www.ietf.org/rfc/rfc6070.txt pbkdf2_sha1_test = [ ('password', 'salt', 1, 20, '0c60c80f961f0e71f3a9b524af6012062fe037a6'), ('password', 'salt', 2, 20, 'ea6c014dc72d6f8ccd1ed92ace1d41f0d8de8957'), ('password', 'salt', 4096, 20, '4b007901b765489abead49d926f721d065a429c1'), #('password', 'salt', 16777216, 20, 'eefe3d61cd4da4e4e9945b3d6ba2158c2634e984'), #takes too long ('passwordPASSWORDpassword', 'saltSALTsaltSALTsaltSALTsaltSALTsalt',4096, 25, '3d2eec4fe41c849b80c8d83662c0e44a8b291a964cf2f07038'), ('pass\0word', 'sa\0lt', 4096, 16, '56fa6aa75548099dcc37d7f03425e0c3'), ] def pbkdf2_tester(hashobj, vector): for i, res in enumerate(vector): password, salt, iters, keylen, ciphertext = res password = password.encode() salt = salt.encode() ciphertext = bytes.fromhex(ciphertext) hashed_data = pbkdf2(password, salt, iters, keylen, digestmod = hashobj) if hashed_data != ciphertext: raise Exception('Digest mismatch! SHA1 %s Cipher: \r\n%s \r\nVector: \r\n%s' % (i, hashed_data, ciphertext)) return True def test_sha1(): hashobj = hashlib.sha1 pbkdf2_tester(hashobj, pbkdf2_sha1_test) unicrypto-0.0.10/tests/test_rc4.py000066400000000000000000000247171437177004600171130ustar00rootroot00000000000000 import pytest from unicrypto import get_cipher_by_name from unicrypto import symmetric rc4_vectors = [ # key, plaintext, ciphertext ('0102030405','00','b2396305f03dc027ccc3524a0a1118a86982944f18fc82d589c403a47a0d091928cb1132c96ce286421dcaadb8b69eae1cfcf62b03eddb641d77dfcf7f8d8c9342b7d0cdd918a8a33dd51781c81f40416459844432a7da923cfb3eb4980661f6ec10327bde2beefd18f9277680457e22eb62638d4f0ba1fe9fca20e05bf8ff2b45129048e6a0ed0b56b490338f078da530abbcc7c20b01609f23ee2d5f6bb7df3294f744d8f9790507e70f62e5bbceead8729db41882259bee4f825325f5a1301eb14a0c13b3bf47fa2a0ba93ad45b8bcc582f8ba9f265e2b1be9112e975d2d7f2e30f9bd102ecbf75aaade9bc35c43cec0e11c479dc329dc8da7968fe965681068326a2118416d21f9d04b2cd1ca050ff25b58995996707e51fbdf08b34d875'), ('01020304050607','00','293f02d47f37c9b633f2af5285feb46be620f1390d19bd84e2e0fd752031afc1914f02531c9218810df60f67e338154cd0fdb583073ce85ab83917740ec011d575f81411e871cffa70b90c74c592e4540bb87202938dad609e87a5a1b079e5e4c2911246b612e7e7b903dfeda1dad86632828f91502b6291368de8081de36fc2f3b9a7e3b297bf9ad804512f9063eff18ecb67a9ba1f55a5a067e2b026a3676fd2aa902bd42d0d7cfd340cd45810529f78b272c96e42eab4c60bd914e39d06e3f4332fd31a079396ee3cee3f2a4ff04905459781d41fda7f30c1be7e1246c623adfd3868b8e51485d5e610017e3dd609ad26581c0c5be45f4cea01db2f3805d5f3172ceffc3b3d997c85ccd5af1a950ce74b0b9731227fd37c0ec08a47ddd8b8'), ('0102030405060708','00','97ab8a1bf0afb96132f2f67258da15a88263efdb45c4a18684ef87e6b19e5b099636ebc9841926f4f7d1f362bddf6e18d0a990ff2c05fef5b90373c9ff4b870a73239f1db7f41d80b643c0c52518ec63163b319923a6bdb4527c626126703c0f49d6c8af0f97144a87df21d91472f96644173a103b6616c5d5ad1cee40c863d0273c9c4b27f322e4e716ef53a47de7a4c6d0e7b226259fa9023490b26167ad1d1fe8986713f07c3d9ae1c163ff8cf9d38369e1a965610be887fbd0c79162aafb0a0127abb44484b9fbef5abcae1b579fc2cdadc6402e8ee866e1f37bdb47e42c26b51ea37df8e1d6f76fc3b66a7429b3bc7683205d4f443dc1f29dda3315c87bd5fa5a3469d29aaaf83d23589db8c85b3fb46e2c8f0f068edce8cdcd7dfc5862'), ('0102030405060708090a','00','ede3b04643e586cc907dc2185170990203516ba78f413beb223aa5d4d2df67113cfd6cb58ee0fdde640176ad0000044d48532b21fb6079c9114c0ffd9c04a1ad3e8cea98017109979084b1ef92f99d86e20fb49bdb337ee48b8d8dc0f4afeffe5c2521eacd7966f15e056544bea0d315e067a7031931a246a6c3875d2f678acba64f70af88ae56b6f87581c0e23e6b08f449031de312814ec6f319291f4a0516bdae85924b3cb1d0a2e33a30c6d795998a0feddbac865a09bcd127fb562ed60ab55a0a5b51a12a8be34899c3e047511ad9a09cea3ce75fe39698070317a71339552225ed1177f44584ac8cfa6c4eb5fc7e82cbabfc95381b080998442129c2f81f135ed14ce60a91369d2322bef25e3c08b6be45124a43e2eb77953f84dc8553'), ('0102030405060708090a0b0c0d0e0f10', '00','9ac7cc9a609d1ef7b2932899cde41b975248c4959014126a6e8a84f11d1a9e1c065902e4b620f6cc36c8589f66432f2bd39d566bc6bce3010768151549f3873fb6d1e6c4a5e4771cad79538df295fb11c68c1d5c559a974123df1dbc52a43b89c5ecf88de897fd57fed301701b82a259eccbe13de1fcc91c11a0b26c0bc8fa4de7a72574f8782ae26aabcf9ebcd66065bdf0324e6083dcc6d3cedd3ca8c53c16b40110c4190b5622a96116b0017ed297ffa0b514647ec04f6306b892ae661181d03d1bc03cd33d70dff9fa5d71963ebd8a44126411eaa78bd51e8d87a8879bf5fabeb76028ade2d0e48722e46c4615a3c05d88abd50357f935a63c59ee537623ff38265c1642c1abe8d3c2fe5e572bf8a36a4c301ae8ac13610ccbc12256cacc'), ('0102030405060708090a0b0c0d0e0f101112131415161718','00','0595e57fe5f0bb3c706edac8a4b2db11dfde31344a1af769c74f070aee9e2326b06b9b1e195d13d8f4a7995c4553ac056bd2378ec341c9a42f37ba79f88a32ffe70bce1df7645adb5d2c4130215c35229a5730c7fcb4c9af51ffda89c7f1ad220485055fd4f6f0d963ef5ab9a5476982591fc66bcda10e452b03d4551f6b62ac2753cc83988afa3e1688a1d3b42c9a0293610d523d1d3f0062b3c2a3bbc7c7f096c248610aadedfeaf8978c03de8205a0e317b3d1c73b9e9a4688f296d133a19bdf0e6c3cca5b5b9d533b69c56ada12088a218b6e2ece1e6246d44c759d19b106866397e95c140534f94263421006e4032cb0a1e9542c6b3b8b398abc3b0f1d529a0b8aed54a132324c62e423f54b4c83cb0f3b5020a98b82af9fe154484a168'), ('0102030405060708090a0b0c0d0e0f101112131415161718191a1b1c1d1e1f20','00','eaa6bd25880bf93d3f5d1e4ca2611d91cfa45c9f7e714b54bdfa80027cb14380114ae344ded71b35f2e60febad727fd802e1e7056b0f623900496422943e97b691cb93c787964e10d9527d999c6f936b49b18b42f8e8367cbeb5ef104ba1c7cd87084b3ba700bade955610672745b374e7a7b9e9ec540d5ff43bdb12792d1b35c799b596738f6b018c76c74b1759bd907fec5bfd9f9b89ce6548309092d7e95840f250b26d1f096a4afd4c340a5888153e34135c79db010200767651cf263073f656abccf88dd827027b2ce917d464ec18b62503bfbc077fbabb98f20d98ab348aed95ee5b0dcbfbef4eb21d3a3f52f9625a1ab00ee39a5327346bddb01a9c18a13a7c79c7e119b5ab0296ab28c300b9f3e4c0a2e02d1d01f7f0a74618af2b48'), ('833222772a','00','80ad97bdc973df8a2e879e92a497efda20f060c2f2e5126501d3d4fea10d5fc0faa148e99046181fec6b2085f3b20ed9f0daf5bab3d596839857846f73fbfe5a1c7e2fc4639232fe297584b296996bc83db9b249406cc8edffac55ccd322ba12e4f9f7e0066154bbd125b745569bc89775d5ef262b44c41a9cf63ae14568e1b96da453dbf81e82334a3d8866cb50a1e37828d074119cab5c22b294d7a9bfa0bbadb89cea9a15fbe617295bd04b8ca05c6251d87fd4aaae9a7e4ad5c217d3f300e7119bd6dd9b22afe8f89585432881e2785b60fd7ec4e9fcb6545f350d660fabafecc037fdb7b0838eb3d70bcd268382dbc1a7b49d57358cc9fa6d61d73b7cf06349d126a37afcba89794f9804914fdcbf42c3018c2f7c66bfde524975768115'), ('1910833222772a','00','bc9222dbd3274d8fc66d14ccbda6690b7ae627410c9a2be693df5bb7485a63e33f0931aa03defb300f060103826f2a64beaa9ec8d59bb68129f3027c9636118174e04db46d28648d7dee8a0064b06cfe9b5e81c62fe023c55be42f87bbf932b8ce178fc1826efecbc182f57999a461408bdf55cd55061c06dba6be11de4a578a626f5f4dce652501f3087d39c92cc34942daac6a8f9ab9a7fd137c6037825682cc03fdb79192a207312f53f5d4dc33d9f70f14122a1c98a3155d28b8a0a8a41d2a3a307ab2708a9c00fe0b42f9c2d6a1862617627d2261eab0b1246597ca0ae955f877ce4f2e1ddbbf8e13e2cde0fdc81b1556cb935f173337705fbb5d501fc1ecd0e96602be7f8d5092816cccf2c2e9027881fab4993a1c262024a94fff3f61'), ('641910833222772a','00','bbf609de9413172d07660cb68071692646101a6dab43115d6c522b4fe93604a9cbe1fff21c96f3eef61e8fe0542cbdf0347938bffa4009c512cfb4034b0dd1a77867a786d00a7147904d76ddf1e520e38d3e9e1caefcccb3fbf8d18f64120b32942337f8fd76f0fae8c52d7954810672b8548c10f51667f6e60e182fa19b30f70211c7c6190c9efd1237c34c8f2e06c4bda64f65276d2aacb8f90212203a808ebd3820f732ffb53ec193e79d33e27c73d0168616861907d482e36cdac8cf574997b0f0f224b2d2317114808fb03af7a0e59616e469787939a063ceea9af956d1c47e0dc1660919c11101208f9e69aa1f5ae4f12896b8379a2aad89b5b553d6b06b6b098d0c293bc2993d80bf0518b6d98170cc3ccd92a698621b939dd38fe7b9'), ('8b37641910833222772a', '00','ab65c26eddb287600db2fda10d1e605cbb759010c29658f2c72d93a2d16d2930b901e8036ed1c383cd3c4c4dd0a6ab053d25ce4922924c55f064943353d78a6c12c1aa44bbf87e75e611f69b2c38f49b28f2b3434b65c09877470044c6ea170dbd9ef822de5288196134cf8af783930467559c23f052158470a296f725735a328bab26fbc2c12b0f13e2ab185eabf24131185a6d696f0cfa9b42808b38e132a2564d3dae183c5234c8af1e51061c44b53c0778a7b5f72d3c23a3135c7d67b9f4f34369890fcf16fb517dcaae4463b2dd02f31c81e8200731b899b028e791bfa772da646283228c14300853701795616f4e0a8c6f7934a788e2265e81d6d0c8f4438dd5eafea0111b6f36b4b938da2a685f6bfc73815874d97100f086979357d8'), ('ebb46227c6cc8b37641910833222772a', '00', '720c94b63edf44e131d950ca211a5a30c366fdeacf9ca80436be7c358424d20bb3394a40aabf75cba42282ef25a0059f4847d81da4942dbc249defc48c922b9f08128c469f275342adda202b2b58da95970dacef40ad98723bac5d6955b817613cb89993b07b0ced93de13d2a11013acef2d676f1545c2c13dc680a02f4adbfeb60595514f24bc9fe522a6cad7393644b515a8c5011754f59003058bdb81514e3c70047e8cbc038e3b9820db601da4951175da6ee756de46a53e2b075660b77000a542bba02111cc2c65b38ebdba587e5865fdbb5b48064104e830b380f2aede34b21ad2ad44e999db2d7f0863f0d9b684a9218fc36e8a5f2ccfbeae53a27d25a2221a11b833ccb498a59540f0545f4a5bbeb4787d59e5373fdbea6c6f75c29b'), ('c109163908ebe51debb46227c6cc8b37641910833222772a','00','54b64e6b5a20b5e2ec84593dc7989da7c135eee237a85465ff97dc03924f45cecfcc922fb4a14ab45d6175aabbf2d201837b87e2a446ad0ef798acd02b94124f17a6dbd664926a0636b3f4c37a4f46944a5f9f26aeeed4d4a25f632d305233d980a3d01ef00c8e9a4209c17f4eeb358cd15e7d5ffaaabc0207bf200a117793a2349682bf588eaa52d0aa1560346aeafaf5854cdb76c889e3ad63354e5f7275e3532c7ceccb39df3236318405a4b1279cbaefe6d9ceb651842260e0d1e05e3b90e82d8c6db54e3c633f581c952ba042074b16e50abd381bd70900a9cd9a62cb233682ee33bd148bd9f58656cd8f30d9fb1e5a0b8475045d9b20b2628624edfd9e63edd684fb826282fe528f9c0e9237bce4dd2e98d6960fae0b43545456743391'), ('1ada31d5cf688221c109163908ebe51debb46227c6cc8b37641910833222772a', '00','dd5bcb0018e922d494759d7c395d02d3c8446f8f77abf737685353eb89a1c9ebaf3e30f9c095045938151575c3fb9098f8cb6274db99b80b1d2012a98ed48f0e25c3005a1cb85de076259839ab7198ab9dcbc183e8cb994b727b75be3180769ca1d3078dfa9169503ed9d4491dee4eb28514a5495858096f596e4bcd66b106655f40d59ec1b03b33738efa60b2255d313477c7f764a41baceff90bf14f92b7ccac4e95368d99b9eb78b8da8f81ffa7958c3c13f8c2388bb73f38576e65b7c44613c4b9c1dfb66579eddd8a280b9f7316ddd27820550126698efaadc64b64f66ef08f2e66d28ed143f3a237cf9de735599ea36c525531b880ba124334f57b0b70d5a39e3dfcc50280bac4a6b5aa0dca7d370b1c1fe655916d97fd0d47ca1d72b8'), ] rc4_segments = [0, 16, 240, 256, 496, 512, 752, 768, 1008, 1024, 1520, 1536, 2032, 2048, 3056, 3072, 4080, 4096] def rc4_enc(cipherobj:symmetric.symmetricBASE, vector): for i, res in enumerate(vector): key, plaintext, ciphertext = res plaintext = bytes.fromhex(plaintext) key = bytes.fromhex(key) ciphertext = bytes.fromhex(ciphertext) ctx = cipherobj(key) enc_data = ctx.encrypt(b'\x00'*5000) ctx_dec = cipherobj(key) dec_data = ctx_dec.decrypt(enc_data) if dec_data != b'\x00'*5000: raise Exception('RC4 decrypt failed!') for i, start in enumerate(rc4_segments): cstart = i*16 if enc_data[start:start+16] != ciphertext[cstart:cstart+16]: raise Exception('Ciphertext doesnt match to vector! RC4 %s Cipher: \r\n%s \r\nVector: \r\n%s' % (i, enc_data[start:start+16].hex(), ciphertext[cstart:cstart+16].hex())) return True @pytest.mark.parametrize("cipherobj", [get_cipher_by_name('RC4', 'pure')]) def test_rc4(cipherobj): if str(cipherobj).find('pure.RC4') == -1: raise Exception('Wrong cipher object!') rc4_enc(cipherobj, rc4_vectors) #@pytest.mark.parametrize("cipherobj", [get_cipher_by_name('RC4', 'crypto')]) #def test_rc4(cipherobj): # rc4_enc(cipherobj, rc4_vectors) @pytest.mark.parametrize("cipherobj", [get_cipher_by_name('RC4', 'pycryptodome')]) def test_rc4(cipherobj): rc4_enc(cipherobj, rc4_vectors) @pytest.mark.parametrize("cipherobj", [get_cipher_by_name('RC4', 'pycryptodomex')]) def test_rc4(cipherobj): rc4_enc(cipherobj, rc4_vectors) @pytest.mark.parametrize("cipherobj", [get_cipher_by_name('RC4', 'mbedtls')]) def test_rc4(cipherobj): rc4_enc(cipherobj, rc4_vectors) @pytest.mark.parametrize("cipherobj", [get_cipher_by_name('RC4', 'cryptography')]) def test_rc4(cipherobj): if str(cipherobj).find('cryptography.RC4') == -1: raise Exception('Wrong cipher object!') rc4_enc(cipherobj, rc4_vectors) unicrypto-0.0.10/tests/test_tdes.py000066400000000000000000000067341437177004600173610ustar00rootroot00000000000000 import pytest from unicrypto import get_cipher_by_name from unicrypto import symmetric tdes_ecb = [ ('000102030405060708090A0B0C0D0E0F1011121314151617', '982662605553244D', '0011223344556677'), ] tdes_cbc = [ ('0123456789abcdeff1e0d3c2b5a49786fedcba9876543210','fedcba9876543210' , '37363534333231204E6F77206973207468652074696D6520666F722000000000', '3FE301C962AC01D02213763C1CBD4CDC799657C064ECF5D41C673812CFDE9675'), ] def ecb_enc(cipherobj:symmetric.symmetricBASE, vector): for i, res in enumerate(vector): key, plaintext, ciphertext = res plaintext = bytes.fromhex(plaintext) key = bytes.fromhex(key) ciphertext = bytes.fromhex(ciphertext) ctx = cipherobj(key) enc_data = ctx.encrypt(plaintext) if enc_data != ciphertext: raise Exception('Ciphertext doesnt match to vector! TDES %s Cipher: \r\n%s \r\nVector: \r\n%s' % (i, enc_data, ciphertext)) ctx = cipherobj(key) dec_data = ctx.decrypt(enc_data) if dec_data != plaintext: raise Exception('Decrypted data doesnt match plaintext! TDES-ECB Cipher: \r\n%s \r\nPlaintext: \r\n%s' % (dec_data.hex(), plaintext.hex())) return True def cbc_enc(cipherobj:symmetric.symmetricBASE, vector): for i, res in enumerate(vector): key, iv, plaintext, ciphertext = res plaintext = bytes.fromhex(plaintext) key = bytes.fromhex(key) ciphertext = bytes.fromhex(ciphertext) iv = bytes.fromhex(iv) ctx = cipherobj(key, symmetric.MODE_CBC, iv) enc_data = ctx.encrypt(plaintext) if enc_data != ciphertext: raise Exception('Ciphertext doesnt match to vector! TDES %s Cipher: \r\n%s \r\nVector: \r\n%s' % (i, enc_data, ciphertext)) ctx = cipherobj(key, symmetric.MODE_CBC, iv) dec_data = ctx.decrypt(enc_data) if dec_data != plaintext: raise Exception('Decrypted data doesnt match plaintext! TDES-CBC Cipher: \r\n%s \r\nPlaintext: \r\n%s' % (dec_data.hex(), plaintext.hex())) return True @pytest.mark.parametrize("cipherobj", [get_cipher_by_name('TDES', 'pure')]) def test_ecb(cipherobj): ecb_enc(cipherobj, tdes_ecb) @pytest.mark.parametrize("cipherobj", [get_cipher_by_name('TDES', 'pure')]) def test_cbc(cipherobj): cbc_enc(cipherobj, tdes_cbc) #@pytest.mark.parametrize("cipherobj", [get_cipher_by_name('TDES', 'crypto')]) #def test_ecb(cipherobj): # ecb_enc(cipherobj, tdes_ecb) # #@pytest.mark.parametrize("cipherobj", [get_cipher_by_name('TDES', 'crypto')]) #def test_cbc(cipherobj): # cbc_enc(cipherobj, tdes_cbc) @pytest.mark.parametrize("cipherobj", [get_cipher_by_name('TDES', 'pycryptodome')]) def test_ecb(cipherobj): ecb_enc(cipherobj, tdes_ecb) @pytest.mark.parametrize("cipherobj", [get_cipher_by_name('TDES', 'pycryptodome')]) def test_cbc(cipherobj): cbc_enc(cipherobj, tdes_cbc) @pytest.mark.parametrize("cipherobj", [get_cipher_by_name('TDES', 'cryptography')]) def test_ecb(cipherobj): ecb_enc(cipherobj, tdes_ecb) @pytest.mark.parametrize("cipherobj", [get_cipher_by_name('TDES', 'cryptography')]) def test_cbc(cipherobj): cbc_enc(cipherobj, tdes_cbc) @pytest.mark.parametrize("cipherobj", [get_cipher_by_name('TDES', 'mbedtls')]) def test_ecb(cipherobj): ecb_enc(cipherobj, tdes_ecb) @pytest.mark.parametrize("cipherobj", [get_cipher_by_name('TDES', 'mbedtls')]) def test_cbc(cipherobj): cbc_enc(cipherobj, tdes_cbc) @pytest.mark.parametrize("cipherobj", [get_cipher_by_name('TDES', 'pycryptodomex')]) def test_ecb(cipherobj): ecb_enc(cipherobj, tdes_ecb) @pytest.mark.parametrize("cipherobj", [get_cipher_by_name('TDES', 'pycryptodomex')]) def test_cbc(cipherobj): cbc_enc(cipherobj, tdes_cbc) unicrypto-0.0.10/tests/trace000066400000000000000000015715651437177004600160440ustar00rootroot00000000000000versions pytest-7.2.1, python-3.10.6.final.0 cwd=/home/webdev/Desktop/octopwnweb/code/projects/unicrypto/tests args=('--cov-config=.coveragerc', '--cov-report', 'html', '--cov=unicrypto', '--debug=trace', './') pytest_cmdline_main [hook] config: <_pytest.config.Config object at 0x7f1da3c09270> pytest_plugin_registered [hook] plugin: manager: <_pytest.config.PytestPluginManager object at 0x7f1da46c7910> finish pytest_plugin_registered --> [] [hook] pytest_configure [hook] config: <_pytest.config.Config object at 0x7f1da3c09270> pytest_plugin_registered [hook] plugin: <_pytest.cacheprovider.LFPlugin object at 0x7f1da350e380> manager: <_pytest.config.PytestPluginManager object at 0x7f1da46c7910> finish pytest_plugin_registered --> [] [hook] pytest_plugin_registered [hook] plugin: <_pytest.cacheprovider.NFPlugin object at 0x7f1da350e620> manager: <_pytest.config.PytestPluginManager object at 0x7f1da46c7910> finish pytest_plugin_registered --> [] [hook] early skip of rewriting module: faulthandler [assertion] pytest_plugin_registered [hook] plugin: manager: <_pytest.config.PytestPluginManager object at 0x7f1da46c7910> finish pytest_plugin_registered --> [] [hook] early skip of rewriting module: pdb [assertion] early skip of rewriting module: cmd [assertion] early skip of rewriting module: code [assertion] early skip of rewriting module: codeop [assertion] pytest_plugin_registered [hook] plugin: <_pytest.config.PytestPluginManager object at 0x7f1da46c7910> manager: <_pytest.config.PytestPluginManager object at 0x7f1da46c7910> finish pytest_plugin_registered --> [] [hook] pytest_plugin_registered [hook] plugin: <_pytest.config.Config object at 0x7f1da3c09270> manager: <_pytest.config.PytestPluginManager object at 0x7f1da46c7910> finish pytest_plugin_registered --> [] [hook] pytest_plugin_registered [hook] plugin: manager: <_pytest.config.PytestPluginManager object at 0x7f1da46c7910> finish pytest_plugin_registered --> [] [hook] pytest_plugin_registered [hook] plugin: manager: <_pytest.config.PytestPluginManager object at 0x7f1da46c7910> finish pytest_plugin_registered --> [] [hook] pytest_plugin_registered [hook] plugin: manager: <_pytest.config.PytestPluginManager object at 0x7f1da46c7910> finish pytest_plugin_registered --> [] [hook] pytest_plugin_registered [hook] plugin: manager: <_pytest.config.PytestPluginManager object at 0x7f1da46c7910> finish pytest_plugin_registered --> [] [hook] pytest_plugin_registered [hook] plugin: manager: <_pytest.config.PytestPluginManager object at 0x7f1da46c7910> finish pytest_plugin_registered --> [] [hook] pytest_plugin_registered [hook] plugin: manager: <_pytest.config.PytestPluginManager object at 0x7f1da46c7910> finish pytest_plugin_registered --> [] [hook] pytest_plugin_registered [hook] plugin: manager: <_pytest.config.PytestPluginManager object at 0x7f1da46c7910> finish pytest_plugin_registered --> [] [hook] pytest_plugin_registered [hook] plugin: manager: <_pytest.config.PytestPluginManager object at 0x7f1da46c7910> finish pytest_plugin_registered --> [] [hook] pytest_plugin_registered [hook] plugin: manager: <_pytest.config.PytestPluginManager object at 0x7f1da46c7910> finish pytest_plugin_registered --> [] [hook] pytest_plugin_registered [hook] plugin: manager: <_pytest.config.PytestPluginManager object at 0x7f1da46c7910> finish pytest_plugin_registered --> [] [hook] pytest_plugin_registered [hook] plugin: manager: <_pytest.config.PytestPluginManager object at 0x7f1da46c7910> finish pytest_plugin_registered --> [] [hook] pytest_plugin_registered [hook] plugin: manager: <_pytest.config.PytestPluginManager object at 0x7f1da46c7910> finish pytest_plugin_registered --> [] [hook] pytest_plugin_registered [hook] plugin: manager: <_pytest.config.PytestPluginManager object at 0x7f1da46c7910> finish pytest_plugin_registered --> [] [hook] pytest_plugin_registered [hook] plugin: manager: <_pytest.config.PytestPluginManager object at 0x7f1da46c7910> finish pytest_plugin_registered --> [] [hook] pytest_plugin_registered [hook] plugin: manager: <_pytest.config.PytestPluginManager object at 0x7f1da46c7910> finish pytest_plugin_registered --> [] [hook] pytest_plugin_registered [hook] plugin: manager: <_pytest.config.PytestPluginManager object at 0x7f1da46c7910> finish pytest_plugin_registered --> [] [hook] pytest_plugin_registered [hook] plugin: manager: <_pytest.config.PytestPluginManager object at 0x7f1da46c7910> finish pytest_plugin_registered --> [] [hook] pytest_plugin_registered [hook] plugin: manager: <_pytest.config.PytestPluginManager object at 0x7f1da46c7910> finish pytest_plugin_registered --> [] [hook] pytest_plugin_registered [hook] plugin: manager: <_pytest.config.PytestPluginManager object at 0x7f1da46c7910> finish pytest_plugin_registered --> [] [hook] pytest_plugin_registered [hook] plugin: manager: <_pytest.config.PytestPluginManager object at 0x7f1da46c7910> finish pytest_plugin_registered --> [] [hook] pytest_plugin_registered [hook] plugin: manager: <_pytest.config.PytestPluginManager object at 0x7f1da46c7910> finish pytest_plugin_registered --> [] [hook] pytest_plugin_registered [hook] plugin: manager: <_pytest.config.PytestPluginManager object at 0x7f1da46c7910> finish pytest_plugin_registered --> [] [hook] pytest_plugin_registered [hook] plugin: manager: <_pytest.config.PytestPluginManager object at 0x7f1da46c7910> finish pytest_plugin_registered --> [] [hook] pytest_plugin_registered [hook] plugin: manager: <_pytest.config.PytestPluginManager object at 0x7f1da46c7910> finish pytest_plugin_registered --> [] [hook] pytest_plugin_registered [hook] plugin: manager: <_pytest.config.PytestPluginManager object at 0x7f1da46c7910> finish pytest_plugin_registered --> [] [hook] pytest_plugin_registered [hook] plugin: manager: <_pytest.config.PytestPluginManager object at 0x7f1da46c7910> finish pytest_plugin_registered --> [] [hook] pytest_plugin_registered [hook] plugin: manager: <_pytest.config.PytestPluginManager object at 0x7f1da46c7910> finish pytest_plugin_registered --> [] [hook] pytest_plugin_registered [hook] plugin: manager: <_pytest.config.PytestPluginManager object at 0x7f1da46c7910> finish pytest_plugin_registered --> [] [hook] pytest_plugin_registered [hook] plugin: manager: <_pytest.config.PytestPluginManager object at 0x7f1da46c7910> finish pytest_plugin_registered --> [] [hook] pytest_plugin_registered [hook] plugin: manager: <_pytest.config.PytestPluginManager object at 0x7f1da46c7910> finish pytest_plugin_registered --> [] [hook] pytest_plugin_registered [hook] plugin: manager: <_pytest.config.PytestPluginManager object at 0x7f1da46c7910> finish pytest_plugin_registered --> [] [hook] pytest_plugin_registered [hook] plugin: manager: <_pytest.config.PytestPluginManager object at 0x7f1da46c7910> finish pytest_plugin_registered --> [] [hook] pytest_plugin_registered [hook] plugin: manager: <_pytest.config.PytestPluginManager object at 0x7f1da46c7910> finish pytest_plugin_registered --> [] [hook] pytest_plugin_registered [hook] plugin: > err=> in_=> _state='suspended' _in_suspended=False> _capture_fixture=None> manager: <_pytest.config.PytestPluginManager object at 0x7f1da46c7910> finish pytest_plugin_registered --> [] [hook] pytest_plugin_registered [hook] plugin: manager: <_pytest.config.PytestPluginManager object at 0x7f1da46c7910> finish pytest_plugin_registered --> [] [hook] pytest_plugin_registered [hook] plugin: testsfailed=0 testscollected=0> manager: <_pytest.config.PytestPluginManager object at 0x7f1da46c7910> finish pytest_plugin_registered --> [] [hook] pytest_plugin_registered [hook] plugin: <_pytest.cacheprovider.LFPlugin object at 0x7f1da350e380> manager: <_pytest.config.PytestPluginManager object at 0x7f1da46c7910> finish pytest_plugin_registered --> [] [hook] pytest_plugin_registered [hook] plugin: <_pytest.cacheprovider.NFPlugin object at 0x7f1da350e620> manager: <_pytest.config.PytestPluginManager object at 0x7f1da46c7910> finish pytest_plugin_registered --> [] [hook] pytest_plugin_registered [hook] plugin: manager: <_pytest.config.PytestPluginManager object at 0x7f1da46c7910> finish pytest_plugin_registered --> [] [hook] pytest_plugin_registered [hook] plugin: <_pytest.terminal.TerminalReporter object at 0x7f1da350ea10> manager: <_pytest.config.PytestPluginManager object at 0x7f1da46c7910> finish pytest_plugin_registered --> [] [hook] pytest_plugin_registered [hook] plugin: <_pytest.logging.LoggingPlugin object at 0x7f1da33ecdc0> manager: <_pytest.config.PytestPluginManager object at 0x7f1da46c7910> finish pytest_plugin_registered --> [] [hook] finish pytest_configure --> [] [hook] pytest_sessionstart [hook] session: testsfailed=0 testscollected=0> pytest_plugin_registered [hook] plugin: <_pytest.config.PytestPluginManager object at 0x7f1da46c7910> manager: <_pytest.config.PytestPluginManager object at 0x7f1da46c7910> finish pytest_plugin_registered --> [] [hook] pytest_plugin_registered [hook] plugin: <_pytest.config.Config object at 0x7f1da3c09270> manager: <_pytest.config.PytestPluginManager object at 0x7f1da46c7910> finish pytest_plugin_registered --> [] [hook] pytest_plugin_registered [hook] plugin: manager: <_pytest.config.PytestPluginManager object at 0x7f1da46c7910> finish pytest_plugin_registered --> [] [hook] pytest_plugin_registered [hook] plugin: manager: <_pytest.config.PytestPluginManager object at 0x7f1da46c7910> finish pytest_plugin_registered --> [] [hook] pytest_plugin_registered [hook] plugin: manager: <_pytest.config.PytestPluginManager object at 0x7f1da46c7910> finish pytest_plugin_registered --> [] [hook] pytest_plugin_registered [hook] plugin: manager: <_pytest.config.PytestPluginManager object at 0x7f1da46c7910> finish pytest_plugin_registered --> [] [hook] pytest_plugin_registered [hook] plugin: manager: <_pytest.config.PytestPluginManager object at 0x7f1da46c7910> finish pytest_plugin_registered --> [] [hook] pytest_plugin_registered [hook] plugin: manager: <_pytest.config.PytestPluginManager object at 0x7f1da46c7910> finish pytest_plugin_registered --> [] [hook] pytest_plugin_registered [hook] plugin: manager: <_pytest.config.PytestPluginManager object at 0x7f1da46c7910> finish pytest_plugin_registered --> [] [hook] pytest_plugin_registered [hook] plugin: manager: <_pytest.config.PytestPluginManager object at 0x7f1da46c7910> finish pytest_plugin_registered --> [] [hook] pytest_plugin_registered [hook] plugin: manager: <_pytest.config.PytestPluginManager object at 0x7f1da46c7910> finish pytest_plugin_registered --> [] [hook] pytest_plugin_registered [hook] plugin: manager: <_pytest.config.PytestPluginManager object at 0x7f1da46c7910> finish pytest_plugin_registered --> [] [hook] pytest_plugin_registered [hook] plugin: manager: <_pytest.config.PytestPluginManager object at 0x7f1da46c7910> finish pytest_plugin_registered --> [] [hook] pytest_plugin_registered [hook] plugin: manager: <_pytest.config.PytestPluginManager object at 0x7f1da46c7910> finish pytest_plugin_registered --> [] [hook] pytest_plugin_registered [hook] plugin: manager: <_pytest.config.PytestPluginManager object at 0x7f1da46c7910> finish pytest_plugin_registered --> [] [hook] pytest_plugin_registered [hook] plugin: manager: <_pytest.config.PytestPluginManager object at 0x7f1da46c7910> finish pytest_plugin_registered --> [] [hook] pytest_plugin_registered [hook] plugin: manager: <_pytest.config.PytestPluginManager object at 0x7f1da46c7910> finish pytest_plugin_registered --> [] [hook] pytest_plugin_registered [hook] plugin: manager: <_pytest.config.PytestPluginManager object at 0x7f1da46c7910> finish pytest_plugin_registered --> [] [hook] pytest_plugin_registered [hook] plugin: manager: <_pytest.config.PytestPluginManager object at 0x7f1da46c7910> finish pytest_plugin_registered --> [] [hook] pytest_plugin_registered [hook] plugin: manager: <_pytest.config.PytestPluginManager object at 0x7f1da46c7910> finish pytest_plugin_registered --> [] [hook] pytest_plugin_registered [hook] plugin: manager: <_pytest.config.PytestPluginManager object at 0x7f1da46c7910> finish pytest_plugin_registered --> [] [hook] pytest_plugin_registered [hook] plugin: manager: <_pytest.config.PytestPluginManager object at 0x7f1da46c7910> finish pytest_plugin_registered --> [] [hook] pytest_plugin_registered [hook] plugin: manager: <_pytest.config.PytestPluginManager object at 0x7f1da46c7910> finish pytest_plugin_registered --> [] [hook] pytest_plugin_registered [hook] plugin: manager: <_pytest.config.PytestPluginManager object at 0x7f1da46c7910> finish pytest_plugin_registered --> [] [hook] pytest_plugin_registered [hook] plugin: manager: <_pytest.config.PytestPluginManager object at 0x7f1da46c7910> finish pytest_plugin_registered --> [] [hook] pytest_plugin_registered [hook] plugin: manager: <_pytest.config.PytestPluginManager object at 0x7f1da46c7910> finish pytest_plugin_registered --> [] [hook] pytest_plugin_registered [hook] plugin: manager: <_pytest.config.PytestPluginManager object at 0x7f1da46c7910> finish pytest_plugin_registered --> [] [hook] pytest_plugin_registered [hook] plugin: manager: <_pytest.config.PytestPluginManager object at 0x7f1da46c7910> finish pytest_plugin_registered --> [] [hook] pytest_plugin_registered [hook] plugin: manager: <_pytest.config.PytestPluginManager object at 0x7f1da46c7910> finish pytest_plugin_registered --> [] [hook] pytest_plugin_registered [hook] plugin: manager: <_pytest.config.PytestPluginManager object at 0x7f1da46c7910> finish pytest_plugin_registered --> [] [hook] pytest_plugin_registered [hook] plugin: manager: <_pytest.config.PytestPluginManager object at 0x7f1da46c7910> finish pytest_plugin_registered --> [] [hook] pytest_plugin_registered [hook] plugin: manager: <_pytest.config.PytestPluginManager object at 0x7f1da46c7910> finish pytest_plugin_registered --> [] [hook] pytest_plugin_registered [hook] plugin: manager: <_pytest.config.PytestPluginManager object at 0x7f1da46c7910> finish pytest_plugin_registered --> [] [hook] pytest_plugin_registered [hook] plugin: manager: <_pytest.config.PytestPluginManager object at 0x7f1da46c7910> finish pytest_plugin_registered --> [] [hook] pytest_plugin_registered [hook] plugin: manager: <_pytest.config.PytestPluginManager object at 0x7f1da46c7910> finish pytest_plugin_registered --> [] [hook] pytest_plugin_registered [hook] plugin: > err=> in_=> _state='suspended' _in_suspended=False> _capture_fixture=None> manager: <_pytest.config.PytestPluginManager object at 0x7f1da46c7910> finish pytest_plugin_registered --> [] [hook] pytest_plugin_registered [hook] plugin: manager: <_pytest.config.PytestPluginManager object at 0x7f1da46c7910> finish pytest_plugin_registered --> [] [hook] pytest_plugin_registered [hook] plugin: testsfailed=0 testscollected=0> manager: <_pytest.config.PytestPluginManager object at 0x7f1da46c7910> finish pytest_plugin_registered --> [] [hook] pytest_plugin_registered [hook] plugin: <_pytest.cacheprovider.LFPlugin object at 0x7f1da350e380> manager: <_pytest.config.PytestPluginManager object at 0x7f1da46c7910> finish pytest_plugin_registered --> [] [hook] pytest_plugin_registered [hook] plugin: <_pytest.cacheprovider.NFPlugin object at 0x7f1da350e620> manager: <_pytest.config.PytestPluginManager object at 0x7f1da46c7910> finish pytest_plugin_registered --> [] [hook] pytest_plugin_registered [hook] plugin: manager: <_pytest.config.PytestPluginManager object at 0x7f1da46c7910> finish pytest_plugin_registered --> [] [hook] pytest_plugin_registered [hook] plugin: <_pytest.terminal.TerminalReporter object at 0x7f1da350ea10> manager: <_pytest.config.PytestPluginManager object at 0x7f1da46c7910> finish pytest_plugin_registered --> [] [hook] pytest_plugin_registered [hook] plugin: <_pytest.logging.LoggingPlugin object at 0x7f1da33ecdc0> manager: <_pytest.config.PytestPluginManager object at 0x7f1da46c7910> finish pytest_plugin_registered --> [] [hook] pytest_plugin_registered [hook] plugin: <_pytest.fixtures.FixtureManager object at 0x7f1da33ed480> manager: <_pytest.config.PytestPluginManager object at 0x7f1da46c7910> finish pytest_plugin_registered --> [] [hook] pytest_report_header [hook] config: <_pytest.config.Config object at 0x7f1da3c09270> start_path: /home/webdev/Desktop/octopwnweb/code/projects/unicrypto/tests startdir: /home/webdev/Desktop/octopwnweb/code/projects/unicrypto/tests early skip of rewriting module: email.parser [assertion] early skip of rewriting module: email.feedparser [assertion] finish pytest_report_header --> [['rootdir: /home/webdev/Desktop/octopwnweb/code/projects/unicrypto', 'plugins: cov-4.0.0'], ['using: pytest-7.2.1', 'setuptools registered plugins:', ' pytest-cov-4.0.0 at /home/webdev/Desktop/octopwnweb/code/projects/unicrypto/tests/testenv/lib/python3.10/site-packages/pytest_cov/plugin.py']] [hook] finish pytest_sessionstart --> [] [hook] pytest_collection [hook] session: testsfailed=0 testscollected=0> perform_collect testsfailed=0 testscollected=0> ['./'] [collection] pytest_collectstart [hook] collector: testsfailed=0 testscollected=0> finish pytest_collectstart --> [] [hook] pytest_make_collect_report [hook] collector: testsfailed=0 testscollected=0> processing argument (PosixPath('/home/webdev/Desktop/octopwnweb/code/projects/unicrypto/tests'), []) [collection] pytest_ignore_collect [hook] config: <_pytest.config.Config object at 0x7f1da3c09270> collection_path: /home/webdev/Desktop/octopwnweb/code/projects/unicrypto/tests/__init__.py path: /home/webdev/Desktop/octopwnweb/code/projects/unicrypto/tests/__init__.py finish pytest_ignore_collect --> None [hook] pytest_collect_file [hook] parent: testsfailed=0 testscollected=0> file_path: /home/webdev/Desktop/octopwnweb/code/projects/unicrypto/tests/__init__.py path: /home/webdev/Desktop/octopwnweb/code/projects/unicrypto/tests/__init__.py pytest_pycollect_makemodule [hook] parent: testsfailed=0 testscollected=0> module_path: /home/webdev/Desktop/octopwnweb/code/projects/unicrypto/tests/__init__.py path: /home/webdev/Desktop/octopwnweb/code/projects/unicrypto/tests/__init__.py finish pytest_pycollect_makemodule --> [hook] finish pytest_collect_file --> [] [hook] pytest_ignore_collect [hook] config: <_pytest.config.Config object at 0x7f1da3c09270> collection_path: /home/webdev/Desktop/octopwnweb/code/projects/unicrypto/tests/__init__.py path: /home/webdev/Desktop/octopwnweb/code/projects/unicrypto/tests/__init__.py finish pytest_ignore_collect --> None [hook] pytest_collect_file [hook] parent: testsfailed=0 testscollected=0> file_path: /home/webdev/Desktop/octopwnweb/code/projects/unicrypto/tests/__init__.py path: /home/webdev/Desktop/octopwnweb/code/projects/unicrypto/tests/__init__.py pytest_pycollect_makemodule [hook] parent: testsfailed=0 testscollected=0> module_path: /home/webdev/Desktop/octopwnweb/code/projects/unicrypto/tests/__init__.py path: /home/webdev/Desktop/octopwnweb/code/projects/unicrypto/tests/__init__.py finish pytest_pycollect_makemodule --> [hook] finish pytest_collect_file --> [] [hook] pytest_ignore_collect [hook] config: <_pytest.config.Config object at 0x7f1da3c09270> collection_path: /home/webdev/Desktop/octopwnweb/code/projects/unicrypto/tests/htmlcov path: /home/webdev/Desktop/octopwnweb/code/projects/unicrypto/tests/htmlcov finish pytest_ignore_collect --> None [hook] pytest_ignore_collect [hook] config: <_pytest.config.Config object at 0x7f1da3c09270> collection_path: /home/webdev/Desktop/octopwnweb/code/projects/unicrypto/tests/htmlcov/.gitignore path: /home/webdev/Desktop/octopwnweb/code/projects/unicrypto/tests/htmlcov/.gitignore finish pytest_ignore_collect --> None [hook] pytest_collect_file [hook] parent: testsfailed=0 testscollected=0> file_path: /home/webdev/Desktop/octopwnweb/code/projects/unicrypto/tests/htmlcov/.gitignore path: /home/webdev/Desktop/octopwnweb/code/projects/unicrypto/tests/htmlcov/.gitignore finish pytest_collect_file --> [] [hook] pytest_ignore_collect [hook] config: <_pytest.config.Config object at 0x7f1da3c09270> collection_path: /home/webdev/Desktop/octopwnweb/code/projects/unicrypto/tests/htmlcov/__init___py.html path: /home/webdev/Desktop/octopwnweb/code/projects/unicrypto/tests/htmlcov/__init___py.html finish pytest_ignore_collect --> None [hook] pytest_collect_file [hook] parent: testsfailed=0 testscollected=0> file_path: /home/webdev/Desktop/octopwnweb/code/projects/unicrypto/tests/htmlcov/__init___py.html path: /home/webdev/Desktop/octopwnweb/code/projects/unicrypto/tests/htmlcov/__init___py.html finish pytest_collect_file --> [] [hook] pytest_ignore_collect [hook] config: <_pytest.config.Config object at 0x7f1da3c09270> collection_path: /home/webdev/Desktop/octopwnweb/code/projects/unicrypto/tests/htmlcov/coverage_html.js path: /home/webdev/Desktop/octopwnweb/code/projects/unicrypto/tests/htmlcov/coverage_html.js finish pytest_ignore_collect --> None [hook] pytest_collect_file [hook] parent: testsfailed=0 testscollected=0> file_path: /home/webdev/Desktop/octopwnweb/code/projects/unicrypto/tests/htmlcov/coverage_html.js path: /home/webdev/Desktop/octopwnweb/code/projects/unicrypto/tests/htmlcov/coverage_html.js finish pytest_collect_file --> [] [hook] pytest_ignore_collect [hook] config: <_pytest.config.Config object at 0x7f1da3c09270> collection_path: /home/webdev/Desktop/octopwnweb/code/projects/unicrypto/tests/htmlcov/d_0237501f9c494193___init___py.html path: /home/webdev/Desktop/octopwnweb/code/projects/unicrypto/tests/htmlcov/d_0237501f9c494193___init___py.html finish pytest_ignore_collect --> None [hook] pytest_collect_file [hook] parent: testsfailed=0 testscollected=0> file_path: /home/webdev/Desktop/octopwnweb/code/projects/unicrypto/tests/htmlcov/d_0237501f9c494193___init___py.html path: /home/webdev/Desktop/octopwnweb/code/projects/unicrypto/tests/htmlcov/d_0237501f9c494193___init___py.html finish pytest_collect_file --> [] [hook] pytest_ignore_collect [hook] config: <_pytest.config.Config object at 0x7f1da3c09270> collection_path: /home/webdev/Desktop/octopwnweb/code/projects/unicrypto/tests/htmlcov/d_028b69a877824f4a_RC4_py.html path: /home/webdev/Desktop/octopwnweb/code/projects/unicrypto/tests/htmlcov/d_028b69a877824f4a_RC4_py.html finish pytest_ignore_collect --> None [hook] pytest_collect_file [hook] parent: testsfailed=0 testscollected=0> file_path: /home/webdev/Desktop/octopwnweb/code/projects/unicrypto/tests/htmlcov/d_028b69a877824f4a_RC4_py.html path: /home/webdev/Desktop/octopwnweb/code/projects/unicrypto/tests/htmlcov/d_028b69a877824f4a_RC4_py.html finish pytest_collect_file --> [] [hook] pytest_ignore_collect [hook] config: <_pytest.config.Config object at 0x7f1da3c09270> collection_path: /home/webdev/Desktop/octopwnweb/code/projects/unicrypto/tests/htmlcov/d_028b69a877824f4a___init___py.html path: /home/webdev/Desktop/octopwnweb/code/projects/unicrypto/tests/htmlcov/d_028b69a877824f4a___init___py.html finish pytest_ignore_collect --> None [hook] pytest_collect_file [hook] parent: testsfailed=0 testscollected=0> file_path: /home/webdev/Desktop/octopwnweb/code/projects/unicrypto/tests/htmlcov/d_028b69a877824f4a___init___py.html path: /home/webdev/Desktop/octopwnweb/code/projects/unicrypto/tests/htmlcov/d_028b69a877824f4a___init___py.html finish pytest_collect_file --> [] [hook] pytest_ignore_collect [hook] config: <_pytest.config.Config object at 0x7f1da3c09270> collection_path: /home/webdev/Desktop/octopwnweb/code/projects/unicrypto/tests/htmlcov/d_0f217a5f66ae40f9_AES_py.html path: /home/webdev/Desktop/octopwnweb/code/projects/unicrypto/tests/htmlcov/d_0f217a5f66ae40f9_AES_py.html finish pytest_ignore_collect --> None [hook] pytest_collect_file [hook] parent: testsfailed=0 testscollected=0> file_path: /home/webdev/Desktop/octopwnweb/code/projects/unicrypto/tests/htmlcov/d_0f217a5f66ae40f9_AES_py.html path: /home/webdev/Desktop/octopwnweb/code/projects/unicrypto/tests/htmlcov/d_0f217a5f66ae40f9_AES_py.html finish pytest_collect_file --> [] [hook] pytest_ignore_collect [hook] config: <_pytest.config.Config object at 0x7f1da3c09270> collection_path: /home/webdev/Desktop/octopwnweb/code/projects/unicrypto/tests/htmlcov/d_0f217a5f66ae40f9_DES_py.html path: /home/webdev/Desktop/octopwnweb/code/projects/unicrypto/tests/htmlcov/d_0f217a5f66ae40f9_DES_py.html finish pytest_ignore_collect --> None [hook] pytest_collect_file [hook] parent: testsfailed=0 testscollected=0> file_path: /home/webdev/Desktop/octopwnweb/code/projects/unicrypto/tests/htmlcov/d_0f217a5f66ae40f9_DES_py.html path: /home/webdev/Desktop/octopwnweb/code/projects/unicrypto/tests/htmlcov/d_0f217a5f66ae40f9_DES_py.html finish pytest_collect_file --> [] [hook] pytest_ignore_collect [hook] config: <_pytest.config.Config object at 0x7f1da3c09270> collection_path: /home/webdev/Desktop/octopwnweb/code/projects/unicrypto/tests/htmlcov/d_0f217a5f66ae40f9_RC4_py.html path: /home/webdev/Desktop/octopwnweb/code/projects/unicrypto/tests/htmlcov/d_0f217a5f66ae40f9_RC4_py.html finish pytest_ignore_collect --> None [hook] pytest_collect_file [hook] parent: testsfailed=0 testscollected=0> file_path: /home/webdev/Desktop/octopwnweb/code/projects/unicrypto/tests/htmlcov/d_0f217a5f66ae40f9_RC4_py.html path: /home/webdev/Desktop/octopwnweb/code/projects/unicrypto/tests/htmlcov/d_0f217a5f66ae40f9_RC4_py.html finish pytest_collect_file --> [] [hook] pytest_ignore_collect [hook] config: <_pytest.config.Config object at 0x7f1da3c09270> collection_path: /home/webdev/Desktop/octopwnweb/code/projects/unicrypto/tests/htmlcov/d_0f217a5f66ae40f9_TDES_py.html path: /home/webdev/Desktop/octopwnweb/code/projects/unicrypto/tests/htmlcov/d_0f217a5f66ae40f9_TDES_py.html finish pytest_ignore_collect --> None [hook] pytest_collect_file [hook] parent: testsfailed=0 testscollected=0> file_path: /home/webdev/Desktop/octopwnweb/code/projects/unicrypto/tests/htmlcov/d_0f217a5f66ae40f9_TDES_py.html path: /home/webdev/Desktop/octopwnweb/code/projects/unicrypto/tests/htmlcov/d_0f217a5f66ae40f9_TDES_py.html finish pytest_collect_file --> [] [hook] pytest_ignore_collect [hook] config: <_pytest.config.Config object at 0x7f1da3c09270> collection_path: /home/webdev/Desktop/octopwnweb/code/projects/unicrypto/tests/htmlcov/d_0f217a5f66ae40f9___init___py.html path: /home/webdev/Desktop/octopwnweb/code/projects/unicrypto/tests/htmlcov/d_0f217a5f66ae40f9___init___py.html finish pytest_ignore_collect --> None [hook] pytest_collect_file [hook] parent: testsfailed=0 testscollected=0> file_path: /home/webdev/Desktop/octopwnweb/code/projects/unicrypto/tests/htmlcov/d_0f217a5f66ae40f9___init___py.html path: /home/webdev/Desktop/octopwnweb/code/projects/unicrypto/tests/htmlcov/d_0f217a5f66ae40f9___init___py.html finish pytest_collect_file --> [] [hook] pytest_ignore_collect [hook] config: <_pytest.config.Config object at 0x7f1da3c09270> collection_path: /home/webdev/Desktop/octopwnweb/code/projects/unicrypto/tests/htmlcov/d_12fa02817ba8b749_AES_py.html path: /home/webdev/Desktop/octopwnweb/code/projects/unicrypto/tests/htmlcov/d_12fa02817ba8b749_AES_py.html finish pytest_ignore_collect --> None [hook] pytest_collect_file [hook] parent: testsfailed=0 testscollected=0> file_path: /home/webdev/Desktop/octopwnweb/code/projects/unicrypto/tests/htmlcov/d_12fa02817ba8b749_AES_py.html path: /home/webdev/Desktop/octopwnweb/code/projects/unicrypto/tests/htmlcov/d_12fa02817ba8b749_AES_py.html finish pytest_collect_file --> [] [hook] pytest_ignore_collect [hook] config: <_pytest.config.Config object at 0x7f1da3c09270> collection_path: /home/webdev/Desktop/octopwnweb/code/projects/unicrypto/tests/htmlcov/d_12fa02817ba8b749_DES_py.html path: /home/webdev/Desktop/octopwnweb/code/projects/unicrypto/tests/htmlcov/d_12fa02817ba8b749_DES_py.html finish pytest_ignore_collect --> None [hook] pytest_collect_file [hook] parent: testsfailed=0 testscollected=0> file_path: /home/webdev/Desktop/octopwnweb/code/projects/unicrypto/tests/htmlcov/d_12fa02817ba8b749_DES_py.html path: /home/webdev/Desktop/octopwnweb/code/projects/unicrypto/tests/htmlcov/d_12fa02817ba8b749_DES_py.html finish pytest_collect_file --> [] [hook] pytest_ignore_collect [hook] config: <_pytest.config.Config object at 0x7f1da3c09270> collection_path: /home/webdev/Desktop/octopwnweb/code/projects/unicrypto/tests/htmlcov/d_12fa02817ba8b749_RC4_py.html path: /home/webdev/Desktop/octopwnweb/code/projects/unicrypto/tests/htmlcov/d_12fa02817ba8b749_RC4_py.html finish pytest_ignore_collect --> None [hook] pytest_collect_file [hook] parent: testsfailed=0 testscollected=0> file_path: /home/webdev/Desktop/octopwnweb/code/projects/unicrypto/tests/htmlcov/d_12fa02817ba8b749_RC4_py.html path: /home/webdev/Desktop/octopwnweb/code/projects/unicrypto/tests/htmlcov/d_12fa02817ba8b749_RC4_py.html finish pytest_collect_file --> [] [hook] pytest_ignore_collect [hook] config: <_pytest.config.Config object at 0x7f1da3c09270> collection_path: /home/webdev/Desktop/octopwnweb/code/projects/unicrypto/tests/htmlcov/d_12fa02817ba8b749_TDES_py.html path: /home/webdev/Desktop/octopwnweb/code/projects/unicrypto/tests/htmlcov/d_12fa02817ba8b749_TDES_py.html finish pytest_ignore_collect --> None [hook] pytest_collect_file [hook] parent: testsfailed=0 testscollected=0> file_path: /home/webdev/Desktop/octopwnweb/code/projects/unicrypto/tests/htmlcov/d_12fa02817ba8b749_TDES_py.html path: /home/webdev/Desktop/octopwnweb/code/projects/unicrypto/tests/htmlcov/d_12fa02817ba8b749_TDES_py.html finish pytest_collect_file --> [] [hook] pytest_ignore_collect [hook] config: <_pytest.config.Config object at 0x7f1da3c09270> collection_path: /home/webdev/Desktop/octopwnweb/code/projects/unicrypto/tests/htmlcov/d_12fa02817ba8b749___init___py.html path: /home/webdev/Desktop/octopwnweb/code/projects/unicrypto/tests/htmlcov/d_12fa02817ba8b749___init___py.html finish pytest_ignore_collect --> None [hook] pytest_collect_file [hook] parent: testsfailed=0 testscollected=0> file_path: /home/webdev/Desktop/octopwnweb/code/projects/unicrypto/tests/htmlcov/d_12fa02817ba8b749___init___py.html path: /home/webdev/Desktop/octopwnweb/code/projects/unicrypto/tests/htmlcov/d_12fa02817ba8b749___init___py.html finish pytest_collect_file --> [] [hook] pytest_ignore_collect [hook] config: <_pytest.config.Config object at 0x7f1da3c09270> collection_path: /home/webdev/Desktop/octopwnweb/code/projects/unicrypto/tests/htmlcov/d_1b326c20d678c8f6_AESCCM_py.html path: /home/webdev/Desktop/octopwnweb/code/projects/unicrypto/tests/htmlcov/d_1b326c20d678c8f6_AESCCM_py.html finish pytest_ignore_collect --> None [hook] pytest_collect_file [hook] parent: testsfailed=0 testscollected=0> file_path: /home/webdev/Desktop/octopwnweb/code/projects/unicrypto/tests/htmlcov/d_1b326c20d678c8f6_AESCCM_py.html path: /home/webdev/Desktop/octopwnweb/code/projects/unicrypto/tests/htmlcov/d_1b326c20d678c8f6_AESCCM_py.html finish pytest_collect_file --> [] [hook] pytest_ignore_collect [hook] config: <_pytest.config.Config object at 0x7f1da3c09270> collection_path: /home/webdev/Desktop/octopwnweb/code/projects/unicrypto/tests/htmlcov/d_1b326c20d678c8f6_AESGCM_py.html path: /home/webdev/Desktop/octopwnweb/code/projects/unicrypto/tests/htmlcov/d_1b326c20d678c8f6_AESGCM_py.html finish pytest_ignore_collect --> None [hook] pytest_collect_file [hook] parent: testsfailed=0 testscollected=0> file_path: /home/webdev/Desktop/octopwnweb/code/projects/unicrypto/tests/htmlcov/d_1b326c20d678c8f6_AESGCM_py.html path: /home/webdev/Desktop/octopwnweb/code/projects/unicrypto/tests/htmlcov/d_1b326c20d678c8f6_AESGCM_py.html finish pytest_collect_file --> [] [hook] pytest_ignore_collect [hook] config: <_pytest.config.Config object at 0x7f1da3c09270> collection_path: /home/webdev/Desktop/octopwnweb/code/projects/unicrypto/tests/htmlcov/d_1b326c20d678c8f6_AES_py.html path: /home/webdev/Desktop/octopwnweb/code/projects/unicrypto/tests/htmlcov/d_1b326c20d678c8f6_AES_py.html finish pytest_ignore_collect --> None [hook] pytest_collect_file [hook] parent: testsfailed=0 testscollected=0> file_path: /home/webdev/Desktop/octopwnweb/code/projects/unicrypto/tests/htmlcov/d_1b326c20d678c8f6_AES_py.html path: /home/webdev/Desktop/octopwnweb/code/projects/unicrypto/tests/htmlcov/d_1b326c20d678c8f6_AES_py.html finish pytest_collect_file --> [] [hook] pytest_ignore_collect [hook] config: <_pytest.config.Config object at 0x7f1da3c09270> collection_path: /home/webdev/Desktop/octopwnweb/code/projects/unicrypto/tests/htmlcov/d_1b326c20d678c8f6___init___py.html path: /home/webdev/Desktop/octopwnweb/code/projects/unicrypto/tests/htmlcov/d_1b326c20d678c8f6___init___py.html finish pytest_ignore_collect --> None [hook] pytest_collect_file [hook] parent: testsfailed=0 testscollected=0> file_path: /home/webdev/Desktop/octopwnweb/code/projects/unicrypto/tests/htmlcov/d_1b326c20d678c8f6___init___py.html path: /home/webdev/Desktop/octopwnweb/code/projects/unicrypto/tests/htmlcov/d_1b326c20d678c8f6___init___py.html finish pytest_collect_file --> [] [hook] pytest_ignore_collect [hook] config: <_pytest.config.Config object at 0x7f1da3c09270> collection_path: /home/webdev/Desktop/octopwnweb/code/projects/unicrypto/tests/htmlcov/d_1b326c20d678c8f6_blockfeeder_py.html path: /home/webdev/Desktop/octopwnweb/code/projects/unicrypto/tests/htmlcov/d_1b326c20d678c8f6_blockfeeder_py.html finish pytest_ignore_collect --> None [hook] pytest_collect_file [hook] parent: testsfailed=0 testscollected=0> file_path: /home/webdev/Desktop/octopwnweb/code/projects/unicrypto/tests/htmlcov/d_1b326c20d678c8f6_blockfeeder_py.html path: /home/webdev/Desktop/octopwnweb/code/projects/unicrypto/tests/htmlcov/d_1b326c20d678c8f6_blockfeeder_py.html finish pytest_collect_file --> [] [hook] pytest_ignore_collect [hook] config: <_pytest.config.Config object at 0x7f1da3c09270> collection_path: /home/webdev/Desktop/octopwnweb/code/projects/unicrypto/tests/htmlcov/d_1b326c20d678c8f6_ccm_py.html path: /home/webdev/Desktop/octopwnweb/code/projects/unicrypto/tests/htmlcov/d_1b326c20d678c8f6_ccm_py.html finish pytest_ignore_collect --> None [hook] pytest_collect_file [hook] parent: testsfailed=0 testscollected=0> file_path: /home/webdev/Desktop/octopwnweb/code/projects/unicrypto/tests/htmlcov/d_1b326c20d678c8f6_ccm_py.html path: /home/webdev/Desktop/octopwnweb/code/projects/unicrypto/tests/htmlcov/d_1b326c20d678c8f6_ccm_py.html finish pytest_collect_file --> [] [hook] pytest_ignore_collect [hook] config: <_pytest.config.Config object at 0x7f1da3c09270> collection_path: /home/webdev/Desktop/octopwnweb/code/projects/unicrypto/tests/htmlcov/d_1b326c20d678c8f6_gcc_bak_orig_py.html path: /home/webdev/Desktop/octopwnweb/code/projects/unicrypto/tests/htmlcov/d_1b326c20d678c8f6_gcc_bak_orig_py.html finish pytest_ignore_collect --> None [hook] pytest_collect_file [hook] parent: testsfailed=0 testscollected=0> file_path: /home/webdev/Desktop/octopwnweb/code/projects/unicrypto/tests/htmlcov/d_1b326c20d678c8f6_gcc_bak_orig_py.html path: /home/webdev/Desktop/octopwnweb/code/projects/unicrypto/tests/htmlcov/d_1b326c20d678c8f6_gcc_bak_orig_py.html finish pytest_collect_file --> [] [hook] pytest_ignore_collect [hook] config: <_pytest.config.Config object at 0x7f1da3c09270> collection_path: /home/webdev/Desktop/octopwnweb/code/projects/unicrypto/tests/htmlcov/d_1b326c20d678c8f6_util_py.html path: /home/webdev/Desktop/octopwnweb/code/projects/unicrypto/tests/htmlcov/d_1b326c20d678c8f6_util_py.html finish pytest_ignore_collect --> None [hook] pytest_collect_file [hook] parent: testsfailed=0 testscollected=0> file_path: /home/webdev/Desktop/octopwnweb/code/projects/unicrypto/tests/htmlcov/d_1b326c20d678c8f6_util_py.html path: /home/webdev/Desktop/octopwnweb/code/projects/unicrypto/tests/htmlcov/d_1b326c20d678c8f6_util_py.html finish pytest_collect_file --> [] [hook] pytest_ignore_collect [hook] config: <_pytest.config.Config object at 0x7f1da3c09270> collection_path: /home/webdev/Desktop/octopwnweb/code/projects/unicrypto/tests/htmlcov/d_251f17693116e7b2_AES_py.html path: /home/webdev/Desktop/octopwnweb/code/projects/unicrypto/tests/htmlcov/d_251f17693116e7b2_AES_py.html finish pytest_ignore_collect --> None [hook] pytest_collect_file [hook] parent: testsfailed=0 testscollected=0> file_path: /home/webdev/Desktop/octopwnweb/code/projects/unicrypto/tests/htmlcov/d_251f17693116e7b2_AES_py.html path: /home/webdev/Desktop/octopwnweb/code/projects/unicrypto/tests/htmlcov/d_251f17693116e7b2_AES_py.html finish pytest_collect_file --> [] [hook] pytest_ignore_collect [hook] config: <_pytest.config.Config object at 0x7f1da3c09270> collection_path: /home/webdev/Desktop/octopwnweb/code/projects/unicrypto/tests/htmlcov/d_251f17693116e7b2_DES_py.html path: /home/webdev/Desktop/octopwnweb/code/projects/unicrypto/tests/htmlcov/d_251f17693116e7b2_DES_py.html finish pytest_ignore_collect --> None [hook] pytest_collect_file [hook] parent: testsfailed=0 testscollected=0> file_path: /home/webdev/Desktop/octopwnweb/code/projects/unicrypto/tests/htmlcov/d_251f17693116e7b2_DES_py.html path: /home/webdev/Desktop/octopwnweb/code/projects/unicrypto/tests/htmlcov/d_251f17693116e7b2_DES_py.html finish pytest_collect_file --> [] [hook] pytest_ignore_collect [hook] config: <_pytest.config.Config object at 0x7f1da3c09270> collection_path: /home/webdev/Desktop/octopwnweb/code/projects/unicrypto/tests/htmlcov/d_251f17693116e7b2_RC4_py.html path: /home/webdev/Desktop/octopwnweb/code/projects/unicrypto/tests/htmlcov/d_251f17693116e7b2_RC4_py.html finish pytest_ignore_collect --> None [hook] pytest_collect_file [hook] parent: testsfailed=0 testscollected=0> file_path: /home/webdev/Desktop/octopwnweb/code/projects/unicrypto/tests/htmlcov/d_251f17693116e7b2_RC4_py.html path: /home/webdev/Desktop/octopwnweb/code/projects/unicrypto/tests/htmlcov/d_251f17693116e7b2_RC4_py.html finish pytest_collect_file --> [] [hook] pytest_ignore_collect [hook] config: <_pytest.config.Config object at 0x7f1da3c09270> collection_path: /home/webdev/Desktop/octopwnweb/code/projects/unicrypto/tests/htmlcov/d_251f17693116e7b2_TDES_py.html path: /home/webdev/Desktop/octopwnweb/code/projects/unicrypto/tests/htmlcov/d_251f17693116e7b2_TDES_py.html finish pytest_ignore_collect --> None [hook] pytest_collect_file [hook] parent: testsfailed=0 testscollected=0> file_path: /home/webdev/Desktop/octopwnweb/code/projects/unicrypto/tests/htmlcov/d_251f17693116e7b2_TDES_py.html path: /home/webdev/Desktop/octopwnweb/code/projects/unicrypto/tests/htmlcov/d_251f17693116e7b2_TDES_py.html finish pytest_collect_file --> [] [hook] pytest_ignore_collect [hook] config: <_pytest.config.Config object at 0x7f1da3c09270> collection_path: /home/webdev/Desktop/octopwnweb/code/projects/unicrypto/tests/htmlcov/d_251f17693116e7b2___init___py.html path: /home/webdev/Desktop/octopwnweb/code/projects/unicrypto/tests/htmlcov/d_251f17693116e7b2___init___py.html finish pytest_ignore_collect --> None [hook] pytest_collect_file [hook] parent: testsfailed=0 testscollected=0> file_path: /home/webdev/Desktop/octopwnweb/code/projects/unicrypto/tests/htmlcov/d_251f17693116e7b2___init___py.html path: /home/webdev/Desktop/octopwnweb/code/projects/unicrypto/tests/htmlcov/d_251f17693116e7b2___init___py.html finish pytest_collect_file --> [] [hook] pytest_ignore_collect [hook] config: <_pytest.config.Config object at 0x7f1da3c09270> collection_path: /home/webdev/Desktop/octopwnweb/code/projects/unicrypto/tests/htmlcov/d_2e5ad67125402140_AES_py.html path: /home/webdev/Desktop/octopwnweb/code/projects/unicrypto/tests/htmlcov/d_2e5ad67125402140_AES_py.html finish pytest_ignore_collect --> None [hook] pytest_collect_file [hook] parent: testsfailed=0 testscollected=0> file_path: /home/webdev/Desktop/octopwnweb/code/projects/unicrypto/tests/htmlcov/d_2e5ad67125402140_AES_py.html path: /home/webdev/Desktop/octopwnweb/code/projects/unicrypto/tests/htmlcov/d_2e5ad67125402140_AES_py.html finish pytest_collect_file --> [] [hook] pytest_ignore_collect [hook] config: <_pytest.config.Config object at 0x7f1da3c09270> collection_path: /home/webdev/Desktop/octopwnweb/code/projects/unicrypto/tests/htmlcov/d_2e5ad67125402140_DES_py.html path: /home/webdev/Desktop/octopwnweb/code/projects/unicrypto/tests/htmlcov/d_2e5ad67125402140_DES_py.html finish pytest_ignore_collect --> None [hook] pytest_collect_file [hook] parent: testsfailed=0 testscollected=0> file_path: /home/webdev/Desktop/octopwnweb/code/projects/unicrypto/tests/htmlcov/d_2e5ad67125402140_DES_py.html path: /home/webdev/Desktop/octopwnweb/code/projects/unicrypto/tests/htmlcov/d_2e5ad67125402140_DES_py.html finish pytest_collect_file --> [] [hook] pytest_ignore_collect [hook] config: <_pytest.config.Config object at 0x7f1da3c09270> collection_path: /home/webdev/Desktop/octopwnweb/code/projects/unicrypto/tests/htmlcov/d_2e5ad67125402140_RC4_py.html path: /home/webdev/Desktop/octopwnweb/code/projects/unicrypto/tests/htmlcov/d_2e5ad67125402140_RC4_py.html finish pytest_ignore_collect --> None [hook] pytest_collect_file [hook] parent: testsfailed=0 testscollected=0> file_path: /home/webdev/Desktop/octopwnweb/code/projects/unicrypto/tests/htmlcov/d_2e5ad67125402140_RC4_py.html path: /home/webdev/Desktop/octopwnweb/code/projects/unicrypto/tests/htmlcov/d_2e5ad67125402140_RC4_py.html finish pytest_collect_file --> [] [hook] pytest_ignore_collect [hook] config: <_pytest.config.Config object at 0x7f1da3c09270> collection_path: /home/webdev/Desktop/octopwnweb/code/projects/unicrypto/tests/htmlcov/d_2e5ad67125402140_TDES_py.html path: /home/webdev/Desktop/octopwnweb/code/projects/unicrypto/tests/htmlcov/d_2e5ad67125402140_TDES_py.html finish pytest_ignore_collect --> None [hook] pytest_collect_file [hook] parent: testsfailed=0 testscollected=0> file_path: /home/webdev/Desktop/octopwnweb/code/projects/unicrypto/tests/htmlcov/d_2e5ad67125402140_TDES_py.html path: /home/webdev/Desktop/octopwnweb/code/projects/unicrypto/tests/htmlcov/d_2e5ad67125402140_TDES_py.html finish pytest_collect_file --> [] [hook] pytest_ignore_collect [hook] config: <_pytest.config.Config object at 0x7f1da3c09270> collection_path: /home/webdev/Desktop/octopwnweb/code/projects/unicrypto/tests/htmlcov/d_2e5ad67125402140___init___py.html path: /home/webdev/Desktop/octopwnweb/code/projects/unicrypto/tests/htmlcov/d_2e5ad67125402140___init___py.html finish pytest_ignore_collect --> None [hook] pytest_collect_file [hook] parent: testsfailed=0 testscollected=0> file_path: /home/webdev/Desktop/octopwnweb/code/projects/unicrypto/tests/htmlcov/d_2e5ad67125402140___init___py.html path: /home/webdev/Desktop/octopwnweb/code/projects/unicrypto/tests/htmlcov/d_2e5ad67125402140___init___py.html finish pytest_collect_file --> [] [hook] pytest_ignore_collect [hook] config: <_pytest.config.Config object at 0x7f1da3c09270> collection_path: /home/webdev/Desktop/octopwnweb/code/projects/unicrypto/tests/htmlcov/d_6129138558f5e740_AES_py.html path: /home/webdev/Desktop/octopwnweb/code/projects/unicrypto/tests/htmlcov/d_6129138558f5e740_AES_py.html finish pytest_ignore_collect --> None [hook] pytest_collect_file [hook] parent: testsfailed=0 testscollected=0> file_path: /home/webdev/Desktop/octopwnweb/code/projects/unicrypto/tests/htmlcov/d_6129138558f5e740_AES_py.html path: /home/webdev/Desktop/octopwnweb/code/projects/unicrypto/tests/htmlcov/d_6129138558f5e740_AES_py.html finish pytest_collect_file --> [] [hook] pytest_ignore_collect [hook] config: <_pytest.config.Config object at 0x7f1da3c09270> collection_path: /home/webdev/Desktop/octopwnweb/code/projects/unicrypto/tests/htmlcov/d_6129138558f5e740_DES_py.html path: /home/webdev/Desktop/octopwnweb/code/projects/unicrypto/tests/htmlcov/d_6129138558f5e740_DES_py.html finish pytest_ignore_collect --> None [hook] pytest_collect_file [hook] parent: testsfailed=0 testscollected=0> file_path: /home/webdev/Desktop/octopwnweb/code/projects/unicrypto/tests/htmlcov/d_6129138558f5e740_DES_py.html path: /home/webdev/Desktop/octopwnweb/code/projects/unicrypto/tests/htmlcov/d_6129138558f5e740_DES_py.html finish pytest_collect_file --> [] [hook] pytest_ignore_collect [hook] config: <_pytest.config.Config object at 0x7f1da3c09270> collection_path: /home/webdev/Desktop/octopwnweb/code/projects/unicrypto/tests/htmlcov/d_6129138558f5e740_RC4_py.html path: /home/webdev/Desktop/octopwnweb/code/projects/unicrypto/tests/htmlcov/d_6129138558f5e740_RC4_py.html finish pytest_ignore_collect --> None [hook] pytest_collect_file [hook] parent: testsfailed=0 testscollected=0> file_path: /home/webdev/Desktop/octopwnweb/code/projects/unicrypto/tests/htmlcov/d_6129138558f5e740_RC4_py.html path: /home/webdev/Desktop/octopwnweb/code/projects/unicrypto/tests/htmlcov/d_6129138558f5e740_RC4_py.html finish pytest_collect_file --> [] [hook] pytest_ignore_collect [hook] config: <_pytest.config.Config object at 0x7f1da3c09270> collection_path: /home/webdev/Desktop/octopwnweb/code/projects/unicrypto/tests/htmlcov/d_6129138558f5e740_TDES_py.html path: /home/webdev/Desktop/octopwnweb/code/projects/unicrypto/tests/htmlcov/d_6129138558f5e740_TDES_py.html finish pytest_ignore_collect --> None [hook] pytest_collect_file [hook] parent: testsfailed=0 testscollected=0> file_path: /home/webdev/Desktop/octopwnweb/code/projects/unicrypto/tests/htmlcov/d_6129138558f5e740_TDES_py.html path: /home/webdev/Desktop/octopwnweb/code/projects/unicrypto/tests/htmlcov/d_6129138558f5e740_TDES_py.html finish pytest_collect_file --> [] [hook] pytest_ignore_collect [hook] config: <_pytest.config.Config object at 0x7f1da3c09270> collection_path: /home/webdev/Desktop/octopwnweb/code/projects/unicrypto/tests/htmlcov/d_6129138558f5e740___init___py.html path: /home/webdev/Desktop/octopwnweb/code/projects/unicrypto/tests/htmlcov/d_6129138558f5e740___init___py.html finish pytest_ignore_collect --> None [hook] pytest_collect_file [hook] parent: testsfailed=0 testscollected=0> file_path: /home/webdev/Desktop/octopwnweb/code/projects/unicrypto/tests/htmlcov/d_6129138558f5e740___init___py.html path: /home/webdev/Desktop/octopwnweb/code/projects/unicrypto/tests/htmlcov/d_6129138558f5e740___init___py.html finish pytest_collect_file --> [] [hook] pytest_ignore_collect [hook] config: <_pytest.config.Config object at 0x7f1da3c09270> collection_path: /home/webdev/Desktop/octopwnweb/code/projects/unicrypto/tests/htmlcov/d_7d646dc836ec9617_AES_py.html path: /home/webdev/Desktop/octopwnweb/code/projects/unicrypto/tests/htmlcov/d_7d646dc836ec9617_AES_py.html finish pytest_ignore_collect --> None [hook] pytest_collect_file [hook] parent: testsfailed=0 testscollected=0> file_path: /home/webdev/Desktop/octopwnweb/code/projects/unicrypto/tests/htmlcov/d_7d646dc836ec9617_AES_py.html path: /home/webdev/Desktop/octopwnweb/code/projects/unicrypto/tests/htmlcov/d_7d646dc836ec9617_AES_py.html finish pytest_collect_file --> [] [hook] pytest_ignore_collect [hook] config: <_pytest.config.Config object at 0x7f1da3c09270> collection_path: /home/webdev/Desktop/octopwnweb/code/projects/unicrypto/tests/htmlcov/d_7d646dc836ec9617_DES_py.html path: /home/webdev/Desktop/octopwnweb/code/projects/unicrypto/tests/htmlcov/d_7d646dc836ec9617_DES_py.html finish pytest_ignore_collect --> None [hook] pytest_collect_file [hook] parent: testsfailed=0 testscollected=0> file_path: /home/webdev/Desktop/octopwnweb/code/projects/unicrypto/tests/htmlcov/d_7d646dc836ec9617_DES_py.html path: /home/webdev/Desktop/octopwnweb/code/projects/unicrypto/tests/htmlcov/d_7d646dc836ec9617_DES_py.html finish pytest_collect_file --> [] [hook] pytest_ignore_collect [hook] config: <_pytest.config.Config object at 0x7f1da3c09270> collection_path: /home/webdev/Desktop/octopwnweb/code/projects/unicrypto/tests/htmlcov/d_7d646dc836ec9617_MD4_py.html path: /home/webdev/Desktop/octopwnweb/code/projects/unicrypto/tests/htmlcov/d_7d646dc836ec9617_MD4_py.html finish pytest_ignore_collect --> None [hook] pytest_collect_file [hook] parent: testsfailed=0 testscollected=0> file_path: /home/webdev/Desktop/octopwnweb/code/projects/unicrypto/tests/htmlcov/d_7d646dc836ec9617_MD4_py.html path: /home/webdev/Desktop/octopwnweb/code/projects/unicrypto/tests/htmlcov/d_7d646dc836ec9617_MD4_py.html finish pytest_collect_file --> [] [hook] pytest_ignore_collect [hook] config: <_pytest.config.Config object at 0x7f1da3c09270> collection_path: /home/webdev/Desktop/octopwnweb/code/projects/unicrypto/tests/htmlcov/d_7d646dc836ec9617_RC4_py.html path: /home/webdev/Desktop/octopwnweb/code/projects/unicrypto/tests/htmlcov/d_7d646dc836ec9617_RC4_py.html finish pytest_ignore_collect --> None [hook] pytest_collect_file [hook] parent: testsfailed=0 testscollected=0> file_path: /home/webdev/Desktop/octopwnweb/code/projects/unicrypto/tests/htmlcov/d_7d646dc836ec9617_RC4_py.html path: /home/webdev/Desktop/octopwnweb/code/projects/unicrypto/tests/htmlcov/d_7d646dc836ec9617_RC4_py.html finish pytest_collect_file --> [] [hook] pytest_ignore_collect [hook] config: <_pytest.config.Config object at 0x7f1da3c09270> collection_path: /home/webdev/Desktop/octopwnweb/code/projects/unicrypto/tests/htmlcov/d_7d646dc836ec9617_TDES_py.html path: /home/webdev/Desktop/octopwnweb/code/projects/unicrypto/tests/htmlcov/d_7d646dc836ec9617_TDES_py.html finish pytest_ignore_collect --> None [hook] pytest_collect_file [hook] parent: testsfailed=0 testscollected=0> file_path: /home/webdev/Desktop/octopwnweb/code/projects/unicrypto/tests/htmlcov/d_7d646dc836ec9617_TDES_py.html path: /home/webdev/Desktop/octopwnweb/code/projects/unicrypto/tests/htmlcov/d_7d646dc836ec9617_TDES_py.html finish pytest_collect_file --> [] [hook] pytest_ignore_collect [hook] config: <_pytest.config.Config object at 0x7f1da3c09270> collection_path: /home/webdev/Desktop/octopwnweb/code/projects/unicrypto/tests/htmlcov/d_7d646dc836ec9617___init___py.html path: /home/webdev/Desktop/octopwnweb/code/projects/unicrypto/tests/htmlcov/d_7d646dc836ec9617___init___py.html finish pytest_ignore_collect --> None [hook] pytest_collect_file [hook] parent: testsfailed=0 testscollected=0> file_path: /home/webdev/Desktop/octopwnweb/code/projects/unicrypto/tests/htmlcov/d_7d646dc836ec9617___init___py.html path: /home/webdev/Desktop/octopwnweb/code/projects/unicrypto/tests/htmlcov/d_7d646dc836ec9617___init___py.html finish pytest_collect_file --> [] [hook] pytest_ignore_collect [hook] config: <_pytest.config.Config object at 0x7f1da3c09270> collection_path: /home/webdev/Desktop/octopwnweb/code/projects/unicrypto/tests/htmlcov/d_7ea8e34bf0d7f4e4_DES_py.html path: /home/webdev/Desktop/octopwnweb/code/projects/unicrypto/tests/htmlcov/d_7ea8e34bf0d7f4e4_DES_py.html finish pytest_ignore_collect --> None [hook] pytest_collect_file [hook] parent: testsfailed=0 testscollected=0> file_path: /home/webdev/Desktop/octopwnweb/code/projects/unicrypto/tests/htmlcov/d_7ea8e34bf0d7f4e4_DES_py.html path: /home/webdev/Desktop/octopwnweb/code/projects/unicrypto/tests/htmlcov/d_7ea8e34bf0d7f4e4_DES_py.html finish pytest_collect_file --> [] [hook] pytest_ignore_collect [hook] config: <_pytest.config.Config object at 0x7f1da3c09270> collection_path: /home/webdev/Desktop/octopwnweb/code/projects/unicrypto/tests/htmlcov/d_7ea8e34bf0d7f4e4___init___py.html path: /home/webdev/Desktop/octopwnweb/code/projects/unicrypto/tests/htmlcov/d_7ea8e34bf0d7f4e4___init___py.html finish pytest_ignore_collect --> None [hook] pytest_collect_file [hook] parent: testsfailed=0 testscollected=0> file_path: /home/webdev/Desktop/octopwnweb/code/projects/unicrypto/tests/htmlcov/d_7ea8e34bf0d7f4e4___init___py.html path: /home/webdev/Desktop/octopwnweb/code/projects/unicrypto/tests/htmlcov/d_7ea8e34bf0d7f4e4___init___py.html finish pytest_collect_file --> [] [hook] pytest_ignore_collect [hook] config: <_pytest.config.Config object at 0x7f1da3c09270> collection_path: /home/webdev/Desktop/octopwnweb/code/projects/unicrypto/tests/htmlcov/d_a01d58846f10b105_AESGCM_py.html path: /home/webdev/Desktop/octopwnweb/code/projects/unicrypto/tests/htmlcov/d_a01d58846f10b105_AESGCM_py.html finish pytest_ignore_collect --> None [hook] pytest_collect_file [hook] parent: testsfailed=0 testscollected=0> file_path: /home/webdev/Desktop/octopwnweb/code/projects/unicrypto/tests/htmlcov/d_a01d58846f10b105_AESGCM_py.html path: /home/webdev/Desktop/octopwnweb/code/projects/unicrypto/tests/htmlcov/d_a01d58846f10b105_AESGCM_py.html finish pytest_collect_file --> [] [hook] pytest_ignore_collect [hook] config: <_pytest.config.Config object at 0x7f1da3c09270> collection_path: /home/webdev/Desktop/octopwnweb/code/projects/unicrypto/tests/htmlcov/d_a01d58846f10b105___init___py.html path: /home/webdev/Desktop/octopwnweb/code/projects/unicrypto/tests/htmlcov/d_a01d58846f10b105___init___py.html finish pytest_ignore_collect --> None [hook] pytest_collect_file [hook] parent: testsfailed=0 testscollected=0> file_path: /home/webdev/Desktop/octopwnweb/code/projects/unicrypto/tests/htmlcov/d_a01d58846f10b105___init___py.html path: /home/webdev/Desktop/octopwnweb/code/projects/unicrypto/tests/htmlcov/d_a01d58846f10b105___init___py.html finish pytest_collect_file --> [] [hook] pytest_ignore_collect [hook] config: <_pytest.config.Config object at 0x7f1da3c09270> collection_path: /home/webdev/Desktop/octopwnweb/code/projects/unicrypto/tests/htmlcov/d_aef2cb7bed9f28fc___init___py.html path: /home/webdev/Desktop/octopwnweb/code/projects/unicrypto/tests/htmlcov/d_aef2cb7bed9f28fc___init___py.html finish pytest_ignore_collect --> None [hook] pytest_collect_file [hook] parent: testsfailed=0 testscollected=0> file_path: /home/webdev/Desktop/octopwnweb/code/projects/unicrypto/tests/htmlcov/d_aef2cb7bed9f28fc___init___py.html path: /home/webdev/Desktop/octopwnweb/code/projects/unicrypto/tests/htmlcov/d_aef2cb7bed9f28fc___init___py.html finish pytest_collect_file --> [] [hook] pytest_ignore_collect [hook] config: <_pytest.config.Config object at 0x7f1da3c09270> collection_path: /home/webdev/Desktop/octopwnweb/code/projects/unicrypto/tests/htmlcov/d_aef2cb7bed9f28fc_pkcs7_py.html path: /home/webdev/Desktop/octopwnweb/code/projects/unicrypto/tests/htmlcov/d_aef2cb7bed9f28fc_pkcs7_py.html finish pytest_ignore_collect --> None [hook] pytest_collect_file [hook] parent: testsfailed=0 testscollected=0> file_path: /home/webdev/Desktop/octopwnweb/code/projects/unicrypto/tests/htmlcov/d_aef2cb7bed9f28fc_pkcs7_py.html path: /home/webdev/Desktop/octopwnweb/code/projects/unicrypto/tests/htmlcov/d_aef2cb7bed9f28fc_pkcs7_py.html finish pytest_collect_file --> [] [hook] pytest_ignore_collect [hook] config: <_pytest.config.Config object at 0x7f1da3c09270> collection_path: /home/webdev/Desktop/octopwnweb/code/projects/unicrypto/tests/htmlcov/d_c18e496b448ab961___init___py.html path: /home/webdev/Desktop/octopwnweb/code/projects/unicrypto/tests/htmlcov/d_c18e496b448ab961___init___py.html finish pytest_ignore_collect --> None [hook] pytest_collect_file [hook] parent: testsfailed=0 testscollected=0> file_path: /home/webdev/Desktop/octopwnweb/code/projects/unicrypto/tests/htmlcov/d_c18e496b448ab961___init___py.html path: /home/webdev/Desktop/octopwnweb/code/projects/unicrypto/tests/htmlcov/d_c18e496b448ab961___init___py.html finish pytest_collect_file --> [] [hook] pytest_ignore_collect [hook] config: <_pytest.config.Config object at 0x7f1da3c09270> collection_path: /home/webdev/Desktop/octopwnweb/code/projects/unicrypto/tests/htmlcov/d_c18e496b448ab961_cmac_py.html path: /home/webdev/Desktop/octopwnweb/code/projects/unicrypto/tests/htmlcov/d_c18e496b448ab961_cmac_py.html finish pytest_ignore_collect --> None [hook] pytest_collect_file [hook] parent: testsfailed=0 testscollected=0> file_path: /home/webdev/Desktop/octopwnweb/code/projects/unicrypto/tests/htmlcov/d_c18e496b448ab961_cmac_py.html path: /home/webdev/Desktop/octopwnweb/code/projects/unicrypto/tests/htmlcov/d_c18e496b448ab961_cmac_py.html finish pytest_collect_file --> [] [hook] pytest_ignore_collect [hook] config: <_pytest.config.Config object at 0x7f1da3c09270> collection_path: /home/webdev/Desktop/octopwnweb/code/projects/unicrypto/tests/htmlcov/d_c18e496b448ab961_kdf_py.html path: /home/webdev/Desktop/octopwnweb/code/projects/unicrypto/tests/htmlcov/d_c18e496b448ab961_kdf_py.html finish pytest_ignore_collect --> None [hook] pytest_collect_file [hook] parent: testsfailed=0 testscollected=0> file_path: /home/webdev/Desktop/octopwnweb/code/projects/unicrypto/tests/htmlcov/d_c18e496b448ab961_kdf_py.html path: /home/webdev/Desktop/octopwnweb/code/projects/unicrypto/tests/htmlcov/d_c18e496b448ab961_kdf_py.html finish pytest_collect_file --> [] [hook] pytest_ignore_collect [hook] config: <_pytest.config.Config object at 0x7f1da3c09270> collection_path: /home/webdev/Desktop/octopwnweb/code/projects/unicrypto/tests/htmlcov/d_d66001d28a41f951___init___py.html path: /home/webdev/Desktop/octopwnweb/code/projects/unicrypto/tests/htmlcov/d_d66001d28a41f951___init___py.html finish pytest_ignore_collect --> None [hook] pytest_collect_file [hook] parent: testsfailed=0 testscollected=0> file_path: /home/webdev/Desktop/octopwnweb/code/projects/unicrypto/tests/htmlcov/d_d66001d28a41f951___init___py.html path: /home/webdev/Desktop/octopwnweb/code/projects/unicrypto/tests/htmlcov/d_d66001d28a41f951___init___py.html finish pytest_collect_file --> [] [hook] pytest_ignore_collect [hook] config: <_pytest.config.Config object at 0x7f1da3c09270> collection_path: /home/webdev/Desktop/octopwnweb/code/projects/unicrypto/tests/htmlcov/d_d66001d28a41f951__version_py.html path: /home/webdev/Desktop/octopwnweb/code/projects/unicrypto/tests/htmlcov/d_d66001d28a41f951__version_py.html finish pytest_ignore_collect --> None [hook] pytest_collect_file [hook] parent: testsfailed=0 testscollected=0> file_path: /home/webdev/Desktop/octopwnweb/code/projects/unicrypto/tests/htmlcov/d_d66001d28a41f951__version_py.html path: /home/webdev/Desktop/octopwnweb/code/projects/unicrypto/tests/htmlcov/d_d66001d28a41f951__version_py.html finish pytest_collect_file --> [] [hook] pytest_ignore_collect [hook] config: <_pytest.config.Config object at 0x7f1da3c09270> collection_path: /home/webdev/Desktop/octopwnweb/code/projects/unicrypto/tests/htmlcov/d_d66001d28a41f951_cmac_py.html path: /home/webdev/Desktop/octopwnweb/code/projects/unicrypto/tests/htmlcov/d_d66001d28a41f951_cmac_py.html finish pytest_ignore_collect --> None [hook] pytest_collect_file [hook] parent: testsfailed=0 testscollected=0> file_path: /home/webdev/Desktop/octopwnweb/code/projects/unicrypto/tests/htmlcov/d_d66001d28a41f951_cmac_py.html path: /home/webdev/Desktop/octopwnweb/code/projects/unicrypto/tests/htmlcov/d_d66001d28a41f951_cmac_py.html finish pytest_collect_file --> [] [hook] pytest_ignore_collect [hook] config: <_pytest.config.Config object at 0x7f1da3c09270> collection_path: /home/webdev/Desktop/octopwnweb/code/projects/unicrypto/tests/htmlcov/d_d66001d28a41f951_hashlib_py.html path: /home/webdev/Desktop/octopwnweb/code/projects/unicrypto/tests/htmlcov/d_d66001d28a41f951_hashlib_py.html finish pytest_ignore_collect --> None [hook] pytest_collect_file [hook] parent: testsfailed=0 testscollected=0> file_path: /home/webdev/Desktop/octopwnweb/code/projects/unicrypto/tests/htmlcov/d_d66001d28a41f951_hashlib_py.html path: /home/webdev/Desktop/octopwnweb/code/projects/unicrypto/tests/htmlcov/d_d66001d28a41f951_hashlib_py.html finish pytest_collect_file --> [] [hook] pytest_ignore_collect [hook] config: <_pytest.config.Config object at 0x7f1da3c09270> collection_path: /home/webdev/Desktop/octopwnweb/code/projects/unicrypto/tests/htmlcov/d_d66001d28a41f951_hmac_py.html path: /home/webdev/Desktop/octopwnweb/code/projects/unicrypto/tests/htmlcov/d_d66001d28a41f951_hmac_py.html finish pytest_ignore_collect --> None [hook] pytest_collect_file [hook] parent: testsfailed=0 testscollected=0> file_path: /home/webdev/Desktop/octopwnweb/code/projects/unicrypto/tests/htmlcov/d_d66001d28a41f951_hmac_py.html path: /home/webdev/Desktop/octopwnweb/code/projects/unicrypto/tests/htmlcov/d_d66001d28a41f951_hmac_py.html finish pytest_collect_file --> [] [hook] pytest_ignore_collect [hook] config: <_pytest.config.Config object at 0x7f1da3c09270> collection_path: /home/webdev/Desktop/octopwnweb/code/projects/unicrypto/tests/htmlcov/d_d66001d28a41f951_kdf_py.html path: /home/webdev/Desktop/octopwnweb/code/projects/unicrypto/tests/htmlcov/d_d66001d28a41f951_kdf_py.html finish pytest_ignore_collect --> None [hook] pytest_collect_file [hook] parent: testsfailed=0 testscollected=0> file_path: /home/webdev/Desktop/octopwnweb/code/projects/unicrypto/tests/htmlcov/d_d66001d28a41f951_kdf_py.html path: /home/webdev/Desktop/octopwnweb/code/projects/unicrypto/tests/htmlcov/d_d66001d28a41f951_kdf_py.html finish pytest_collect_file --> [] [hook] pytest_ignore_collect [hook] config: <_pytest.config.Config object at 0x7f1da3c09270> collection_path: /home/webdev/Desktop/octopwnweb/code/projects/unicrypto/tests/htmlcov/d_d66001d28a41f951_pbkdf2_py.html path: /home/webdev/Desktop/octopwnweb/code/projects/unicrypto/tests/htmlcov/d_d66001d28a41f951_pbkdf2_py.html finish pytest_ignore_collect --> None [hook] pytest_collect_file [hook] parent: testsfailed=0 testscollected=0> file_path: /home/webdev/Desktop/octopwnweb/code/projects/unicrypto/tests/htmlcov/d_d66001d28a41f951_pbkdf2_py.html path: /home/webdev/Desktop/octopwnweb/code/projects/unicrypto/tests/htmlcov/d_d66001d28a41f951_pbkdf2_py.html finish pytest_collect_file --> [] [hook] pytest_ignore_collect [hook] config: <_pytest.config.Config object at 0x7f1da3c09270> collection_path: /home/webdev/Desktop/octopwnweb/code/projects/unicrypto/tests/htmlcov/d_d66001d28a41f951_symmetric_py.html path: /home/webdev/Desktop/octopwnweb/code/projects/unicrypto/tests/htmlcov/d_d66001d28a41f951_symmetric_py.html finish pytest_ignore_collect --> None [hook] pytest_collect_file [hook] parent: testsfailed=0 testscollected=0> file_path: /home/webdev/Desktop/octopwnweb/code/projects/unicrypto/tests/htmlcov/d_d66001d28a41f951_symmetric_py.html path: /home/webdev/Desktop/octopwnweb/code/projects/unicrypto/tests/htmlcov/d_d66001d28a41f951_symmetric_py.html finish pytest_collect_file --> [] [hook] pytest_ignore_collect [hook] config: <_pytest.config.Config object at 0x7f1da3c09270> collection_path: /home/webdev/Desktop/octopwnweb/code/projects/unicrypto/tests/htmlcov/favicon_32.png path: /home/webdev/Desktop/octopwnweb/code/projects/unicrypto/tests/htmlcov/favicon_32.png finish pytest_ignore_collect --> None [hook] pytest_collect_file [hook] parent: testsfailed=0 testscollected=0> file_path: /home/webdev/Desktop/octopwnweb/code/projects/unicrypto/tests/htmlcov/favicon_32.png path: /home/webdev/Desktop/octopwnweb/code/projects/unicrypto/tests/htmlcov/favicon_32.png finish pytest_collect_file --> [] [hook] pytest_ignore_collect [hook] config: <_pytest.config.Config object at 0x7f1da3c09270> collection_path: /home/webdev/Desktop/octopwnweb/code/projects/unicrypto/tests/htmlcov/index.html path: /home/webdev/Desktop/octopwnweb/code/projects/unicrypto/tests/htmlcov/index.html finish pytest_ignore_collect --> None [hook] pytest_collect_file [hook] parent: testsfailed=0 testscollected=0> file_path: /home/webdev/Desktop/octopwnweb/code/projects/unicrypto/tests/htmlcov/index.html path: /home/webdev/Desktop/octopwnweb/code/projects/unicrypto/tests/htmlcov/index.html finish pytest_collect_file --> [] [hook] pytest_ignore_collect [hook] config: <_pytest.config.Config object at 0x7f1da3c09270> collection_path: /home/webdev/Desktop/octopwnweb/code/projects/unicrypto/tests/htmlcov/keybd_closed.png path: /home/webdev/Desktop/octopwnweb/code/projects/unicrypto/tests/htmlcov/keybd_closed.png finish pytest_ignore_collect --> None [hook] pytest_collect_file [hook] parent: testsfailed=0 testscollected=0> file_path: /home/webdev/Desktop/octopwnweb/code/projects/unicrypto/tests/htmlcov/keybd_closed.png path: /home/webdev/Desktop/octopwnweb/code/projects/unicrypto/tests/htmlcov/keybd_closed.png finish pytest_collect_file --> [] [hook] pytest_ignore_collect [hook] config: <_pytest.config.Config object at 0x7f1da3c09270> collection_path: /home/webdev/Desktop/octopwnweb/code/projects/unicrypto/tests/htmlcov/keybd_open.png path: /home/webdev/Desktop/octopwnweb/code/projects/unicrypto/tests/htmlcov/keybd_open.png finish pytest_ignore_collect --> None [hook] pytest_collect_file [hook] parent: testsfailed=0 testscollected=0> file_path: /home/webdev/Desktop/octopwnweb/code/projects/unicrypto/tests/htmlcov/keybd_open.png path: /home/webdev/Desktop/octopwnweb/code/projects/unicrypto/tests/htmlcov/keybd_open.png finish pytest_collect_file --> [] [hook] pytest_ignore_collect [hook] config: <_pytest.config.Config object at 0x7f1da3c09270> collection_path: /home/webdev/Desktop/octopwnweb/code/projects/unicrypto/tests/htmlcov/status.json path: /home/webdev/Desktop/octopwnweb/code/projects/unicrypto/tests/htmlcov/status.json finish pytest_ignore_collect --> None [hook] pytest_collect_file [hook] parent: testsfailed=0 testscollected=0> file_path: /home/webdev/Desktop/octopwnweb/code/projects/unicrypto/tests/htmlcov/status.json path: /home/webdev/Desktop/octopwnweb/code/projects/unicrypto/tests/htmlcov/status.json finish pytest_collect_file --> [] [hook] pytest_ignore_collect [hook] config: <_pytest.config.Config object at 0x7f1da3c09270> collection_path: /home/webdev/Desktop/octopwnweb/code/projects/unicrypto/tests/htmlcov/style.css path: /home/webdev/Desktop/octopwnweb/code/projects/unicrypto/tests/htmlcov/style.css finish pytest_ignore_collect --> None [hook] pytest_collect_file [hook] parent: testsfailed=0 testscollected=0> file_path: /home/webdev/Desktop/octopwnweb/code/projects/unicrypto/tests/htmlcov/style.css path: /home/webdev/Desktop/octopwnweb/code/projects/unicrypto/tests/htmlcov/style.css finish pytest_collect_file --> [] [hook] pytest_ignore_collect [hook] config: <_pytest.config.Config object at 0x7f1da3c09270> collection_path: /home/webdev/Desktop/octopwnweb/code/projects/unicrypto/tests/htmlcov/test_aes_py.html path: /home/webdev/Desktop/octopwnweb/code/projects/unicrypto/tests/htmlcov/test_aes_py.html finish pytest_ignore_collect --> None [hook] pytest_collect_file [hook] parent: testsfailed=0 testscollected=0> file_path: /home/webdev/Desktop/octopwnweb/code/projects/unicrypto/tests/htmlcov/test_aes_py.html path: /home/webdev/Desktop/octopwnweb/code/projects/unicrypto/tests/htmlcov/test_aes_py.html finish pytest_collect_file --> [] [hook] pytest_ignore_collect [hook] config: <_pytest.config.Config object at 0x7f1da3c09270> collection_path: /home/webdev/Desktop/octopwnweb/code/projects/unicrypto/tests/htmlcov/test_des_py.html path: /home/webdev/Desktop/octopwnweb/code/projects/unicrypto/tests/htmlcov/test_des_py.html finish pytest_ignore_collect --> None [hook] pytest_collect_file [hook] parent: testsfailed=0 testscollected=0> file_path: /home/webdev/Desktop/octopwnweb/code/projects/unicrypto/tests/htmlcov/test_des_py.html path: /home/webdev/Desktop/octopwnweb/code/projects/unicrypto/tests/htmlcov/test_des_py.html finish pytest_collect_file --> [] [hook] pytest_ignore_collect [hook] config: <_pytest.config.Config object at 0x7f1da3c09270> collection_path: /home/webdev/Desktop/octopwnweb/code/projects/unicrypto/tests/htmlcov/test_import_py.html path: /home/webdev/Desktop/octopwnweb/code/projects/unicrypto/tests/htmlcov/test_import_py.html finish pytest_ignore_collect --> None [hook] pytest_collect_file [hook] parent: testsfailed=0 testscollected=0> file_path: /home/webdev/Desktop/octopwnweb/code/projects/unicrypto/tests/htmlcov/test_import_py.html path: /home/webdev/Desktop/octopwnweb/code/projects/unicrypto/tests/htmlcov/test_import_py.html finish pytest_collect_file --> [] [hook] pytest_ignore_collect [hook] config: <_pytest.config.Config object at 0x7f1da3c09270> collection_path: /home/webdev/Desktop/octopwnweb/code/projects/unicrypto/tests/htmlcov/test_pbkdf2_py.html path: /home/webdev/Desktop/octopwnweb/code/projects/unicrypto/tests/htmlcov/test_pbkdf2_py.html finish pytest_ignore_collect --> None [hook] pytest_collect_file [hook] parent: testsfailed=0 testscollected=0> file_path: /home/webdev/Desktop/octopwnweb/code/projects/unicrypto/tests/htmlcov/test_pbkdf2_py.html path: /home/webdev/Desktop/octopwnweb/code/projects/unicrypto/tests/htmlcov/test_pbkdf2_py.html finish pytest_collect_file --> [] [hook] pytest_ignore_collect [hook] config: <_pytest.config.Config object at 0x7f1da3c09270> collection_path: /home/webdev/Desktop/octopwnweb/code/projects/unicrypto/tests/htmlcov/test_rc4_py.html path: /home/webdev/Desktop/octopwnweb/code/projects/unicrypto/tests/htmlcov/test_rc4_py.html finish pytest_ignore_collect --> None [hook] pytest_collect_file [hook] parent: testsfailed=0 testscollected=0> file_path: /home/webdev/Desktop/octopwnweb/code/projects/unicrypto/tests/htmlcov/test_rc4_py.html path: /home/webdev/Desktop/octopwnweb/code/projects/unicrypto/tests/htmlcov/test_rc4_py.html finish pytest_collect_file --> [] [hook] pytest_ignore_collect [hook] config: <_pytest.config.Config object at 0x7f1da3c09270> collection_path: /home/webdev/Desktop/octopwnweb/code/projects/unicrypto/tests/htmlcov/test_tdes_py.html path: /home/webdev/Desktop/octopwnweb/code/projects/unicrypto/tests/htmlcov/test_tdes_py.html finish pytest_ignore_collect --> None [hook] pytest_collect_file [hook] parent: testsfailed=0 testscollected=0> file_path: /home/webdev/Desktop/octopwnweb/code/projects/unicrypto/tests/htmlcov/test_tdes_py.html path: /home/webdev/Desktop/octopwnweb/code/projects/unicrypto/tests/htmlcov/test_tdes_py.html finish pytest_collect_file --> [] [hook] pytest_ignore_collect [hook] config: <_pytest.config.Config object at 0x7f1da3c09270> collection_path: /home/webdev/Desktop/octopwnweb/code/projects/unicrypto/tests/testenv path: /home/webdev/Desktop/octopwnweb/code/projects/unicrypto/tests/testenv finish pytest_ignore_collect --> True [hook] finish pytest_make_collect_report --> [hook] pytest_collectreport [hook] report: finish pytest_collectreport --> [] [hook] genitems [collection] pytest_collectstart [hook] collector: finish pytest_collectstart --> [] [hook] pytest_make_collect_report [hook] collector: pytest_ignore_collect [hook] config: <_pytest.config.Config object at 0x7f1da3c09270> collection_path: /home/webdev/Desktop/octopwnweb/code/projects/unicrypto/tests/coverage.sh path: /home/webdev/Desktop/octopwnweb/code/projects/unicrypto/tests/coverage.sh finish pytest_ignore_collect --> None [hook] pytest_collect_file [hook] parent: file_path: /home/webdev/Desktop/octopwnweb/code/projects/unicrypto/tests/coverage.sh path: /home/webdev/Desktop/octopwnweb/code/projects/unicrypto/tests/coverage.sh finish pytest_collect_file --> [] [hook] pytest_ignore_collect [hook] config: <_pytest.config.Config object at 0x7f1da3c09270> collection_path: /home/webdev/Desktop/octopwnweb/code/projects/unicrypto/tests/coveragerc path: /home/webdev/Desktop/octopwnweb/code/projects/unicrypto/tests/coveragerc finish pytest_ignore_collect --> None [hook] pytest_collect_file [hook] parent: file_path: /home/webdev/Desktop/octopwnweb/code/projects/unicrypto/tests/coveragerc path: /home/webdev/Desktop/octopwnweb/code/projects/unicrypto/tests/coveragerc finish pytest_collect_file --> [] [hook] pytest_ignore_collect [hook] config: <_pytest.config.Config object at 0x7f1da3c09270> collection_path: /home/webdev/Desktop/octopwnweb/code/projects/unicrypto/tests/test_aes.py path: /home/webdev/Desktop/octopwnweb/code/projects/unicrypto/tests/test_aes.py finish pytest_ignore_collect --> None [hook] pytest_collect_file [hook] parent: file_path: /home/webdev/Desktop/octopwnweb/code/projects/unicrypto/tests/test_aes.py path: /home/webdev/Desktop/octopwnweb/code/projects/unicrypto/tests/test_aes.py pytest_pycollect_makemodule [hook] parent: module_path: /home/webdev/Desktop/octopwnweb/code/projects/unicrypto/tests/test_aes.py path: /home/webdev/Desktop/octopwnweb/code/projects/unicrypto/tests/test_aes.py finish pytest_pycollect_makemodule --> [hook] finish pytest_collect_file --> [] [hook] pytest_ignore_collect [hook] config: <_pytest.config.Config object at 0x7f1da3c09270> collection_path: /home/webdev/Desktop/octopwnweb/code/projects/unicrypto/tests/test_des.py path: /home/webdev/Desktop/octopwnweb/code/projects/unicrypto/tests/test_des.py finish pytest_ignore_collect --> None [hook] pytest_collect_file [hook] parent: file_path: /home/webdev/Desktop/octopwnweb/code/projects/unicrypto/tests/test_des.py path: /home/webdev/Desktop/octopwnweb/code/projects/unicrypto/tests/test_des.py pytest_pycollect_makemodule [hook] parent: module_path: /home/webdev/Desktop/octopwnweb/code/projects/unicrypto/tests/test_des.py path: /home/webdev/Desktop/octopwnweb/code/projects/unicrypto/tests/test_des.py finish pytest_pycollect_makemodule --> [hook] finish pytest_collect_file --> [] [hook] pytest_ignore_collect [hook] config: <_pytest.config.Config object at 0x7f1da3c09270> collection_path: /home/webdev/Desktop/octopwnweb/code/projects/unicrypto/tests/test_import.py path: /home/webdev/Desktop/octopwnweb/code/projects/unicrypto/tests/test_import.py finish pytest_ignore_collect --> None [hook] pytest_collect_file [hook] parent: file_path: /home/webdev/Desktop/octopwnweb/code/projects/unicrypto/tests/test_import.py path: /home/webdev/Desktop/octopwnweb/code/projects/unicrypto/tests/test_import.py pytest_pycollect_makemodule [hook] parent: module_path: /home/webdev/Desktop/octopwnweb/code/projects/unicrypto/tests/test_import.py path: /home/webdev/Desktop/octopwnweb/code/projects/unicrypto/tests/test_import.py finish pytest_pycollect_makemodule --> [hook] finish pytest_collect_file --> [] [hook] pytest_ignore_collect [hook] config: <_pytest.config.Config object at 0x7f1da3c09270> collection_path: /home/webdev/Desktop/octopwnweb/code/projects/unicrypto/tests/test_pbkdf2.py path: /home/webdev/Desktop/octopwnweb/code/projects/unicrypto/tests/test_pbkdf2.py finish pytest_ignore_collect --> None [hook] pytest_collect_file [hook] parent: file_path: /home/webdev/Desktop/octopwnweb/code/projects/unicrypto/tests/test_pbkdf2.py path: /home/webdev/Desktop/octopwnweb/code/projects/unicrypto/tests/test_pbkdf2.py pytest_pycollect_makemodule [hook] parent: module_path: /home/webdev/Desktop/octopwnweb/code/projects/unicrypto/tests/test_pbkdf2.py path: /home/webdev/Desktop/octopwnweb/code/projects/unicrypto/tests/test_pbkdf2.py finish pytest_pycollect_makemodule --> [hook] finish pytest_collect_file --> [] [hook] pytest_ignore_collect [hook] config: <_pytest.config.Config object at 0x7f1da3c09270> collection_path: /home/webdev/Desktop/octopwnweb/code/projects/unicrypto/tests/test_rc4.py path: /home/webdev/Desktop/octopwnweb/code/projects/unicrypto/tests/test_rc4.py finish pytest_ignore_collect --> None [hook] pytest_collect_file [hook] parent: file_path: /home/webdev/Desktop/octopwnweb/code/projects/unicrypto/tests/test_rc4.py path: /home/webdev/Desktop/octopwnweb/code/projects/unicrypto/tests/test_rc4.py pytest_pycollect_makemodule [hook] parent: module_path: /home/webdev/Desktop/octopwnweb/code/projects/unicrypto/tests/test_rc4.py path: /home/webdev/Desktop/octopwnweb/code/projects/unicrypto/tests/test_rc4.py finish pytest_pycollect_makemodule --> [hook] finish pytest_collect_file --> [] [hook] pytest_ignore_collect [hook] config: <_pytest.config.Config object at 0x7f1da3c09270> collection_path: /home/webdev/Desktop/octopwnweb/code/projects/unicrypto/tests/test_tdes.py path: /home/webdev/Desktop/octopwnweb/code/projects/unicrypto/tests/test_tdes.py finish pytest_ignore_collect --> None [hook] pytest_collect_file [hook] parent: file_path: /home/webdev/Desktop/octopwnweb/code/projects/unicrypto/tests/test_tdes.py path: /home/webdev/Desktop/octopwnweb/code/projects/unicrypto/tests/test_tdes.py pytest_pycollect_makemodule [hook] parent: module_path: /home/webdev/Desktop/octopwnweb/code/projects/unicrypto/tests/test_tdes.py path: /home/webdev/Desktop/octopwnweb/code/projects/unicrypto/tests/test_tdes.py finish pytest_pycollect_makemodule --> [hook] finish pytest_collect_file --> [] [hook] pytest_ignore_collect [hook] config: <_pytest.config.Config object at 0x7f1da3c09270> collection_path: /home/webdev/Desktop/octopwnweb/code/projects/unicrypto/tests/trace path: /home/webdev/Desktop/octopwnweb/code/projects/unicrypto/tests/trace finish pytest_ignore_collect --> None [hook] pytest_collect_file [hook] parent: file_path: /home/webdev/Desktop/octopwnweb/code/projects/unicrypto/tests/trace path: /home/webdev/Desktop/octopwnweb/code/projects/unicrypto/tests/trace finish pytest_collect_file --> [] [hook] pytest_ignore_collect [hook] config: <_pytest.config.Config object at 0x7f1da3c09270> collection_path: /home/webdev/Desktop/octopwnweb/code/projects/unicrypto/tests/htmlcov path: /home/webdev/Desktop/octopwnweb/code/projects/unicrypto/tests/htmlcov finish pytest_ignore_collect --> None [hook] pytest_ignore_collect [hook] config: <_pytest.config.Config object at 0x7f1da3c09270> collection_path: /home/webdev/Desktop/octopwnweb/code/projects/unicrypto/tests/htmlcov/.gitignore path: /home/webdev/Desktop/octopwnweb/code/projects/unicrypto/tests/htmlcov/.gitignore finish pytest_ignore_collect --> None [hook] pytest_ignore_collect [hook] config: <_pytest.config.Config object at 0x7f1da3c09270> collection_path: /home/webdev/Desktop/octopwnweb/code/projects/unicrypto/tests/htmlcov/__init___py.html path: /home/webdev/Desktop/octopwnweb/code/projects/unicrypto/tests/htmlcov/__init___py.html finish pytest_ignore_collect --> None [hook] pytest_ignore_collect [hook] config: <_pytest.config.Config object at 0x7f1da3c09270> collection_path: /home/webdev/Desktop/octopwnweb/code/projects/unicrypto/tests/htmlcov/coverage_html.js path: /home/webdev/Desktop/octopwnweb/code/projects/unicrypto/tests/htmlcov/coverage_html.js finish pytest_ignore_collect --> None [hook] pytest_ignore_collect [hook] config: <_pytest.config.Config object at 0x7f1da3c09270> collection_path: /home/webdev/Desktop/octopwnweb/code/projects/unicrypto/tests/htmlcov/d_0237501f9c494193___init___py.html path: /home/webdev/Desktop/octopwnweb/code/projects/unicrypto/tests/htmlcov/d_0237501f9c494193___init___py.html finish pytest_ignore_collect --> None [hook] pytest_ignore_collect [hook] config: <_pytest.config.Config object at 0x7f1da3c09270> collection_path: /home/webdev/Desktop/octopwnweb/code/projects/unicrypto/tests/htmlcov/d_028b69a877824f4a_RC4_py.html path: /home/webdev/Desktop/octopwnweb/code/projects/unicrypto/tests/htmlcov/d_028b69a877824f4a_RC4_py.html finish pytest_ignore_collect --> None [hook] pytest_ignore_collect [hook] config: <_pytest.config.Config object at 0x7f1da3c09270> collection_path: /home/webdev/Desktop/octopwnweb/code/projects/unicrypto/tests/htmlcov/d_028b69a877824f4a___init___py.html path: /home/webdev/Desktop/octopwnweb/code/projects/unicrypto/tests/htmlcov/d_028b69a877824f4a___init___py.html finish pytest_ignore_collect --> None [hook] pytest_ignore_collect [hook] config: <_pytest.config.Config object at 0x7f1da3c09270> collection_path: /home/webdev/Desktop/octopwnweb/code/projects/unicrypto/tests/htmlcov/d_0f217a5f66ae40f9_AES_py.html path: /home/webdev/Desktop/octopwnweb/code/projects/unicrypto/tests/htmlcov/d_0f217a5f66ae40f9_AES_py.html finish pytest_ignore_collect --> None [hook] pytest_ignore_collect [hook] config: <_pytest.config.Config object at 0x7f1da3c09270> collection_path: /home/webdev/Desktop/octopwnweb/code/projects/unicrypto/tests/htmlcov/d_0f217a5f66ae40f9_DES_py.html path: /home/webdev/Desktop/octopwnweb/code/projects/unicrypto/tests/htmlcov/d_0f217a5f66ae40f9_DES_py.html finish pytest_ignore_collect --> None [hook] pytest_ignore_collect [hook] config: <_pytest.config.Config object at 0x7f1da3c09270> collection_path: /home/webdev/Desktop/octopwnweb/code/projects/unicrypto/tests/htmlcov/d_0f217a5f66ae40f9_RC4_py.html path: /home/webdev/Desktop/octopwnweb/code/projects/unicrypto/tests/htmlcov/d_0f217a5f66ae40f9_RC4_py.html finish pytest_ignore_collect --> None [hook] pytest_ignore_collect [hook] config: <_pytest.config.Config object at 0x7f1da3c09270> collection_path: /home/webdev/Desktop/octopwnweb/code/projects/unicrypto/tests/htmlcov/d_0f217a5f66ae40f9_TDES_py.html path: /home/webdev/Desktop/octopwnweb/code/projects/unicrypto/tests/htmlcov/d_0f217a5f66ae40f9_TDES_py.html finish pytest_ignore_collect --> None [hook] pytest_ignore_collect [hook] config: <_pytest.config.Config object at 0x7f1da3c09270> collection_path: /home/webdev/Desktop/octopwnweb/code/projects/unicrypto/tests/htmlcov/d_0f217a5f66ae40f9___init___py.html path: /home/webdev/Desktop/octopwnweb/code/projects/unicrypto/tests/htmlcov/d_0f217a5f66ae40f9___init___py.html finish pytest_ignore_collect --> None [hook] pytest_ignore_collect [hook] config: <_pytest.config.Config object at 0x7f1da3c09270> collection_path: /home/webdev/Desktop/octopwnweb/code/projects/unicrypto/tests/htmlcov/d_12fa02817ba8b749_AES_py.html path: /home/webdev/Desktop/octopwnweb/code/projects/unicrypto/tests/htmlcov/d_12fa02817ba8b749_AES_py.html finish pytest_ignore_collect --> None [hook] pytest_ignore_collect [hook] config: <_pytest.config.Config object at 0x7f1da3c09270> collection_path: /home/webdev/Desktop/octopwnweb/code/projects/unicrypto/tests/htmlcov/d_12fa02817ba8b749_DES_py.html path: /home/webdev/Desktop/octopwnweb/code/projects/unicrypto/tests/htmlcov/d_12fa02817ba8b749_DES_py.html finish pytest_ignore_collect --> None [hook] pytest_ignore_collect [hook] config: <_pytest.config.Config object at 0x7f1da3c09270> collection_path: /home/webdev/Desktop/octopwnweb/code/projects/unicrypto/tests/htmlcov/d_12fa02817ba8b749_RC4_py.html path: /home/webdev/Desktop/octopwnweb/code/projects/unicrypto/tests/htmlcov/d_12fa02817ba8b749_RC4_py.html finish pytest_ignore_collect --> None [hook] pytest_ignore_collect [hook] config: <_pytest.config.Config object at 0x7f1da3c09270> collection_path: /home/webdev/Desktop/octopwnweb/code/projects/unicrypto/tests/htmlcov/d_12fa02817ba8b749_TDES_py.html path: /home/webdev/Desktop/octopwnweb/code/projects/unicrypto/tests/htmlcov/d_12fa02817ba8b749_TDES_py.html finish pytest_ignore_collect --> None [hook] pytest_ignore_collect [hook] config: <_pytest.config.Config object at 0x7f1da3c09270> collection_path: /home/webdev/Desktop/octopwnweb/code/projects/unicrypto/tests/htmlcov/d_12fa02817ba8b749___init___py.html path: /home/webdev/Desktop/octopwnweb/code/projects/unicrypto/tests/htmlcov/d_12fa02817ba8b749___init___py.html finish pytest_ignore_collect --> None [hook] pytest_ignore_collect [hook] config: <_pytest.config.Config object at 0x7f1da3c09270> collection_path: /home/webdev/Desktop/octopwnweb/code/projects/unicrypto/tests/htmlcov/d_1b326c20d678c8f6_AESCCM_py.html path: /home/webdev/Desktop/octopwnweb/code/projects/unicrypto/tests/htmlcov/d_1b326c20d678c8f6_AESCCM_py.html finish pytest_ignore_collect --> None [hook] pytest_ignore_collect [hook] config: <_pytest.config.Config object at 0x7f1da3c09270> collection_path: /home/webdev/Desktop/octopwnweb/code/projects/unicrypto/tests/htmlcov/d_1b326c20d678c8f6_AESGCM_py.html path: /home/webdev/Desktop/octopwnweb/code/projects/unicrypto/tests/htmlcov/d_1b326c20d678c8f6_AESGCM_py.html finish pytest_ignore_collect --> None [hook] pytest_ignore_collect [hook] config: <_pytest.config.Config object at 0x7f1da3c09270> collection_path: /home/webdev/Desktop/octopwnweb/code/projects/unicrypto/tests/htmlcov/d_1b326c20d678c8f6_AES_py.html path: /home/webdev/Desktop/octopwnweb/code/projects/unicrypto/tests/htmlcov/d_1b326c20d678c8f6_AES_py.html finish pytest_ignore_collect --> None [hook] pytest_ignore_collect [hook] config: <_pytest.config.Config object at 0x7f1da3c09270> collection_path: /home/webdev/Desktop/octopwnweb/code/projects/unicrypto/tests/htmlcov/d_1b326c20d678c8f6___init___py.html path: /home/webdev/Desktop/octopwnweb/code/projects/unicrypto/tests/htmlcov/d_1b326c20d678c8f6___init___py.html finish pytest_ignore_collect --> None [hook] pytest_ignore_collect [hook] config: <_pytest.config.Config object at 0x7f1da3c09270> collection_path: /home/webdev/Desktop/octopwnweb/code/projects/unicrypto/tests/htmlcov/d_1b326c20d678c8f6_blockfeeder_py.html path: /home/webdev/Desktop/octopwnweb/code/projects/unicrypto/tests/htmlcov/d_1b326c20d678c8f6_blockfeeder_py.html finish pytest_ignore_collect --> None [hook] pytest_ignore_collect [hook] config: <_pytest.config.Config object at 0x7f1da3c09270> collection_path: /home/webdev/Desktop/octopwnweb/code/projects/unicrypto/tests/htmlcov/d_1b326c20d678c8f6_ccm_py.html path: /home/webdev/Desktop/octopwnweb/code/projects/unicrypto/tests/htmlcov/d_1b326c20d678c8f6_ccm_py.html finish pytest_ignore_collect --> None [hook] pytest_ignore_collect [hook] config: <_pytest.config.Config object at 0x7f1da3c09270> collection_path: /home/webdev/Desktop/octopwnweb/code/projects/unicrypto/tests/htmlcov/d_1b326c20d678c8f6_gcc_bak_orig_py.html path: /home/webdev/Desktop/octopwnweb/code/projects/unicrypto/tests/htmlcov/d_1b326c20d678c8f6_gcc_bak_orig_py.html finish pytest_ignore_collect --> None [hook] pytest_ignore_collect [hook] config: <_pytest.config.Config object at 0x7f1da3c09270> collection_path: /home/webdev/Desktop/octopwnweb/code/projects/unicrypto/tests/htmlcov/d_1b326c20d678c8f6_util_py.html path: /home/webdev/Desktop/octopwnweb/code/projects/unicrypto/tests/htmlcov/d_1b326c20d678c8f6_util_py.html finish pytest_ignore_collect --> None [hook] pytest_ignore_collect [hook] config: <_pytest.config.Config object at 0x7f1da3c09270> collection_path: /home/webdev/Desktop/octopwnweb/code/projects/unicrypto/tests/htmlcov/d_251f17693116e7b2_AES_py.html path: /home/webdev/Desktop/octopwnweb/code/projects/unicrypto/tests/htmlcov/d_251f17693116e7b2_AES_py.html finish pytest_ignore_collect --> None [hook] pytest_ignore_collect [hook] config: <_pytest.config.Config object at 0x7f1da3c09270> collection_path: /home/webdev/Desktop/octopwnweb/code/projects/unicrypto/tests/htmlcov/d_251f17693116e7b2_DES_py.html path: /home/webdev/Desktop/octopwnweb/code/projects/unicrypto/tests/htmlcov/d_251f17693116e7b2_DES_py.html finish pytest_ignore_collect --> None [hook] pytest_ignore_collect [hook] config: <_pytest.config.Config object at 0x7f1da3c09270> collection_path: /home/webdev/Desktop/octopwnweb/code/projects/unicrypto/tests/htmlcov/d_251f17693116e7b2_RC4_py.html path: /home/webdev/Desktop/octopwnweb/code/projects/unicrypto/tests/htmlcov/d_251f17693116e7b2_RC4_py.html finish pytest_ignore_collect --> None [hook] pytest_ignore_collect [hook] config: <_pytest.config.Config object at 0x7f1da3c09270> collection_path: /home/webdev/Desktop/octopwnweb/code/projects/unicrypto/tests/htmlcov/d_251f17693116e7b2_TDES_py.html path: /home/webdev/Desktop/octopwnweb/code/projects/unicrypto/tests/htmlcov/d_251f17693116e7b2_TDES_py.html finish pytest_ignore_collect --> None [hook] pytest_ignore_collect [hook] config: <_pytest.config.Config object at 0x7f1da3c09270> collection_path: /home/webdev/Desktop/octopwnweb/code/projects/unicrypto/tests/htmlcov/d_251f17693116e7b2___init___py.html path: /home/webdev/Desktop/octopwnweb/code/projects/unicrypto/tests/htmlcov/d_251f17693116e7b2___init___py.html finish pytest_ignore_collect --> None [hook] pytest_ignore_collect [hook] config: <_pytest.config.Config object at 0x7f1da3c09270> collection_path: /home/webdev/Desktop/octopwnweb/code/projects/unicrypto/tests/htmlcov/d_2e5ad67125402140_AES_py.html path: /home/webdev/Desktop/octopwnweb/code/projects/unicrypto/tests/htmlcov/d_2e5ad67125402140_AES_py.html finish pytest_ignore_collect --> None [hook] pytest_ignore_collect [hook] config: <_pytest.config.Config object at 0x7f1da3c09270> collection_path: /home/webdev/Desktop/octopwnweb/code/projects/unicrypto/tests/htmlcov/d_2e5ad67125402140_DES_py.html path: /home/webdev/Desktop/octopwnweb/code/projects/unicrypto/tests/htmlcov/d_2e5ad67125402140_DES_py.html finish pytest_ignore_collect --> None [hook] pytest_ignore_collect [hook] config: <_pytest.config.Config object at 0x7f1da3c09270> collection_path: /home/webdev/Desktop/octopwnweb/code/projects/unicrypto/tests/htmlcov/d_2e5ad67125402140_RC4_py.html path: /home/webdev/Desktop/octopwnweb/code/projects/unicrypto/tests/htmlcov/d_2e5ad67125402140_RC4_py.html finish pytest_ignore_collect --> None [hook] pytest_ignore_collect [hook] config: <_pytest.config.Config object at 0x7f1da3c09270> collection_path: /home/webdev/Desktop/octopwnweb/code/projects/unicrypto/tests/htmlcov/d_2e5ad67125402140_TDES_py.html path: /home/webdev/Desktop/octopwnweb/code/projects/unicrypto/tests/htmlcov/d_2e5ad67125402140_TDES_py.html finish pytest_ignore_collect --> None [hook] pytest_ignore_collect [hook] config: <_pytest.config.Config object at 0x7f1da3c09270> collection_path: /home/webdev/Desktop/octopwnweb/code/projects/unicrypto/tests/htmlcov/d_2e5ad67125402140___init___py.html path: /home/webdev/Desktop/octopwnweb/code/projects/unicrypto/tests/htmlcov/d_2e5ad67125402140___init___py.html finish pytest_ignore_collect --> None [hook] pytest_ignore_collect [hook] config: <_pytest.config.Config object at 0x7f1da3c09270> collection_path: /home/webdev/Desktop/octopwnweb/code/projects/unicrypto/tests/htmlcov/d_6129138558f5e740_AES_py.html path: /home/webdev/Desktop/octopwnweb/code/projects/unicrypto/tests/htmlcov/d_6129138558f5e740_AES_py.html finish pytest_ignore_collect --> None [hook] pytest_ignore_collect [hook] config: <_pytest.config.Config object at 0x7f1da3c09270> collection_path: /home/webdev/Desktop/octopwnweb/code/projects/unicrypto/tests/htmlcov/d_6129138558f5e740_DES_py.html path: /home/webdev/Desktop/octopwnweb/code/projects/unicrypto/tests/htmlcov/d_6129138558f5e740_DES_py.html finish pytest_ignore_collect --> None [hook] pytest_ignore_collect [hook] config: <_pytest.config.Config object at 0x7f1da3c09270> collection_path: /home/webdev/Desktop/octopwnweb/code/projects/unicrypto/tests/htmlcov/d_6129138558f5e740_RC4_py.html path: /home/webdev/Desktop/octopwnweb/code/projects/unicrypto/tests/htmlcov/d_6129138558f5e740_RC4_py.html finish pytest_ignore_collect --> None [hook] pytest_ignore_collect [hook] config: <_pytest.config.Config object at 0x7f1da3c09270> collection_path: /home/webdev/Desktop/octopwnweb/code/projects/unicrypto/tests/htmlcov/d_6129138558f5e740_TDES_py.html path: /home/webdev/Desktop/octopwnweb/code/projects/unicrypto/tests/htmlcov/d_6129138558f5e740_TDES_py.html finish pytest_ignore_collect --> None [hook] pytest_ignore_collect [hook] config: <_pytest.config.Config object at 0x7f1da3c09270> collection_path: /home/webdev/Desktop/octopwnweb/code/projects/unicrypto/tests/htmlcov/d_6129138558f5e740___init___py.html path: /home/webdev/Desktop/octopwnweb/code/projects/unicrypto/tests/htmlcov/d_6129138558f5e740___init___py.html finish pytest_ignore_collect --> None [hook] pytest_ignore_collect [hook] config: <_pytest.config.Config object at 0x7f1da3c09270> collection_path: /home/webdev/Desktop/octopwnweb/code/projects/unicrypto/tests/htmlcov/d_7d646dc836ec9617_AES_py.html path: /home/webdev/Desktop/octopwnweb/code/projects/unicrypto/tests/htmlcov/d_7d646dc836ec9617_AES_py.html finish pytest_ignore_collect --> None [hook] pytest_ignore_collect [hook] config: <_pytest.config.Config object at 0x7f1da3c09270> collection_path: /home/webdev/Desktop/octopwnweb/code/projects/unicrypto/tests/htmlcov/d_7d646dc836ec9617_DES_py.html path: /home/webdev/Desktop/octopwnweb/code/projects/unicrypto/tests/htmlcov/d_7d646dc836ec9617_DES_py.html finish pytest_ignore_collect --> None [hook] pytest_ignore_collect [hook] config: <_pytest.config.Config object at 0x7f1da3c09270> collection_path: /home/webdev/Desktop/octopwnweb/code/projects/unicrypto/tests/htmlcov/d_7d646dc836ec9617_MD4_py.html path: /home/webdev/Desktop/octopwnweb/code/projects/unicrypto/tests/htmlcov/d_7d646dc836ec9617_MD4_py.html finish pytest_ignore_collect --> None [hook] pytest_ignore_collect [hook] config: <_pytest.config.Config object at 0x7f1da3c09270> collection_path: /home/webdev/Desktop/octopwnweb/code/projects/unicrypto/tests/htmlcov/d_7d646dc836ec9617_RC4_py.html path: /home/webdev/Desktop/octopwnweb/code/projects/unicrypto/tests/htmlcov/d_7d646dc836ec9617_RC4_py.html finish pytest_ignore_collect --> None [hook] pytest_ignore_collect [hook] config: <_pytest.config.Config object at 0x7f1da3c09270> collection_path: /home/webdev/Desktop/octopwnweb/code/projects/unicrypto/tests/htmlcov/d_7d646dc836ec9617_TDES_py.html path: /home/webdev/Desktop/octopwnweb/code/projects/unicrypto/tests/htmlcov/d_7d646dc836ec9617_TDES_py.html finish pytest_ignore_collect --> None [hook] pytest_ignore_collect [hook] config: <_pytest.config.Config object at 0x7f1da3c09270> collection_path: /home/webdev/Desktop/octopwnweb/code/projects/unicrypto/tests/htmlcov/d_7d646dc836ec9617___init___py.html path: /home/webdev/Desktop/octopwnweb/code/projects/unicrypto/tests/htmlcov/d_7d646dc836ec9617___init___py.html finish pytest_ignore_collect --> None [hook] pytest_ignore_collect [hook] config: <_pytest.config.Config object at 0x7f1da3c09270> collection_path: /home/webdev/Desktop/octopwnweb/code/projects/unicrypto/tests/htmlcov/d_7ea8e34bf0d7f4e4_DES_py.html path: /home/webdev/Desktop/octopwnweb/code/projects/unicrypto/tests/htmlcov/d_7ea8e34bf0d7f4e4_DES_py.html finish pytest_ignore_collect --> None [hook] pytest_ignore_collect [hook] config: <_pytest.config.Config object at 0x7f1da3c09270> collection_path: /home/webdev/Desktop/octopwnweb/code/projects/unicrypto/tests/htmlcov/d_7ea8e34bf0d7f4e4___init___py.html path: /home/webdev/Desktop/octopwnweb/code/projects/unicrypto/tests/htmlcov/d_7ea8e34bf0d7f4e4___init___py.html finish pytest_ignore_collect --> None [hook] pytest_ignore_collect [hook] config: <_pytest.config.Config object at 0x7f1da3c09270> collection_path: /home/webdev/Desktop/octopwnweb/code/projects/unicrypto/tests/htmlcov/d_a01d58846f10b105_AESGCM_py.html path: /home/webdev/Desktop/octopwnweb/code/projects/unicrypto/tests/htmlcov/d_a01d58846f10b105_AESGCM_py.html finish pytest_ignore_collect --> None [hook] pytest_ignore_collect [hook] config: <_pytest.config.Config object at 0x7f1da3c09270> collection_path: /home/webdev/Desktop/octopwnweb/code/projects/unicrypto/tests/htmlcov/d_a01d58846f10b105___init___py.html path: /home/webdev/Desktop/octopwnweb/code/projects/unicrypto/tests/htmlcov/d_a01d58846f10b105___init___py.html finish pytest_ignore_collect --> None [hook] pytest_ignore_collect [hook] config: <_pytest.config.Config object at 0x7f1da3c09270> collection_path: /home/webdev/Desktop/octopwnweb/code/projects/unicrypto/tests/htmlcov/d_aef2cb7bed9f28fc___init___py.html path: /home/webdev/Desktop/octopwnweb/code/projects/unicrypto/tests/htmlcov/d_aef2cb7bed9f28fc___init___py.html finish pytest_ignore_collect --> None [hook] pytest_ignore_collect [hook] config: <_pytest.config.Config object at 0x7f1da3c09270> collection_path: /home/webdev/Desktop/octopwnweb/code/projects/unicrypto/tests/htmlcov/d_aef2cb7bed9f28fc_pkcs7_py.html path: /home/webdev/Desktop/octopwnweb/code/projects/unicrypto/tests/htmlcov/d_aef2cb7bed9f28fc_pkcs7_py.html finish pytest_ignore_collect --> None [hook] pytest_ignore_collect [hook] config: <_pytest.config.Config object at 0x7f1da3c09270> collection_path: /home/webdev/Desktop/octopwnweb/code/projects/unicrypto/tests/htmlcov/d_c18e496b448ab961___init___py.html path: /home/webdev/Desktop/octopwnweb/code/projects/unicrypto/tests/htmlcov/d_c18e496b448ab961___init___py.html finish pytest_ignore_collect --> None [hook] pytest_ignore_collect [hook] config: <_pytest.config.Config object at 0x7f1da3c09270> collection_path: /home/webdev/Desktop/octopwnweb/code/projects/unicrypto/tests/htmlcov/d_c18e496b448ab961_cmac_py.html path: /home/webdev/Desktop/octopwnweb/code/projects/unicrypto/tests/htmlcov/d_c18e496b448ab961_cmac_py.html finish pytest_ignore_collect --> None [hook] pytest_ignore_collect [hook] config: <_pytest.config.Config object at 0x7f1da3c09270> collection_path: /home/webdev/Desktop/octopwnweb/code/projects/unicrypto/tests/htmlcov/d_c18e496b448ab961_kdf_py.html path: /home/webdev/Desktop/octopwnweb/code/projects/unicrypto/tests/htmlcov/d_c18e496b448ab961_kdf_py.html finish pytest_ignore_collect --> None [hook] pytest_ignore_collect [hook] config: <_pytest.config.Config object at 0x7f1da3c09270> collection_path: /home/webdev/Desktop/octopwnweb/code/projects/unicrypto/tests/htmlcov/d_d66001d28a41f951___init___py.html path: /home/webdev/Desktop/octopwnweb/code/projects/unicrypto/tests/htmlcov/d_d66001d28a41f951___init___py.html finish pytest_ignore_collect --> None [hook] pytest_ignore_collect [hook] config: <_pytest.config.Config object at 0x7f1da3c09270> collection_path: /home/webdev/Desktop/octopwnweb/code/projects/unicrypto/tests/htmlcov/d_d66001d28a41f951__version_py.html path: /home/webdev/Desktop/octopwnweb/code/projects/unicrypto/tests/htmlcov/d_d66001d28a41f951__version_py.html finish pytest_ignore_collect --> None [hook] pytest_ignore_collect [hook] config: <_pytest.config.Config object at 0x7f1da3c09270> collection_path: /home/webdev/Desktop/octopwnweb/code/projects/unicrypto/tests/htmlcov/d_d66001d28a41f951_cmac_py.html path: /home/webdev/Desktop/octopwnweb/code/projects/unicrypto/tests/htmlcov/d_d66001d28a41f951_cmac_py.html finish pytest_ignore_collect --> None [hook] pytest_ignore_collect [hook] config: <_pytest.config.Config object at 0x7f1da3c09270> collection_path: /home/webdev/Desktop/octopwnweb/code/projects/unicrypto/tests/htmlcov/d_d66001d28a41f951_hashlib_py.html path: /home/webdev/Desktop/octopwnweb/code/projects/unicrypto/tests/htmlcov/d_d66001d28a41f951_hashlib_py.html finish pytest_ignore_collect --> None [hook] pytest_ignore_collect [hook] config: <_pytest.config.Config object at 0x7f1da3c09270> collection_path: /home/webdev/Desktop/octopwnweb/code/projects/unicrypto/tests/htmlcov/d_d66001d28a41f951_hmac_py.html path: /home/webdev/Desktop/octopwnweb/code/projects/unicrypto/tests/htmlcov/d_d66001d28a41f951_hmac_py.html finish pytest_ignore_collect --> None [hook] pytest_ignore_collect [hook] config: <_pytest.config.Config object at 0x7f1da3c09270> collection_path: /home/webdev/Desktop/octopwnweb/code/projects/unicrypto/tests/htmlcov/d_d66001d28a41f951_kdf_py.html path: /home/webdev/Desktop/octopwnweb/code/projects/unicrypto/tests/htmlcov/d_d66001d28a41f951_kdf_py.html finish pytest_ignore_collect --> None [hook] pytest_ignore_collect [hook] config: <_pytest.config.Config object at 0x7f1da3c09270> collection_path: /home/webdev/Desktop/octopwnweb/code/projects/unicrypto/tests/htmlcov/d_d66001d28a41f951_pbkdf2_py.html path: /home/webdev/Desktop/octopwnweb/code/projects/unicrypto/tests/htmlcov/d_d66001d28a41f951_pbkdf2_py.html finish pytest_ignore_collect --> None [hook] pytest_ignore_collect [hook] config: <_pytest.config.Config object at 0x7f1da3c09270> collection_path: /home/webdev/Desktop/octopwnweb/code/projects/unicrypto/tests/htmlcov/d_d66001d28a41f951_symmetric_py.html path: /home/webdev/Desktop/octopwnweb/code/projects/unicrypto/tests/htmlcov/d_d66001d28a41f951_symmetric_py.html finish pytest_ignore_collect --> None [hook] pytest_ignore_collect [hook] config: <_pytest.config.Config object at 0x7f1da3c09270> collection_path: /home/webdev/Desktop/octopwnweb/code/projects/unicrypto/tests/htmlcov/favicon_32.png path: /home/webdev/Desktop/octopwnweb/code/projects/unicrypto/tests/htmlcov/favicon_32.png finish pytest_ignore_collect --> None [hook] pytest_ignore_collect [hook] config: <_pytest.config.Config object at 0x7f1da3c09270> collection_path: /home/webdev/Desktop/octopwnweb/code/projects/unicrypto/tests/htmlcov/index.html path: /home/webdev/Desktop/octopwnweb/code/projects/unicrypto/tests/htmlcov/index.html finish pytest_ignore_collect --> None [hook] pytest_ignore_collect [hook] config: <_pytest.config.Config object at 0x7f1da3c09270> collection_path: /home/webdev/Desktop/octopwnweb/code/projects/unicrypto/tests/htmlcov/keybd_closed.png path: /home/webdev/Desktop/octopwnweb/code/projects/unicrypto/tests/htmlcov/keybd_closed.png finish pytest_ignore_collect --> None [hook] pytest_ignore_collect [hook] config: <_pytest.config.Config object at 0x7f1da3c09270> collection_path: /home/webdev/Desktop/octopwnweb/code/projects/unicrypto/tests/htmlcov/keybd_open.png path: /home/webdev/Desktop/octopwnweb/code/projects/unicrypto/tests/htmlcov/keybd_open.png finish pytest_ignore_collect --> None [hook] pytest_ignore_collect [hook] config: <_pytest.config.Config object at 0x7f1da3c09270> collection_path: /home/webdev/Desktop/octopwnweb/code/projects/unicrypto/tests/htmlcov/status.json path: /home/webdev/Desktop/octopwnweb/code/projects/unicrypto/tests/htmlcov/status.json finish pytest_ignore_collect --> None [hook] pytest_ignore_collect [hook] config: <_pytest.config.Config object at 0x7f1da3c09270> collection_path: /home/webdev/Desktop/octopwnweb/code/projects/unicrypto/tests/htmlcov/style.css path: /home/webdev/Desktop/octopwnweb/code/projects/unicrypto/tests/htmlcov/style.css finish pytest_ignore_collect --> None [hook] pytest_ignore_collect [hook] config: <_pytest.config.Config object at 0x7f1da3c09270> collection_path: /home/webdev/Desktop/octopwnweb/code/projects/unicrypto/tests/htmlcov/test_aes_py.html path: /home/webdev/Desktop/octopwnweb/code/projects/unicrypto/tests/htmlcov/test_aes_py.html finish pytest_ignore_collect --> None [hook] pytest_ignore_collect [hook] config: <_pytest.config.Config object at 0x7f1da3c09270> collection_path: /home/webdev/Desktop/octopwnweb/code/projects/unicrypto/tests/htmlcov/test_des_py.html path: /home/webdev/Desktop/octopwnweb/code/projects/unicrypto/tests/htmlcov/test_des_py.html finish pytest_ignore_collect --> None [hook] pytest_ignore_collect [hook] config: <_pytest.config.Config object at 0x7f1da3c09270> collection_path: /home/webdev/Desktop/octopwnweb/code/projects/unicrypto/tests/htmlcov/test_import_py.html path: /home/webdev/Desktop/octopwnweb/code/projects/unicrypto/tests/htmlcov/test_import_py.html finish pytest_ignore_collect --> None [hook] pytest_ignore_collect [hook] config: <_pytest.config.Config object at 0x7f1da3c09270> collection_path: /home/webdev/Desktop/octopwnweb/code/projects/unicrypto/tests/htmlcov/test_pbkdf2_py.html path: /home/webdev/Desktop/octopwnweb/code/projects/unicrypto/tests/htmlcov/test_pbkdf2_py.html finish pytest_ignore_collect --> None [hook] pytest_ignore_collect [hook] config: <_pytest.config.Config object at 0x7f1da3c09270> collection_path: /home/webdev/Desktop/octopwnweb/code/projects/unicrypto/tests/htmlcov/test_rc4_py.html path: /home/webdev/Desktop/octopwnweb/code/projects/unicrypto/tests/htmlcov/test_rc4_py.html finish pytest_ignore_collect --> None [hook] pytest_ignore_collect [hook] config: <_pytest.config.Config object at 0x7f1da3c09270> collection_path: /home/webdev/Desktop/octopwnweb/code/projects/unicrypto/tests/htmlcov/test_tdes_py.html path: /home/webdev/Desktop/octopwnweb/code/projects/unicrypto/tests/htmlcov/test_tdes_py.html finish pytest_ignore_collect --> None [hook] pytest_ignore_collect [hook] config: <_pytest.config.Config object at 0x7f1da3c09270> collection_path: /home/webdev/Desktop/octopwnweb/code/projects/unicrypto/tests/testenv path: /home/webdev/Desktop/octopwnweb/code/projects/unicrypto/tests/testenv finish pytest_ignore_collect --> True [hook] finish pytest_make_collect_report --> [hook] genitems [collection] pytest_collectstart [hook] collector: finish pytest_collectstart --> [] [hook] pytest_make_collect_report [hook] collector: find_module called for: tests [assertion] find_module called for: tests.test_aes [assertion] matched test file '/home/webdev/Desktop/octopwnweb/code/projects/unicrypto/tests/test_aes.py' [assertion] found cached rewritten pyc for /home/webdev/Desktop/octopwnweb/code/projects/unicrypto/tests/test_aes.py [assertion] early skip of rewriting module: unicrypto [assertion] early skip of rewriting module: mbedtls [assertion] early skip of rewriting module: mbedtls [assertion] early skip of rewriting module: cryptography [assertion] early skip of rewriting module: cryptography [assertion] early skip of rewriting module: Cryptodome [assertion] early skip of rewriting module: Cryptodome [assertion] early skip of rewriting module: Crypto [assertion] early skip of rewriting module: Crypto.Cipher [assertion] early skip of rewriting module: Crypto.Cipher._mode_ecb [assertion] early skip of rewriting module: Crypto.Util [assertion] early skip of rewriting module: Crypto.Util._raw_api [assertion] early skip of rewriting module: Crypto.Util.py3compat [assertion] early skip of rewriting module: Crypto.Util._file_system [assertion] early skip of rewriting module: cffi [assertion] early skip of rewriting module: cffi.api [assertion] early skip of rewriting module: cffi.lock [assertion] early skip of rewriting module: cffi.error [assertion] early skip of rewriting module: cffi.model [assertion] early skip of rewriting module: _cffi_backend [assertion] early skip of rewriting module: cffi.cparser [assertion] early skip of rewriting module: cffi.commontypes [assertion] early skip of rewriting module: cffi._pycparser [assertion] early skip of rewriting module: pycparser [assertion] early skip of rewriting module: pycparser.c_parser [assertion] early skip of rewriting module: pycparser.ply [assertion] early skip of rewriting module: pycparser.ply.yacc [assertion] early skip of rewriting module: pycparser.c_ast [assertion] early skip of rewriting module: pycparser.c_lexer [assertion] early skip of rewriting module: pycparser.ply.lex [assertion] early skip of rewriting module: pycparser.plyparser [assertion] early skip of rewriting module: pycparser.ast_transforms [assertion] early skip of rewriting module: pycparser.lextab [assertion] early skip of rewriting module: pycparser.yacctab [assertion] early skip of rewriting module: Crypto.Cipher._mode_cbc [assertion] early skip of rewriting module: Crypto.Random [assertion] early skip of rewriting module: Crypto.Cipher._mode_cfb [assertion] early skip of rewriting module: Crypto.Cipher._mode_ofb [assertion] early skip of rewriting module: Crypto.Cipher._mode_ctr [assertion] early skip of rewriting module: Crypto.Util.number [assertion] early skip of rewriting module: Crypto.Cipher._mode_openpgp [assertion] early skip of rewriting module: Crypto.Cipher._mode_ccm [assertion] early skip of rewriting module: Crypto.Util.strxor [assertion] early skip of rewriting module: Crypto.Hash [assertion] early skip of rewriting module: Crypto.Hash.BLAKE2s [assertion] early skip of rewriting module: Crypto.Cipher._mode_eax [assertion] early skip of rewriting module: Crypto.Hash.CMAC [assertion] early skip of rewriting module: Crypto.Cipher._mode_siv [assertion] early skip of rewriting module: Crypto.Protocol [assertion] early skip of rewriting module: Crypto.Protocol.KDF [assertion] early skip of rewriting module: Crypto.Hash.SHA1 [assertion] early skip of rewriting module: Crypto.Hash.SHA256 [assertion] early skip of rewriting module: Crypto.Hash.HMAC [assertion] early skip of rewriting module: Crypto.Hash.MD5 [assertion] early skip of rewriting module: Crypto.Cipher._mode_gcm [assertion] early skip of rewriting module: Crypto.Util._cpu_features [assertion] early skip of rewriting module: Crypto.Cipher._mode_ocb [assertion] early skip of rewriting module: Crypto.Cipher.Salsa20 [assertion] early skip of rewriting module: Crypto.Cipher.Salsa20 [assertion] early skip of rewriting module: Crypto.Random.OSRNG [assertion] early skip of rewriting module: Crypto.Random.OSRNG [assertion] early skip of rewriting module: unicrypto.symmetric [assertion] early skip of rewriting module: unicrypto.backends [assertion] early skip of rewriting module: unicrypto.backends.pycryptodomex [assertion] early skip of rewriting module: unicrypto.backends.pycryptodomex.AES [assertion] early skip of rewriting module: Cryptodome [assertion] early skip of rewriting module: Cryptodome.Cipher [assertion] early skip of rewriting module: Cryptodome.Cipher._mode_ecb [assertion] early skip of rewriting module: Cryptodome.Util [assertion] early skip of rewriting module: Cryptodome.Util._raw_api [assertion] early skip of rewriting module: Cryptodome.Util.py3compat [assertion] early skip of rewriting module: Cryptodome.Util._file_system [assertion] early skip of rewriting module: Cryptodome.Cipher._mode_cbc [assertion] early skip of rewriting module: Cryptodome.Random [assertion] early skip of rewriting module: Cryptodome.Cipher._mode_cfb [assertion] early skip of rewriting module: Cryptodome.Cipher._mode_ofb [assertion] early skip of rewriting module: Cryptodome.Cipher._mode_ctr [assertion] early skip of rewriting module: Cryptodome.Util.number [assertion] early skip of rewriting module: Cryptodome.Cipher._mode_openpgp [assertion] early skip of rewriting module: Cryptodome.Cipher._mode_ccm [assertion] early skip of rewriting module: Cryptodome.Util.strxor [assertion] early skip of rewriting module: Cryptodome.Hash [assertion] early skip of rewriting module: Cryptodome.Hash.BLAKE2s [assertion] early skip of rewriting module: Cryptodome.Cipher._mode_eax [assertion] early skip of rewriting module: Cryptodome.Hash.CMAC [assertion] early skip of rewriting module: Cryptodome.Cipher._mode_siv [assertion] early skip of rewriting module: Cryptodome.Protocol [assertion] early skip of rewriting module: Cryptodome.Protocol.KDF [assertion] early skip of rewriting module: Cryptodome.Hash.SHA1 [assertion] early skip of rewriting module: Cryptodome.Hash.SHA256 [assertion] early skip of rewriting module: Cryptodome.Hash.HMAC [assertion] early skip of rewriting module: Cryptodome.Hash.MD5 [assertion] early skip of rewriting module: Cryptodome.Cipher._mode_gcm [assertion] early skip of rewriting module: Cryptodome.Util._cpu_features [assertion] early skip of rewriting module: Cryptodome.Cipher._mode_ocb [assertion] early skip of rewriting module: Cryptodome.Cipher.AES [assertion] early skip of rewriting module: Cryptodome.Util.Counter [assertion] early skip of rewriting module: unicrypto.backends.pycryptodomex.DES [assertion] early skip of rewriting module: Cryptodome.Cipher.DES [assertion] early skip of rewriting module: unicrypto.backends.pycryptodomex.RC4 [assertion] early skip of rewriting module: Cryptodome.Cipher.ARC4 [assertion] early skip of rewriting module: unicrypto.backends.pycryptodomex.TDES [assertion] early skip of rewriting module: Cryptodome.Cipher.DES3 [assertion] early skip of rewriting module: unicrypto.backends.pycryptodome [assertion] early skip of rewriting module: unicrypto.backends.pycryptodome.AES [assertion] early skip of rewriting module: Crypto.Cipher.AES [assertion] early skip of rewriting module: Crypto.Util.Counter [assertion] early skip of rewriting module: unicrypto.backends.pycryptodome.DES [assertion] early skip of rewriting module: Crypto.Cipher.DES [assertion] early skip of rewriting module: unicrypto.backends.pycryptodome.RC4 [assertion] early skip of rewriting module: Crypto.Cipher.ARC4 [assertion] early skip of rewriting module: unicrypto.backends.pycryptodome.TDES [assertion] early skip of rewriting module: Crypto.Cipher.DES3 [assertion] early skip of rewriting module: unicrypto.backends.cryptography [assertion] early skip of rewriting module: unicrypto.backends.cryptography.AES [assertion] early skip of rewriting module: cryptography [assertion] early skip of rewriting module: cryptography.__about__ [assertion] early skip of rewriting module: cryptography.utils [assertion] early skip of rewriting module: cryptography.hazmat [assertion] early skip of rewriting module: cryptography.hazmat.primitives [assertion] early skip of rewriting module: cryptography.hazmat.primitives.ciphers [assertion] early skip of rewriting module: cryptography.hazmat.primitives._cipheralgorithm [assertion] early skip of rewriting module: cryptography.hazmat.primitives.ciphers.base [assertion] early skip of rewriting module: cryptography.exceptions [assertion] early skip of rewriting module: cryptography.hazmat.primitives.ciphers.modes [assertion] early skip of rewriting module: cryptography.hazmat.primitives.ciphers.algorithms [assertion] early skip of rewriting module: cryptography.hazmat.primitives.padding [assertion] early skip of rewriting module: cryptography.hazmat.bindings [assertion] early skip of rewriting module: cryptography.hazmat.bindings._rust [assertion] early skip of rewriting module: cryptography.hazmat.backends [assertion] early skip of rewriting module: unicrypto.backends.cryptography.DES [assertion] early skip of rewriting module: unicrypto.backends.cryptography.RC4 [assertion] early skip of rewriting module: unicrypto.backends.cryptography.TDES [assertion] early skip of rewriting module: unicrypto.backends.pure [assertion] early skip of rewriting module: unicrypto.backends.pure.AES [assertion] early skip of rewriting module: unicrypto.backends.pure.external [assertion] early skip of rewriting module: unicrypto.backends.pure.external.AES [assertion] early skip of rewriting module: unicrypto.backends.pure.external.AES.AES [assertion] early skip of rewriting module: unicrypto.backends.pure.external.AES.blockfeeder [assertion] early skip of rewriting module: unicrypto.backends.pure.external.AES.util [assertion] early skip of rewriting module: unicrypto.hashlib [assertion] early skip of rewriting module: unicrypto.backends.pure.DES [assertion] early skip of rewriting module: unicrypto.backends.pure.external.DES [assertion] early skip of rewriting module: unicrypto.backends.pure.external.DES.DES [assertion] early skip of rewriting module: unicrypto.backends.pure.RC4 [assertion] early skip of rewriting module: unicrypto.backends.pure.external.RC4 [assertion] early skip of rewriting module: unicrypto.backends.pure.external.RC4.RC4 [assertion] early skip of rewriting module: unicrypto.backends.pure.TDES [assertion] early skip of rewriting module: unicrypto.backends.mbedtls [assertion] early skip of rewriting module: unicrypto.backends.mbedtls.AES [assertion] early skip of rewriting module: mbedtls [assertion] early skip of rewriting module: mbedtls.cipher [assertion] early skip of rewriting module: mbedtls.cipher.AES [assertion] early skip of rewriting module: mbedtls.exceptions [assertion] early skip of rewriting module: mbedtls.cipher._cipher [assertion] early skip of rewriting module: mbedtls.cipher.ARC4 [assertion] early skip of rewriting module: mbedtls.cipher.ARIA [assertion] early skip of rewriting module: mbedtls.cipher.CHACHA20 [assertion] early skip of rewriting module: mbedtls.cipher.DES [assertion] early skip of rewriting module: mbedtls.cipher.DES3 [assertion] early skip of rewriting module: mbedtls.cipher.Blowfish [assertion] early skip of rewriting module: mbedtls.cipher.Camellia [assertion] early skip of rewriting module: mbedtls.cipher.DES3dbl [assertion] early skip of rewriting module: mbedtls.hashlib [assertion] early skip of rewriting module: mbedtls._md [assertion] early skip of rewriting module: backports_abc [assertion] early skip of rewriting module: mbedtls.version [assertion] early skip of rewriting module: mbedtls.hkdf [assertion] early skip of rewriting module: mbedtls.hmac [assertion] early skip of rewriting module: mbedtls.pk [assertion] early skip of rewriting module: mbedtls.mpi [assertion] early skip of rewriting module: mbedtls._random [assertion] early skip of rewriting module: mbedtls._platform [assertion] early skip of rewriting module: mbedtls.secrets [assertion] early skip of rewriting module: mbedtls.tls [assertion] early skip of rewriting module: mbedtls._tls [assertion] early skip of rewriting module: mbedtls._ringbuf [assertion] early skip of rewriting module: mbedtls.x509 [assertion] early skip of rewriting module: backports_abc [assertion] early skip of rewriting module: certifi [assertion] early skip of rewriting module: certifi.core [assertion] early skip of rewriting module: importlib.resources [assertion] early skip of rewriting module: importlib._common [assertion] early skip of rewriting module: importlib._adapters [assertion] early skip of rewriting module: mbedtls._tlsi [assertion] early skip of rewriting module: unicrypto.backends.mbedtls.DES [assertion] early skip of rewriting module: unicrypto.backends.mbedtls.RC4 [assertion] early skip of rewriting module: unicrypto.backends.mbedtls.TDES [assertion] pytest_pycollect_makeitem [hook] collector: name: @py_builtins obj: finish pytest_pycollect_makeitem --> None [hook] pytest_pycollect_makeitem [hook] collector: name: @pytest_ar obj: finish pytest_pycollect_makeitem --> None [hook] pytest_pycollect_makeitem [hook] collector: name: pytest obj: finish pytest_pycollect_makeitem --> None [hook] pytest_pycollect_makeitem [hook] collector: name: get_cipher_by_name obj: finish pytest_pycollect_makeitem --> None [hook] pytest_pycollect_makeitem [hook] collector: name: symmetric obj: finish pytest_pycollect_makeitem --> None [hook] pytest_pycollect_makeitem [hook] collector: name: aes_128_ecb obj: [('6bc1bee22e409f96e93d7e117393172a', '2b7e151628aed2a6abf7158809cf4f3c', '3ad77bb40d7a3660a89ecaf32466ef97'), ('ae2d8a571e03ac9c9eb76fac45af8e51', '2b7e151628aed2a6abf7158809cf4f3c', 'f5d3d58503b9699de785895a96fdbaaf'), ('30c81c46a35ce411e5fbc1191a0a52ef', '2b7e151628aed2a6abf7158809cf4f3c', '43b1cd7f598ece23881b00e3ed030688'), ('f69f2445df4f9b17ad2b417be66c3710', '2b7e151628aed2a6abf7158809cf4f3c', '7b0c785e27e8ad3f8223207104725dd4')] finish pytest_pycollect_makeitem --> None [hook] pytest_pycollect_makeitem [hook] collector: name: aes_192_ecb obj: [('6bc1bee22e409f96e93d7e117393172a', '8e73b0f7da0e6452c810f32b809079e562f8ead2522c6b7b', 'bd334f1d6e45f25ff712a214571fa5cc'), ('ae2d8a571e03ac9c9eb76fac45af8e51', '8e73b0f7da0e6452c810f32b809079e562f8ead2522c6b7b', '974104846d0ad3ad7734ecb3ecee4eef'), ('30c81c46a35ce411e5fbc1191a0a52ef', '8e73b0f7da0e6452c810f32b809079e562f8ead2522c6b7b', 'ef7afd2270e2e60adce0ba2face6444e'), ('f69f2445df4f9b17ad2b417be66c3710', '8e73b0f7da0e6452c810f32b809079e562f8ead2522c6b7b', '9a4b41ba738d6c72fb16691603c18e0e')] finish pytest_pycollect_makeitem --> None [hook] pytest_pycollect_makeitem [hook] collector: name: aes_256_ecb obj: [('6bc1bee22e409f96e93d7e117393172a', '603deb1015ca71be2b73aef0857d77811f352c073b6108d72d9810a30914dff4', 'f3eed1bdb5d2a03c064b5a7e3db181f8'), ('ae2d8a571e03ac9c9eb76fac45af8e51', '603deb1015ca71be2b73aef0857d77811f352c073b6108d72d9810a30914dff4', '591ccb10d410ed26dc5ba74a31362870'), ('30c81c46a35ce411e5fbc1191a0a52ef', '603deb1015ca71be2b73aef0857d77811f352c073b6108d72d9810a30914dff4', 'b6ed21b99ca6f4f9f153e7b1beafed1d'), ('f69f2445df4f9b17ad2b417be66c3710', '603deb1015ca71be2b73aef0857d77811f352c073b6108d72d9810a30914dff4', '23304b7a39f9f3ff067d8d8f9e24ecc7')] finish pytest_pycollect_makeitem --> None [hook] pytest_pycollect_makeitem [hook] collector: name: aes_ecb_long obj: [('006bc1bee22e409f96e93d7e117393172aae2d8a571e03ac9c9eb76fac45af8e5130c81c46a35ce411e5fbc1191a0a52eff69f2445df4f9b17ad2b417be66c371000006bc1bee22e409f96e93d7e117393172aae2d8a571e03ac9c9eb76fac45af8e5130c81c46a35ce411e5fbc1191a0a52eff69f2445df4f9b17ad2b417be66c371000006bc1bee22e409f96e93d7e117393172aae2d8a571e03ac9c9eb76fac45af8e5130c81c46a35ce411e5fbc1191a0a52eff69f2445df4f9b17ad2b417be66c371000006bc1bee22e409f96e93d7e117393172aae2d8a571e03ac9c9eb76fac45af8e5130c81c46a35ce411e5fbc1191a0a52eff69f2445df4f9b17ad2b417be66c371000006bc1bee22e409f96e93d7e117393172aae2d8a571e03ac9c9eb76fac45af8e5130c81c46a35ce411e5fbc1191a0a52eff69f2445df4f9b17ad2b417be66c371000006bc1bee22e409f96e93d7e117393172aae2d8a571e03ac9c9eb76fac45af8e5130c81c46a35ce411e5fbc1191a0a52eff69f2445df4f9b17ad2b417be66c371000006bc1bee22e409f96e93d7e117393172aae2d8a571e03ac9c9eb76fac45af8e5130c81c46a35ce411e5fbc1191a0a52eff69f2445df4f9b17ad2b417be66c371000006bc1bee22e409f96e93d7e117393172aae2d8a571e03ac9c9eb76fac45af8e5130c81c46a35ce411e5fbc1191a0a52eff69f2445df4f9b17ad2b417be66c371000', '2b7e151628aed2a6abf7158809cf4f3c', '84C6CBDC2B5A39985774B23BAB066A6AF8CB66C08E4F058E5D3E7C351EA845CEC7B209210EE7EFD38269628687F21CB9BCEA349DC0418ADBA2BF2364DF4DB1A11AD84CF6A422CE95C37B2CF81196245CD857D0B954B83985C1888230F3C301847AAF714253EF768C17E89E4F5513DBD5BEE1266A2B2D7063CE3D0BA8716252C5BCBB9922CD46F374B52FDFF1FEBF155FF4AFEE18788999BC74234A3FFBA7B2858BB2552F172E56EC47456878440ABB5ADAE49941C1E43616AC5D6E31A011611B829F6A77BE1F50754F81F35D24ED89FDE804B17363F9A81C3F12AE067FDD41A2984912CAE1926C5FB3AC18E541FA4AD1E171888E61428F2A8F2E981AE16D0D4E41D33E5E675F446DAE0F454FC4CA056F41F3CC4744A9E948428B2280F96663B7230C09692503C95B3E34F8DE8DF23157F45BDF689B258D994D9E6CE5D4DD6BDB96763CCC41DBBE57A4778D5A9E90226D614C335E44CA8AB41EFEA898BC170C65412F77194A43A1305EF23AC70B059E6E047796EF518D7696BC3DAD5E2634F92DD1C90D206A2B6D3A7CE88668BEAD64614E9000ACFBA79EB3601606214E21E08F14CE77E36BB66FE4A0FCD2A21BCAA2391A9C2016AC3BC7CDF1438EB6DD26696644583E2B0A0C68629D736F6723DF66859CF80B4E5B5C5BF03F334D65C48DB3B2660E2CE33B510FD60C912B85D16AEE7CDBFDF6285B0A77BAE07D987F9CE172A548E6BF0A30CF099AA82BE0A25E0E8919')] finish pytest_pycollect_makeitem --> None [hook] pytest_pycollect_makeitem [hook] collector: name: aes_cbc_128 obj: [('6bc1bee22e409f96e93d7e117393172a', '2b7e151628aed2a6abf7158809cf4f3c', '7649abac8119b246cee98e9b12e9197d', '000102030405060708090a0b0c0d0e0f'), ('ae2d8a571e03ac9c9eb76fac45af8e51', '2b7e151628aed2a6abf7158809cf4f3c', '5086cb9b507219ee95db113a917678b2', '000102030405060708090a0b0c0d0e0f'), ('30c81c46a35ce411e5fbc1191a0a52ef', '2b7e151628aed2a6abf7158809cf4f3c', '73bed6b8e3c1743b7116e69e22229516', '000102030405060708090a0b0c0d0e0f'), ('f69f2445df4f9b17ad2b417be66c3710', '2b7e151628aed2a6abf7158809cf4f3c', '3ff1caa1681fac09120eca307586e1a7', '000102030405060708090a0b0c0d0e0f')] finish pytest_pycollect_makeitem --> None [hook] pytest_pycollect_makeitem [hook] collector: name: aes_cbc_192 obj: [('6bc1bee22e409f96e93d7e117393172a', '8e73b0f7da0e6452c810f32b809079e562f8ead2522c6b7b', '4f021db243bc633d7178183a9fa071e8', '000102030405060708090a0b0c0d0e0f'), ('ae2d8a571e03ac9c9eb76fac45af8e51', '8e73b0f7da0e6452c810f32b809079e562f8ead2522c6b7b', 'b4d9ada9ad7dedf4e5e738763f69145a', '000102030405060708090a0b0c0d0e0f'), ('30c81c46a35ce411e5fbc1191a0a52ef', '8e73b0f7da0e6452c810f32b809079e562f8ead2522c6b7b', '571b242012fb7ae07fa9baac3df102e0', '000102030405060708090a0b0c0d0e0f'), ('f69f2445df4f9b17ad2b417be66c3710', '8e73b0f7da0e6452c810f32b809079e562f8ead2522c6b7b', '08b0e27988598881d920a9e64f5615cd', '000102030405060708090a0b0c0d0e0f')] finish pytest_pycollect_makeitem --> None [hook] pytest_pycollect_makeitem [hook] collector: name: aes_cbc_256 obj: [('6bc1bee22e409f96e93d7e117393172a', '603deb1015ca71be2b73aef0857d77811f352c073b6108d72d9810a30914dff4', 'f58c4c04d6e5f1ba779eabfb5f7bfbd6', '000102030405060708090a0b0c0d0e0f'), ('ae2d8a571e03ac9c9eb76fac45af8e51', '603deb1015ca71be2b73aef0857d77811f352c073b6108d72d9810a30914dff4', '9cfc4e967edb808d679f777bc6702c7d', '000102030405060708090a0b0c0d0e0f'), ('30c81c46a35ce411e5fbc1191a0a52ef', '603deb1015ca71be2b73aef0857d77811f352c073b6108d72d9810a30914dff4', '39f23369a9d9bacfa530e26304231461', '000102030405060708090a0b0c0d0e0f'), ('f69f2445df4f9b17ad2b417be66c3710', '603deb1015ca71be2b73aef0857d77811f352c073b6108d72d9810a30914dff4', 'b2eb05e2c39be9fcda6c19078c6a9d1b', '000102030405060708090a0b0c0d0e0f')] finish pytest_pycollect_makeitem --> None [hook] pytest_pycollect_makeitem [hook] collector: name: aes_cbc_long obj: [('006bc1bee22e409f96e93d7e117393172aae2d8a571e03ac9c9eb76fac45af8e5130c81c46a35ce411e5fbc1191a0a52eff69f2445df4f9b17ad2b417be66c371000006bc1bee22e409f96e93d7e117393172aae2d8a571e03ac9c9eb76fac45af8e5130c81c46a35ce411e5fbc1191a0a52eff69f2445df4f9b17ad2b417be66c371000006bc1bee22e409f96e93d7e117393172aae2d8a571e03ac9c9eb76fac45af8e5130c81c46a35ce411e5fbc1191a0a52eff69f2445df4f9b17ad2b417be66c371000006bc1bee22e409f96e93d7e117393172aae2d8a571e03ac9c9eb76fac45af8e5130c81c46a35ce411e5fbc1191a0a52eff69f2445df4f9b17ad2b417be66c371000006bc1bee22e409f96e93d7e117393172aae2d8a571e03ac9c9eb76fac45af8e5130c81c46a35ce411e5fbc1191a0a52eff69f2445df4f9b17ad2b417be66c371000006bc1bee22e409f96e93d7e117393172aae2d8a571e03ac9c9eb76fac45af8e5130c81c46a35ce411e5fbc1191a0a52eff69f2445df4f9b17ad2b417be66c371000006bc1bee22e409f96e93d7e117393172aae2d8a571e03ac9c9eb76fac45af8e5130c81c46a35ce411e5fbc1191a0a52eff69f2445df4f9b17ad2b417be66c371000006bc1bee22e409f96e93d7e117393172aae2d8a571e03ac9c9eb76fac45af8e5130c81c46a35ce411e5fbc1191a0a52eff69f2445df4f9b17ad2b417be66c371000', '2b7e151628aed2a6abf7158809cf4f3c', '6544CCA076C4D67C1A69DD7E504C6586FBD22912505E187D8628E19FA067D6C339D078E3032B8596DA74BB0E23434F83E153D5ACD5DEF7D264F58EC685317BF50C93430791718D6E09CCC4804FFE4EEB5C6AD8E9B5DFD456EDE81081627A97FC2FAE9F1955377D7774E68EAB541B20CE3C915185BCA208EE08428C400043F2DC90B0390756762C9271946FCE214B9576F74399E466DAC48C6DD10B420F302941DCC27D55CF1FB59D71954950CAD893FFFA70970D128C77BFA34F3C84B0B64A01194A086ACDD9847D6B91B7F870D0E7591CA07F0B407005F1473C37A648F6E18044336F30418BA43FD7AA5B5BAE01A0E33B1EDA4487730F043E202DE44CB901BD3AED13D790D05F325C414831EB601BD918678C1B8E116877CE1167F87204B49619D323713F95C04CA9621FDCF44BD21C5E36A299C486C8FC0D3043EDFF424B9A7AA5500DC3BD7BF6FAB256E6B45B458058DC933F1FF8C5E841BFC7F405761E14B12B48C1C108F33BF8D65BB8DBB9ED7E92398E779333730F4C68922AA76409E842E76B649B981B8269186220ACFF9DFA198D62CBF4CFA0FE05C1427CE63A345A61FE460D14EF25D7A89E2E228B415757B4E4110B6AFA7D85D48C3BCF184FDD7366F06D9E3D29896B0D3C0D83FCFA881E6EC5F29B0294628EDFF284E58B7BE19D37A6B28D70DC0F165A4B60CE5536D76D1A71849C36B0837E4E5082A05208CEEB320C57F0F5B86DC3CAAC8A32DEA9552D', 'f0f1f2f3f4f5f6f7f8f9fafbfcfdfeff')] finish pytest_pycollect_makeitem --> None [hook] pytest_pycollect_makeitem [hook] collector: name: aes_cfb_feedbacksize_1 obj: [('6bc1bee22e409f96e93d7e117393172aae2d', '2b7e151628aed2a6abf7158809cf4f3c', '3b79424c9c0dd436bace9e0ed4586a4f32b9', '000102030405060708090a0b0c0d0e0f'), ('6bc1bee22e409f96e93d7e117393172aae2d', '8e73b0f7da0e6452c810f32b809079e562f8ead2522c6b7b', 'cda2521ef0a905ca44cd057cbf0d47a0678a', '000102030405060708090a0b0c0d0e0f'), ('6bc1bee22e409f96e93d7e117393172aae2d', '603deb1015ca71be2b73aef0857d77811f352c073b6108d72d9810a30914dff4', 'dc1f1a8520a64db55fcc8ac554844e889700', '000102030405060708090a0b0c0d0e0f')] finish pytest_pycollect_makeitem --> None [hook] pytest_pycollect_makeitem [hook] collector: name: aes_cfb_128_feedbacksize_16 obj: [('6bc1bee22e409f96e93d7e117393172a', '2b7e151628aed2a6abf7158809cf4f3c', '3b3fd92eb72dad20333449f8e83cfb4a', '000102030405060708090a0b0c0d0e0f'), ('ae2d8a571e03ac9c9eb76fac45af8e51', '2b7e151628aed2a6abf7158809cf4f3c', 'c8a64537a0b3a93fcde3cdad9f1ce58b', '000102030405060708090a0b0c0d0e0f'), ('30c81c46a35ce411e5fbc1191a0a52ef', '2b7e151628aed2a6abf7158809cf4f3c', '26751f67a3cbb140b1808cf187a4f4df', '000102030405060708090a0b0c0d0e0f'), ('f69f2445df4f9b17ad2b417be66c3710', '2b7e151628aed2a6abf7158809cf4f3c', 'c04b05357c5d1c0eeac4c66f9ff7f2e6', '000102030405060708090a0b0c0d0e0f')] finish pytest_pycollect_makeitem --> None [hook] pytest_pycollect_makeitem [hook] collector: name: aes_cfb_192_feedbacksize_16 obj: [('6bc1bee22e409f96e93d7e117393172a', '8e73b0f7da0e6452c810f32b809079e562f8ead2522c6b7b', 'cdc80d6fddf18cab34c25909c99a4174', '000102030405060708090a0b0c0d0e0f'), ('ae2d8a571e03ac9c9eb76fac45af8e51', '8e73b0f7da0e6452c810f32b809079e562f8ead2522c6b7b', '67ce7f7f81173621961a2b70171d3d7a', '000102030405060708090a0b0c0d0e0f'), ('30c81c46a35ce411e5fbc1191a0a52ef', '8e73b0f7da0e6452c810f32b809079e562f8ead2522c6b7b', '2e1e8a1dd59b88b1c8e60fed1efac4c9', '000102030405060708090a0b0c0d0e0f'), ('f69f2445df4f9b17ad2b417be66c3710', '8e73b0f7da0e6452c810f32b809079e562f8ead2522c6b7b', 'c05f9f9ca9834fa042ae8fba584b09ff', '000102030405060708090a0b0c0d0e0f')] finish pytest_pycollect_makeitem --> None [hook] pytest_pycollect_makeitem [hook] collector: name: aes_cfb_256_feedbacksize_16 obj: [('6bc1bee22e409f96e93d7e117393172a', '603deb1015ca71be2b73aef0857d77811f352c073b6108d72d9810a30914dff4', 'dc7e84bfda79164b7ecd8486985d3860', '000102030405060708090a0b0c0d0e0f'), ('ae2d8a571e03ac9c9eb76fac45af8e51', '603deb1015ca71be2b73aef0857d77811f352c073b6108d72d9810a30914dff4', '39ffed143b28b1c832113c6331e5407b', '000102030405060708090a0b0c0d0e0f'), ('30c81c46a35ce411e5fbc1191a0a52ef', '603deb1015ca71be2b73aef0857d77811f352c073b6108d72d9810a30914dff4', 'df10132415e54b92a13ed0a8267ae2f9', '000102030405060708090a0b0c0d0e0f'), ('f69f2445df4f9b17ad2b417be66c3710', '603deb1015ca71be2b73aef0857d77811f352c073b6108d72d9810a30914dff4', '75a385741ab9cef82031623d55b1e471', '000102030405060708090a0b0c0d0e0f')] finish pytest_pycollect_makeitem --> None [hook] pytest_pycollect_makeitem [hook] collector: name: aes_cfb_long obj: [('006bc1bee22e409f96e93d7e117393172aae2d8a571e03ac9c9eb76fac45af8e5130c81c46a35ce411e5fbc1191a0a52eff69f2445df4f9b17ad2b417be66c3710006bc1bee22e409f96e93d7e117393172aae2d8a571e03ac9c9eb76fac45af8e5130c81c46a35ce411e5fbc1191a0a52eff69f2445df4f9b17ad2b417be66c3710006bc1bee22e409f96e93d7e117393172aae2d8a571e03ac9c9eb76fac45af8e5130c81c46a35ce411e5fbc1191a0a52eff69f2445df4f9b17ad2b417be66c3710006bc1bee22e409f96e93d7e117393172aae2d8a571e03ac9c9eb76fac45af8e5130c81c46a35ce411e5fbc1191a0a52eff69f2445df4f9b17ad2b417be66c3710006bc1bee22e409f96e93d7e117393172aae2d8a571e03ac9c9eb76fac45af8e5130c81c46a35ce411e5fbc1191a0a52eff69f2445df4f9b17ad2b417be66c3710006bc1bee22e409f96e93d7e117393172aae2d8a571e03ac9c9eb76fac45af8e5130c81c46a35ce411e5fbc1191a0a52eff69f2445df4f9b17ad2b417be66c3710006bc1bee22e409f96e93d7e117393172aae2d8a571e03ac9c9eb76fac45af8e5130c81c46a35ce411e5fbc1191a0a52eff69f2445df4f9b17ad2b417be66c3710006bc1bee22e409f96e93d7e117393172aae2d8a571e03ac9c9eb76fac45af8e5130c81c46a35ce411e5fbc1191a0a52eff69f2445df4f9b17ad2b417be66c3710006bc1bee22e409f96e93d7e117393172aae2d8a571e03ac9c9eb76fac45af8e5130c81c46a35ce411e5fbc1191a0a52eff69f2445df4f9b17ad2b417be66c3710006bc1bee22e409f96e93d7e117393172aae2d8a571e03ac9c9eb76fac45af8e5130c81c46a35ce411e5fbc1191a0a52eff69f2445df4f9b17ad2b417be66c3710006bc1bee22e409f96e93d7e117393172aae2d8a571e03ac9c9eb76fac45af8e5130c81c46a35ce411e5fbc1191a0a52eff69f2445df4f9b17ad2b417be66c3710', '2b7e151628aed2a6abf7158809cf4f3c', 'ECE71ECD7A4E3C2F643B2B0BFBED32F365C96D626048D13C65962ED08445B5EE74B11203E24C0ACCD3CC13F39963632D8F4B8F8BB16B7901373C32FFD27472957A8448E414A26BB10CAE9BCFBF332BA677D59C0CCD4CCE5B34298E2B1F3250092CF602B5476922D9FA13D4AE9F54841D889FE71D67A79315A621BDAECB2FD3F1ECDAB0DC9FBDFB85AE1633038A44E15DEF1B6DDBC4AB47BB128E1C2DE8A17FD1107D8587CE96088709E17DA23DE6993973A43DFB59801A9691B7EBF5565C4FF842F5132E99288FA4CE3E6CE9333DEE052212E71EF08C5E2E385A787F1567C0CD05A4D11BF40CA19B8D49A231AA55CDE1B8C531C9FCD3B9C70AABD65372E582FCE7528B6BD8F89AA6489B1F085AE024D5A964CAEC4F3F5726CBACDB5D8429F6741FE102BC27E10724C30A64A7D3ED11F6FF41908920A1326793C7C7EDDDD2F79D8A3CE804AE53E59E43B2E0E69AF69A79D7A97A12C0A1AC7331369FCE4072879AA998CD1DC6296CB02D4B97803F1F3713F922796148E2263AFA6A72CF30C3C00297ABF2AD2D559AC4D0011A839FAAA261BB17966E80FF243B65B6209C2732F294F33936A3B8FE7C9BEBE50686BBE7F0FDCF9E24281242B10844037D9AB8A342B954B69E6456243CC13959E1B014A1389BA69B9C4E1C0869C7FE3292ED72FCF183B216F7F5EB5A7CD0A2493BCA160AE6142F4CF03110CA4782CA6C8ED558CA8AF4B14ADC4C368FF0C0CD014F7E117F56D797EF45294C8D3BCED9D5D4E3FA60592031E2925ABA72DFE5AC1D88081DB6CF68DCB256A822CE891AD12F5BB34F39CE974F7D23C0B7AB3BF12D854DA60617EB5E479A9740E00A1DCA267A3D1D212F25A06B83106CBD624CC745ACB31E0EA774F6E0D765D6134F74A3AF5B3846649C14539B7C01B484C54F71B2C5016C2EA57B16472145511130D79E23271151F370DB8A626DB218F73FF0ABFE066E2782696F6984923AA074AEA9E059AEC18F50D4E03F4B17BAD856E6C962604A02', 'f0f1f2f3f4f5f6f7f8f9fafbfcfdfeff')] finish pytest_pycollect_makeitem --> None [hook] pytest_pycollect_makeitem [hook] collector: name: aes_ofb_128 obj: [('6bc1bee22e409f96e93d7e117393172a', '2b7e151628aed2a6abf7158809cf4f3c', '3b3fd92eb72dad20333449f8e83cfb4a', '000102030405060708090a0b0c0d0e0f'), ('ae2d8a571e03ac9c9eb76fac45af8e51', '2b7e151628aed2a6abf7158809cf4f3c', '7789508d16918f03f53c52dac54ed825', '000102030405060708090a0b0c0d0e0f'), ('30c81c46a35ce411e5fbc1191a0a52ef', '2b7e151628aed2a6abf7158809cf4f3c', '9740051e9c5fecf64344f7a82260edcc', '000102030405060708090a0b0c0d0e0f'), ('f69f2445df4f9b17ad2b417be66c3710', '2b7e151628aed2a6abf7158809cf4f3c', '304c6528f659c77866a510d9c1d6ae5e', '000102030405060708090a0b0c0d0e0f')] finish pytest_pycollect_makeitem --> None [hook] pytest_pycollect_makeitem [hook] collector: name: aes_ofb_192 obj: [('6bc1bee22e409f96e93d7e117393172a', '8e73b0f7da0e6452c810f32b809079e562f8ead2522c6b7b', 'cdc80d6fddf18cab34c25909c99a4174', '000102030405060708090a0b0c0d0e0f'), ('ae2d8a571e03ac9c9eb76fac45af8e51', '8e73b0f7da0e6452c810f32b809079e562f8ead2522c6b7b', 'fcc28b8d4c63837c09e81700c1100401', '000102030405060708090a0b0c0d0e0f'), ('30c81c46a35ce411e5fbc1191a0a52ef', '8e73b0f7da0e6452c810f32b809079e562f8ead2522c6b7b', '8d9a9aeac0f6596f559c6d4daf59a5f2', '000102030405060708090a0b0c0d0e0f'), ('f69f2445df4f9b17ad2b417be66c3710', '8e73b0f7da0e6452c810f32b809079e562f8ead2522c6b7b', '6d9f200857ca6c3e9cac524bd9acc92a', '000102030405060708090a0b0c0d0e0f')] finish pytest_pycollect_makeitem --> None [hook] pytest_pycollect_makeitem [hook] collector: name: aes_ofb_256 obj: [('6bc1bee22e409f96e93d7e117393172a', '603deb1015ca71be2b73aef0857d77811f352c073b6108d72d9810a30914dff4', 'dc7e84bfda79164b7ecd8486985d3860', '000102030405060708090a0b0c0d0e0f'), ('ae2d8a571e03ac9c9eb76fac45af8e51', '603deb1015ca71be2b73aef0857d77811f352c073b6108d72d9810a30914dff4', '4febdc6740d20b3ac88f6ad82a4fb08d', '000102030405060708090a0b0c0d0e0f'), ('30c81c46a35ce411e5fbc1191a0a52ef', '603deb1015ca71be2b73aef0857d77811f352c073b6108d72d9810a30914dff4', '71ab47a086e86eedf39d1c5bba97c408', '000102030405060708090a0b0c0d0e0f'), ('f69f2445df4f9b17ad2b417be66c3710', '603deb1015ca71be2b73aef0857d77811f352c073b6108d72d9810a30914dff4', '0126141d67f37be8538f5a8be740e484', '000102030405060708090a0b0c0d0e0f')] finish pytest_pycollect_makeitem --> None [hook] pytest_pycollect_makeitem [hook] collector: name: aes_ofb_long obj: [('006bc1bee22e409f96e93d7e117393172aae2d8a571e03ac9c9eb76fac45af8e5130c81c46a35ce411e5fbc1191a0a52eff69f2445df4f9b17ad2b417be66c3710006bc1bee22e409f96e93d7e117393172aae2d8a571e03ac9c9eb76fac45af8e5130c81c46a35ce411e5fbc1191a0a52eff69f2445df4f9b17ad2b417be66c3710006bc1bee22e409f96e93d7e117393172aae2d8a571e03ac9c9eb76fac45af8e5130c81c46a35ce411e5fbc1191a0a52eff69f2445df4f9b17ad2b417be66c3710006bc1bee22e409f96e93d7e117393172aae2d8a571e03ac9c9eb76fac45af8e5130c81c46a35ce411e5fbc1191a0a52eff69f2445df4f9b17ad2b417be66c3710006bc1bee22e409f96e93d7e117393172aae2d8a571e03ac9c9eb76fac45af8e5130c81c46a35ce411e5fbc1191a0a52eff69f2445df4f9b17ad2b417be66c3710006bc1bee22e409f96e93d7e117393172aae2d8a571e03ac9c9eb76fac45af8e5130c81c46a35ce411e5fbc1191a0a52eff69f2445df4f9b17ad2b417be66c3710006bc1bee22e409f96e93d7e117393172aae2d8a571e03ac9c9eb76fac45af8e5130c81c46a35ce411e5fbc1191a0a52eff69f2445df4f9b17ad2b417be66c3710006bc1bee22e409f96e93d7e117393172aae2d8a571e03ac9c9eb76fac45af8e5130c81c46a35ce411e5fbc1191a0a52eff69f2445df4f9b17ad2b417be66c3710006bc1bee22e409f96e93d7e117393172aae2d8a571e03ac9c9eb76fac45af8e5130c81c46a35ce411e5fbc1191a0a52eff69f2445df4f9b17ad2b417be66c3710006bc1bee22e409f96e93d7e117393172aae2d8a571e03ac9c9eb76fac45af8e5130c81c46a35ce411e5fbc1191a0a52eff69f2445df4f9b17ad2b417be66c3710006bc1bee22e409f96e93d7e117393172aae2d8a571e03ac9c9eb76fac45af8e5130c81c46a35ce411e5fbc1191a0a52eff69f2445df4f9b17ad2b417be66c3710', '2b7e151628aed2a6abf7158809cf4f3c', 'ECE71ECD7A4E3C2F643B2B0BFBED32F3B3D63D91F8B99D5EA9D0AA2D977A8675EDD972802EB60B3D8FA629EF94358D46861CF60D9F89F481632F937182C78E49D53D132260CFC3A80943E0FD169C6091FF4BBBBDEC35F4A31DDB61AFA087750D6CFCF86DAB13330125D60A2732E43A2AF3E47ABE4824C5B17DD747F267149A321ADA13409D51D4FC685ADA6789D5785FCA5EF199FD96A03879B4147C4936CC32DE864520C98DD55408CA8ED4AF1BE1F133ED53CA9FF58E6862D3E900AE66EEF75272B547BBC8919CE5503981684FEBA088F5E73BF272C820656CC9627FB4E4FC3A92A6B815CAC558B3257614AA9BB2CF2409D3633B6570EEF67A9343502D2B528078E561782917D977E6F76B13CD6526512D3D4C803BBB58E54EED5B4057EAF85DE83A7EC53FACBCA7E03EB7E027910C8DA25B75BE33B41C0C594DF6D781E821193963C9F658D380A460561B2F0C9C3D7639A4E4EE2DA87653DA86FAD6D5280857CEC28CC40D082C81C672D9B36CD169A6803ACA4C8DAAD77953B296FBAF480FA146F8B41DCBD487A368851A207C90228DBF7BAEEB38F23F98520E52145D809DB530D3E690C2A91B8367B815C4FFC0AE7171582169D6A7FD073A1F9DE1182FC98D1D5B3E39B44E054218B80091333D5B751C0530BADF4361C5A95CB26634AE788F7B6D2CCA543FDE48172A24E4D991F9262CFB8ED09FFE4E1506DA6478EF879847F8CE44569A9AC66E124CEE5944D2DC87742CA1B598B3C7D54662F8A5783A0C6689C949C54E148C2C88DFBA4F10F0234BA62E4DDEA30F5AD3D209829CCB73C22141D56050FB75E0E7D1B822F6FFC6AB92E8DB12A5C6B62064B692F8B118CC38F0436433B5370CE5A79D09A7081703EEA59F64B7361AA50476DD2F7074CA37C51935DCBC78A806F92C1186033070D5C3FABACAAE39CB7FBA0654D13413E94F6E9FDDB7D2D4EC1985CCF2E2011C186BD0C16AA95A0C7FDDF1B36490780EB646EEB7B0B377E970FD7D2E9A06', 'f0f1f2f3f4f5f6f7f8f9fafbfcfdfeff')] finish pytest_pycollect_makeitem --> None [hook] pytest_pycollect_makeitem [hook] collector: name: aes_ctr_128 obj: [('6bc1bee22e409f96e93d7e117393172a', '2b7e151628aed2a6abf7158809cf4f3c', '874d6191b620e3261bef6864990db6ce', 'f0f1f2f3f4f5f6f7f8f9fafbfcfdfeff'), ('ae2d8a571e03ac9c9eb76fac45af8e51', '2b7e151628aed2a6abf7158809cf4f3c', '9806f66b7970fdff8617187bb9fffdff', 'f0f1f2f3f4f5f6f7f8f9fafbfcfdfeff'), ('30c81c46a35ce411e5fbc1191a0a52ef', '2b7e151628aed2a6abf7158809cf4f3c', '5ae4df3edbd5d35e5b4f09020db03eab', 'f0f1f2f3f4f5f6f7f8f9fafbfcfdfeff'), ('f69f2445df4f9b17ad2b417be66c3710', '2b7e151628aed2a6abf7158809cf4f3c', '1e031dda2fbe03d1792170a0f3009cee', 'f0f1f2f3f4f5f6f7f8f9fafbfcfdfeff')] finish pytest_pycollect_makeitem --> None [hook] pytest_pycollect_makeitem [hook] collector: name: aes_ctr_192 obj: [('6bc1bee22e409f96e93d7e117393172a', '8e73b0f7da0e6452c810f32b809079e562f8ead2522c6b7b', '1abc932417521ca24f2b0459fe7e6e0b', 'f0f1f2f3f4f5f6f7f8f9fafbfcfdfeff'), ('ae2d8a571e03ac9c9eb76fac45af8e51', '8e73b0f7da0e6452c810f32b809079e562f8ead2522c6b7b', '090339ec0aa6faefd5ccc2c6f4ce8e94', 'f0f1f2f3f4f5f6f7f8f9fafbfcfdfeff'), ('30c81c46a35ce411e5fbc1191a0a52ef', '8e73b0f7da0e6452c810f32b809079e562f8ead2522c6b7b', '1e36b26bd1ebc670d1bd1d665620abf7', 'f0f1f2f3f4f5f6f7f8f9fafbfcfdfeff'), ('f69f2445df4f9b17ad2b417be66c3710', '8e73b0f7da0e6452c810f32b809079e562f8ead2522c6b7b', '4f78a7f6d29809585a97daec58c6b050', 'f0f1f2f3f4f5f6f7f8f9fafbfcfdfeff')] finish pytest_pycollect_makeitem --> None [hook] pytest_pycollect_makeitem [hook] collector: name: aes_ctr_256 obj: [('6bc1bee22e409f96e93d7e117393172a', '603deb1015ca71be2b73aef0857d77811f352c073b6108d72d9810a30914dff4', '601ec313775789a5b7a7f504bbf3d228', 'f0f1f2f3f4f5f6f7f8f9fafbfcfdfeff'), ('ae2d8a571e03ac9c9eb76fac45af8e51', '603deb1015ca71be2b73aef0857d77811f352c073b6108d72d9810a30914dff4', 'f443e3ca4d62b59aca84e990cacaf5c5', 'f0f1f2f3f4f5f6f7f8f9fafbfcfdfeff'), ('30c81c46a35ce411e5fbc1191a0a52ef', '603deb1015ca71be2b73aef0857d77811f352c073b6108d72d9810a30914dff4', '2b0930daa23de94ce87017ba2d84988d', 'f0f1f2f3f4f5f6f7f8f9fafbfcfdfeff'), ('f69f2445df4f9b17ad2b417be66c3710', '603deb1015ca71be2b73aef0857d77811f352c073b6108d72d9810a30914dff4', 'dfc9c58db67aada613c2dd08457941a6', 'f0f1f2f3f4f5f6f7f8f9fafbfcfdfeff')] finish pytest_pycollect_makeitem --> None [hook] pytest_pycollect_makeitem [hook] collector: name: aes_ctr_long obj: [('006bc1bee22e409f96e93d7e117393172aae2d8a571e03ac9c9eb76fac45af8e5130c81c46a35ce411e5fbc1191a0a52eff69f2445df4f9b17ad2b417be66c3710006bc1bee22e409f96e93d7e117393172aae2d8a571e03ac9c9eb76fac45af8e5130c81c46a35ce411e5fbc1191a0a52eff69f2445df4f9b17ad2b417be66c3710006bc1bee22e409f96e93d7e117393172aae2d8a571e03ac9c9eb76fac45af8e5130c81c46a35ce411e5fbc1191a0a52eff69f2445df4f9b17ad2b417be66c3710006bc1bee22e409f96e93d7e117393172aae2d8a571e03ac9c9eb76fac45af8e5130c81c46a35ce411e5fbc1191a0a52eff69f2445df4f9b17ad2b417be66c3710006bc1bee22e409f96e93d7e117393172aae2d8a571e03ac9c9eb76fac45af8e5130c81c46a35ce411e5fbc1191a0a52eff69f2445df4f9b17ad2b417be66c3710006bc1bee22e409f96e93d7e117393172aae2d8a571e03ac9c9eb76fac45af8e5130c81c46a35ce411e5fbc1191a0a52eff69f2445df4f9b17ad2b417be66c3710006bc1bee22e409f96e93d7e117393172aae2d8a571e03ac9c9eb76fac45af8e5130c81c46a35ce411e5fbc1191a0a52eff69f2445df4f9b17ad2b417be66c3710006bc1bee22e409f96e93d7e117393172aae2d8a571e03ac9c9eb76fac45af8e5130c81c46a35ce411e5fbc1191a0a52eff69f2445df4f9b17ad2b417be66c3710006bc1bee22e409f96e93d7e117393172aae2d8a571e03ac9c9eb76fac45af8e5130c81c46a35ce411e5fbc1191a0a52eff69f2445df4f9b17ad2b417be66c3710006bc1bee22e409f96e93d7e117393172aae2d8a571e03ac9c9eb76fac45af8e5130c81c46a35ce411e5fbc1191a0a52eff69f2445df4f9b17ad2b417be66c3710006bc1bee22e409f96e93d7e117393172aae2d8a571e03ac9c9eb76fac45af8e5130c81c46a35ce411e5fbc1191a0a52eff69f2445df4f9b17ad2b417be66c3710', '2b7e151628aed2a6abf7158809cf4f3c', 'ECE71ECD7A4E3C2F643B2B0BFBED32F31C8551B6306D52CF843EC0B85015DC203B1C0B643E2A6BABAF5133DA0EA06616076AA6BBB52ED75DC3A71A9A6E8AC7C9A00D2C39AA68BF4E6FFED9AAEE5AD6914FB3EA77C7B61FF6BF564F2F1225ACB4B5889CB1559888A5817849C382E168482F75381F63868C468E4D1583B1FE71DD808CB94D8150AAB9D530A0FC17CDE748E95545D8A033B2F61F1954D0C0226168022E1CD7E031C57D048AC560F152960F47705E174D956D4BB53AE80BFFCD1BD569ED8EFFA223C00558B702405F33E6E0EDB2D9B0C148A1441CC80D6ABBCE785AA1B9DAB7CB8832F1B12D2EE60EE2DFCA37942CA1724E5602B7B70525AC9662028A22DB234676615DB474538CBC8D197F38C88BCC4F9E8D207538CA18DE5F095420A2E4D5868CEBB8B34A9377DC52D119790B65210F1B346F5E00D9BD00A8847048913D80726B9B745D565E6284B986DBAEA997FFC5A0DE5051527D44B2C1266DBC9130A6EB15F37A0F00B6286D6678CA651C07743BD37F2E8F6A94F5ED8C63428AE4883A9695183807E104BC335C64FEAAC40A605913DF98FF44E0801B31A968CCE5DCAFADE1E017FA711E05FF5A54BFA1999C2C463F97A3A66B30211BD306C8911C98F8EE5EF47A54746A4D16B7C7424A6954B4FC3BCF1A41BDE8A19CE1027AE86A320D0E5E7D3C7E50CFD0C4665B811D86C313F09ADE5B4DBE017231859881E5873E9EDB2011CF5920D2F7277C4DE1AC430A1849F0B870A69ABE701B6D0B5123E5FF53395409177CF84BF41EC33C5E4BCC2CF29258DC7C260471AABDA49FDE62915758EE4E578D0F7698E6456BC144573739D5D508CC76B389359D2A0ECB5B7EE5FCB4C3151D5AF7C71819EA3DD5F36C7B27E551FD2373D07FFDC76A13FC4B10A6F29A83D6F465ACB6960671EACF21A3E1CB4411C4DAA0C2A87DAED28AEE60B7EC0258A9AF125F2DDC80B9877EFE0F372D9B832C786770A84EA1A07CB6E1A9907D651BBD0EFDEF2AFFC3', 'f0f1f2f3f4f5f6f7f8f9fafbfcfdfeff')] finish pytest_pycollect_makeitem --> None [hook] pytest_pycollect_makeitem [hook] collector: name: aes_ccm obj: [('08090A0B0C0D0E0F101112131415161718191A1B1C1D1E', 'C0C1C2C3C4C5C6C7C8C9CACBCCCDCECF', '588C979A61C663D2F066D0C2C0F989806D5F6B61DAC38417E8D12CFDF926E0', '00000003020100A0A1A2A3A4A5', '0001020304050607', 8), ('08090A0B0C0D0E0F101112131415161718191A1B1C1D1E1F', 'C0C1C2C3C4C5C6C7C8C9CACBCCCDCECF', '72C91A36E135F8CF291CA894085C87E3CC15C439C9E43A3BA091D56E10400916', '00000004030201A0A1A2A3A4A5', '0001020304050607', 8), ('0C0D0E0F101112131415161718191A1B1C1D1E', 'C0C1C2C3C4C5C6C7C8C9CACBCCCDCECF', 'A28C6865939A9A79FAAA5C4C2A9D4A91CDAC8C96C861B9C9E61EF1', '00000006050403A0A1A2A3A4A5', '000102030405060708090A0B', 8), ('0C0D0E0F101112131415161718191A1B1C1D1E1F', 'C0C1C2C3C4C5C6C7C8C9CACBCCCDCECF', 'DCF1FB7B5D9E23FB9D4E131253658AD86EBDCA3E51E83F077D9C2D93', '00000007060504A0A1A2A3A4A5', '000102030405060708090A0B', 8), ('0C0D0E0F101112131415161718191A1B1C1D1E1F20', 'C0C1C2C3C4C5C6C7C8C9CACBCCCDCECF', '6FC1B011F006568B5171A42D953D469B2570A4BD87405A0443AC91CB94', '00000008070605A0A1A2A3A4A5', '000102030405060708090A0B', 8), ('08090A0B0C0D0E0F101112131415161718191A1B1C1D1E', 'C0C1C2C3C4C5C6C7C8C9CACBCCCDCECF', '0135D1B2C95F41D5D1D4FEC185D166B8094E999DFED96C048C56602C97ACBB7490', '00000009080706A0A1A2A3A4A5', '0001020304050607', 10), ('08090A0B0C0D0E0F101112131415161718191A1B1C1D1E1F', 'C0C1C2C3C4C5C6C7C8C9CACBCCCDCECF', '7B75399AC0831DD2F0BBD75879A2FD8F6CAE6B6CD9B7DB24C17B4433F434963F34B4', '0000000A090807A0A1A2A3A4A5', '0001020304050607', 10), ('08E8CF97D820EA258460E96AD9CF5289054D895CEAC47C', 'D7828D13B2B0BDC325A76236DF93CC6B', '4CB97F86A2A4689A877947AB8091EF5386A6FFBDD080F8E78CF7CB0CDDD7B3', '00412B4EA9CDBE3C9696766CFA', '0BE1A88BACE018B1', 8), ('ABF21C0B02FEB88F856DF4A37381BCE3CC128517D4', 'D7828D13B2B0BDC325A76236DF93CC6B', 'F32905B88A641B04B9C9FFB58CC390900F3DA12AB16DCE9E82EFA16DA62059', '008D493B30AE8B3C9696766CFA', '6E37A6EF546D955D34AB6059', 10)] finish pytest_pycollect_makeitem --> None [hook] pytest_pycollect_makeitem [hook] collector: name: aes_gcm_128 obj: [('00000000000000000000000000000000', '000000000000000000000000', '', '', '', '58e2fccefa7e3061367f1d57a4e7455a'), ('00000000000000000000000000000000', '000000000000000000000000', '00000000000000000000000000000000', '0388dace60b6a392f328c2b971b2fe78', '', 'ab6e47d42cec13bdf53a67b21257bddf'), ('feffe9928665731c6d6a8f9467308308', 'cafebabefacedbaddecaf888', 'd9313225f88406e5a55909c5aff5269a86a7a9531534f7da2e4c303d8a318a721c3c0c95956809532fcf0e2449a6b525b16aedf5aa0de657ba637b391aafd255', '42831ec2217774244b7221b784d0d49ce3aa212f2c02a4e035c17e2329aca12e21d514b25466931c7d8f6a5aac84aa051ba30b396a0aac973d58e091473f5985', '', '4d5c2af327cd64a62cf35abd2ba6fab4'), ('feffe9928665731c6d6a8f9467308308', 'cafebabefacedbaddecaf888', 'd9313225f88406e5a55909c5aff5269a86a7a9531534f7da2e4c303d8a318a721c3c0c95956809532fcf0e2449a6b525b16aedf5aa0de657ba637b39', '42831ec2217774244b7221b784d0d49ce3aa212f2c02a4e035c17e2329aca12e21d514b25466931c7d8f6a5aac84aa051ba30b396a0aac973d58e091', 'feedfacedeadbeeffeedfacedeadbeefabaddad2', '5bc94fbc3221a5db94fae95ae7121a47'), ('feffe9928665731c6d6a8f9467308308', 'cafebabefacedbad', 'd9313225f88406e5a55909c5aff5269a86a7a9531534f7da2e4c303d8a318a721c3c0c95956809532fcf0e2449a6b525b16aedf5aa0de657ba637b39', '61353b4c2806934a777ff51fa22a4755699b2a714fcdc6f83766e5f97b6c742373806900e49f24b22b097544d4896b424989b5e1ebac0f07c23f4598', 'feedfacedeadbeeffeedfacedeadbeefabaddad2', '3612d2e79e3b0785561be14aaca2fccb'), ('feffe9928665731c6d6a8f9467308308', '9313225df88406e555909c5aff5269aa6a7a9538534f7da1e4c303d2a318a728c3c0c95156809539fcf0e2429a6b525416aedbf5a0de6a57a637b39b', 'd9313225f88406e5a55909c5aff5269a86a7a9531534f7da2e4c303d8a318a721c3c0c95956809532fcf0e2449a6b525b16aedf5aa0de657ba637b39', '8ce24998625615b603a033aca13fb894be9112a5c3a211a8ba262a3cca7e2ca701e4a9a4fba43c90ccdcb281d48c7c6fd62875d2aca417034c34aee5', 'feedfacedeadbeeffeedfacedeadbeefabaddad2', '619cc5aefffe0bfa462af43c1699d050'), ('00000000000000000000000000000000', '000000000000000000000000', '', '', 'd9313225f88406e5a55909c5aff5269a86a7a9531534f7da2e4c303d8a318a721c3c0c95956809532fcf0e2449a6b525b16aedf5aa0de657ba637b391aafd255522dc1f099567d07f47f37a32a84427d643a8cdcbfe5c0c97598a2bd2555d1aa8cb08e48590dbb3da7b08b1056828838c5f61e6393ba7a0abcc9f662898015ad', '5fea793a2d6f974d37e68e0cb8ff9492'), ('00000000000000000000000000000000', '000000000000000000000000', '000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000', '0388dace60b6a392f328c2b971b2fe78f795aaab494b5923f7fd89ff948bc1e0200211214e7394da2089b6acd093abe0', '', '9dd0a376b08e40eb00c35f29f9ea61a4'), ('00000000000000000000000000000000', '000000000000000000000000', '0000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000', '0388dace60b6a392f328c2b971b2fe78f795aaab494b5923f7fd89ff948bc1e0200211214e7394da2089b6acd093abe0c94da219118e297d7b7ebcbcc9c388f28ade7d85a8ee35616f7124a9d5270291', '', '98885a3a22bd4742fe7b72172193b163'), ('00000000000000000000000000000000', '000000000000000000000000', '0000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000', '0388dace60b6a392f328c2b971b2fe78f795aaab494b5923f7fd89ff948bc1e0200211214e7394da2089b6acd093abe0c94da219118e297d7b7ebcbcc9c388f28ade7d85a8ee35616f7124a9d527029195b84d1b96c690ff2f2de30bf2ec89e00253786e126504f0dab90c48a30321de3345e6b0461e7c9e6c6b7afedde83f40', '', 'cac45f60e31efd3b5a43b98a22ce1aa1'), ('00000000000000000000000000000000', 'ffffffff000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000', '000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000', '56b3373ca9ef6e4a2b64fe1e9a17b61425f10d47a75a5fce13efc6bc784af24f4141bdd48cf7c770887afd573cca5418a9aeffcd7c5ceddfc6a78397b9a85b499da558257267caab2ad0b23ca476a53cb17fb41c4b8b475cb4f3f7165094c229c9e8c4dc0a2a5ff1903e501511221376a1cdb8364c5061a20cae74bc4acd76ceb0abc9fd3217ef9f8c90be402ddf6d8697f4f880dff15bfb7a6b28241ec8fe183c2d59e3f9dfff653c7126f0acb9e64211f42bae12af462b1070bef1ab5e3606', '', '566f8ef683078bfdeeffa869d751a017'), ('843ffcf5d2b72694d19ed01d01249412', 'dbcca32ebf9b804617c3aa9e', '000102030405060708090a0b0c0d0e0f101112131415161718191a1b1c1d1e1f202122232425262728292a2b2c2d2e2f303132333435363738393a3b3c3d3e3f404142434445464748494a4b4c4d4e4f', '6268c6fa2a80b2d137467f092f657ac04d89be2beaa623d61b5a868c8f03ff95d3dcee23ad2f1ab3a6c80eaf4b140eb05de3457f0fbc111a6b43d0763aa422a3013cf1dc37fe417d1fbfc449b75d4cc5', '00000000000000000000000000000000101112131415161718191a1b1c1d1e1f', '3b629ccfbc1119b7319e1dce2cd6fd6d')] finish pytest_pycollect_makeitem --> None [hook] pytest_pycollect_makeitem [hook] collector: name: aes_gcm_256 obj: [('0000000000000000000000000000000000000000000000000000000000000000', '000000000000000000000000', '', '', '', '530f8afbc74536b9a963b4f1c4cb738b'), ('0000000000000000000000000000000000000000000000000000000000000000', '000000000000000000000000', '00000000000000000000000000000000', 'cea7403d4d606b6e074ec5d3baf39d18', '', 'd0d1c8a799996bf0265b98b5d48ab919'), ('feffe9928665731c6d6a8f9467308308feffe9928665731c6d6a8f9467308308', 'cafebabefacedbaddecaf888', 'd9313225f88406e5a55909c5aff5269a86a7a9531534f7da2e4c303d8a318a721c3c0c95956809532fcf0e2449a6b525b16aedf5aa0de657ba637b391aafd255', '522dc1f099567d07f47f37a32a84427d643a8cdcbfe5c0c97598a2bd2555d1aa8cb08e48590dbb3da7b08b1056828838c5f61e6393ba7a0abcc9f662898015ad', '', 'b094dac5d93471bdec1a502270e3cc6c'), ('feffe9928665731c6d6a8f9467308308feffe9928665731c6d6a8f9467308308', 'cafebabefacedbaddecaf888', 'd9313225f88406e5a55909c5aff5269a86a7a9531534f7da2e4c303d8a318a721c3c0c95956809532fcf0e2449a6b525b16aedf5aa0de657ba637b39', '522dc1f099567d07f47f37a32a84427d643a8cdcbfe5c0c97598a2bd2555d1aa8cb08e48590dbb3da7b08b1056828838c5f61e6393ba7a0abcc9f662', 'feedfacedeadbeeffeedfacedeadbeefabaddad2', '76fc6ece0f4e1768cddf8853bb2d551b'), ('feffe9928665731c6d6a8f9467308308feffe9928665731c6d6a8f9467308308', 'cafebabefacedbad', 'd9313225f88406e5a55909c5aff5269a86a7a9531534f7da2e4c303d8a318a721c3c0c95956809532fcf0e2449a6b525b16aedf5aa0de657ba637b39', 'c3762df1ca787d32ae47c13bf19844cbaf1ae14d0b976afac52ff7d79bba9de0feb582d33934a4f0954cc2363bc73f7862ac430e64abe499f47c9b1f', 'feedfacedeadbeeffeedfacedeadbeefabaddad2', '3a337dbf46a792c45e454913fe2ea8f2'), ('feffe9928665731c6d6a8f9467308308feffe9928665731c6d6a8f9467308308', '9313225df88406e555909c5aff5269aa6a7a9538534f7da1e4c303d2a318a728c3c0c95156809539fcf0e2429a6b525416aedbf5a0de6a57a637b39b', 'd9313225f88406e5a55909c5aff5269a86a7a9531534f7da2e4c303d8a318a721c3c0c95956809532fcf0e2449a6b525b16aedf5aa0de657ba637b39', '5a8def2f0c9e53f1f75d7853659e2a20eeb2b22aafde6419a058ab4f6f746bf40fc0c3b780f244452da3ebf1c5d82cdea2418997200ef82e44ae7e3f', 'feedfacedeadbeeffeedfacedeadbeefabaddad2', 'a44a8266ee1c8eb0c8b5d4cf5ae9f19a')] finish pytest_pycollect_makeitem --> None [hook] pytest_pycollect_makeitem [hook] collector: name: cfb_enc obj: finish pytest_pycollect_makeitem --> None [hook] pytest_pycollect_makeitem [hook] collector: name: cfb_8_enc obj: finish pytest_pycollect_makeitem --> None [hook] pytest_pycollect_makeitem [hook] collector: name: ctr_enc obj: finish pytest_pycollect_makeitem --> None [hook] pytest_pycollect_makeitem [hook] collector: name: ofb_enc obj: finish pytest_pycollect_makeitem --> None [hook] pytest_pycollect_makeitem [hook] collector: name: cbc_enc obj: finish pytest_pycollect_makeitem --> None [hook] pytest_pycollect_makeitem [hook] collector: name: ccm_enc obj: finish pytest_pycollect_makeitem --> None [hook] pytest_pycollect_makeitem [hook] collector: name: gcm_enc obj: finish pytest_pycollect_makeitem --> None [hook] pytest_pycollect_makeitem [hook] collector: name: ecb_enc obj: finish pytest_pycollect_makeitem --> None [hook] pytest_pycollect_makeitem [hook] collector: name: test_ecb_128 obj: pytest_generate_tests [hook] metafunc: <_pytest.python.Metafunc object at 0x7f1da2e335e0> pytest_make_parametrize_id [hook] config: <_pytest.config.Config object at 0x7f1da3c09270> val: argname: cipherobj finish pytest_make_parametrize_id --> None [hook] finish pytest_generate_tests --> [] [hook] finish pytest_pycollect_makeitem --> [] [hook] pytest_pycollect_makeitem [hook] collector: name: test_ecb_192 obj: pytest_generate_tests [hook] metafunc: <_pytest.python.Metafunc object at 0x7f1da2e32e00> pytest_make_parametrize_id [hook] config: <_pytest.config.Config object at 0x7f1da3c09270> val: argname: cipherobj finish pytest_make_parametrize_id --> None [hook] finish pytest_generate_tests --> [] [hook] finish pytest_pycollect_makeitem --> [] [hook] pytest_pycollect_makeitem [hook] collector: name: test_ecb_256 obj: pytest_generate_tests [hook] metafunc: <_pytest.python.Metafunc object at 0x7f1da2e32e00> pytest_make_parametrize_id [hook] config: <_pytest.config.Config object at 0x7f1da3c09270> val: argname: cipherobj finish pytest_make_parametrize_id --> None [hook] finish pytest_generate_tests --> [] [hook] finish pytest_pycollect_makeitem --> [] [hook] pytest_pycollect_makeitem [hook] collector: name: test_ecb_long obj: pytest_generate_tests [hook] metafunc: <_pytest.python.Metafunc object at 0x7f1da2e32e00> pytest_make_parametrize_id [hook] config: <_pytest.config.Config object at 0x7f1da3c09270> val: argname: cipherobj finish pytest_make_parametrize_id --> None [hook] finish pytest_generate_tests --> [] [hook] finish pytest_pycollect_makeitem --> [] [hook] pytest_pycollect_makeitem [hook] collector: name: test_cbc_128 obj: pytest_generate_tests [hook] metafunc: <_pytest.python.Metafunc object at 0x7f1da2e32e00> pytest_make_parametrize_id [hook] config: <_pytest.config.Config object at 0x7f1da3c09270> val: argname: cipherobj finish pytest_make_parametrize_id --> None [hook] finish pytest_generate_tests --> [] [hook] finish pytest_pycollect_makeitem --> [] [hook] pytest_pycollect_makeitem [hook] collector: name: test_cbc_192 obj: pytest_generate_tests [hook] metafunc: <_pytest.python.Metafunc object at 0x7f1da2e32e00> pytest_make_parametrize_id [hook] config: <_pytest.config.Config object at 0x7f1da3c09270> val: argname: cipherobj finish pytest_make_parametrize_id --> None [hook] finish pytest_generate_tests --> [] [hook] finish pytest_pycollect_makeitem --> [] [hook] pytest_pycollect_makeitem [hook] collector: name: test_cbc_256 obj: pytest_generate_tests [hook] metafunc: <_pytest.python.Metafunc object at 0x7f1da2e32e00> pytest_make_parametrize_id [hook] config: <_pytest.config.Config object at 0x7f1da3c09270> val: argname: cipherobj finish pytest_make_parametrize_id --> None [hook] finish pytest_generate_tests --> [] [hook] finish pytest_pycollect_makeitem --> [] [hook] pytest_pycollect_makeitem [hook] collector: name: test_cbc_long obj: pytest_generate_tests [hook] metafunc: <_pytest.python.Metafunc object at 0x7f1da2e32e00> pytest_make_parametrize_id [hook] config: <_pytest.config.Config object at 0x7f1da3c09270> val: argname: cipherobj finish pytest_make_parametrize_id --> None [hook] finish pytest_generate_tests --> [] [hook] finish pytest_pycollect_makeitem --> [] [hook] pytest_pycollect_makeitem [hook] collector: name: test_cfb_fb1 obj: pytest_generate_tests [hook] metafunc: <_pytest.python.Metafunc object at 0x7f1da2e32e00> pytest_make_parametrize_id [hook] config: <_pytest.config.Config object at 0x7f1da3c09270> val: argname: cipherobj finish pytest_make_parametrize_id --> None [hook] finish pytest_generate_tests --> [] [hook] finish pytest_pycollect_makeitem --> [] [hook] pytest_pycollect_makeitem [hook] collector: name: test_cfb_128_fb16 obj: pytest_generate_tests [hook] metafunc: <_pytest.python.Metafunc object at 0x7f1da2e32e00> pytest_make_parametrize_id [hook] config: <_pytest.config.Config object at 0x7f1da3c09270> val: argname: cipherobj finish pytest_make_parametrize_id --> None [hook] finish pytest_generate_tests --> [] [hook] finish pytest_pycollect_makeitem --> [] [hook] pytest_pycollect_makeitem [hook] collector: name: test_cfb_192_fb16 obj: pytest_generate_tests [hook] metafunc: <_pytest.python.Metafunc object at 0x7f1da2b15e70> pytest_make_parametrize_id [hook] config: <_pytest.config.Config object at 0x7f1da3c09270> val: argname: cipherobj finish pytest_make_parametrize_id --> None [hook] finish pytest_generate_tests --> [] [hook] finish pytest_pycollect_makeitem --> [] [hook] pytest_pycollect_makeitem [hook] collector: name: test_cfb_256_fb16 obj: pytest_generate_tests [hook] metafunc: <_pytest.python.Metafunc object at 0x7f1da2e32e00> pytest_make_parametrize_id [hook] config: <_pytest.config.Config object at 0x7f1da3c09270> val: argname: cipherobj finish pytest_make_parametrize_id --> None [hook] finish pytest_generate_tests --> [] [hook] finish pytest_pycollect_makeitem --> [] [hook] pytest_pycollect_makeitem [hook] collector: name: test_cfb_long_fb16 obj: pytest_generate_tests [hook] metafunc: <_pytest.python.Metafunc object at 0x7f1da2e32e00> pytest_make_parametrize_id [hook] config: <_pytest.config.Config object at 0x7f1da3c09270> val: argname: cipherobj finish pytest_make_parametrize_id --> None [hook] finish pytest_generate_tests --> [] [hook] finish pytest_pycollect_makeitem --> [] [hook] pytest_pycollect_makeitem [hook] collector: name: test_ofb_128 obj: pytest_generate_tests [hook] metafunc: <_pytest.python.Metafunc object at 0x7f1da2e32e00> pytest_make_parametrize_id [hook] config: <_pytest.config.Config object at 0x7f1da3c09270> val: argname: cipherobj finish pytest_make_parametrize_id --> None [hook] finish pytest_generate_tests --> [] [hook] finish pytest_pycollect_makeitem --> [] [hook] pytest_pycollect_makeitem [hook] collector: name: test_ofb_192 obj: pytest_generate_tests [hook] metafunc: <_pytest.python.Metafunc object at 0x7f1da2e32e00> pytest_make_parametrize_id [hook] config: <_pytest.config.Config object at 0x7f1da3c09270> val: argname: cipherobj finish pytest_make_parametrize_id --> None [hook] finish pytest_generate_tests --> [] [hook] finish pytest_pycollect_makeitem --> [] [hook] pytest_pycollect_makeitem [hook] collector: name: test_ofb_256 obj: pytest_generate_tests [hook] metafunc: <_pytest.python.Metafunc object at 0x7f1da2e32e00> pytest_make_parametrize_id [hook] config: <_pytest.config.Config object at 0x7f1da3c09270> val: argname: cipherobj finish pytest_make_parametrize_id --> None [hook] finish pytest_generate_tests --> [] [hook] finish pytest_pycollect_makeitem --> [] [hook] pytest_pycollect_makeitem [hook] collector: name: test_ofb_long obj: pytest_generate_tests [hook] metafunc: <_pytest.python.Metafunc object at 0x7f1da2e32e00> pytest_make_parametrize_id [hook] config: <_pytest.config.Config object at 0x7f1da3c09270> val: argname: cipherobj finish pytest_make_parametrize_id --> None [hook] finish pytest_generate_tests --> [] [hook] finish pytest_pycollect_makeitem --> [] [hook] pytest_pycollect_makeitem [hook] collector: name: test_ctr_128 obj: pytest_generate_tests [hook] metafunc: <_pytest.python.Metafunc object at 0x7f1da2e32e00> pytest_make_parametrize_id [hook] config: <_pytest.config.Config object at 0x7f1da3c09270> val: argname: cipherobj finish pytest_make_parametrize_id --> None [hook] finish pytest_generate_tests --> [] [hook] finish pytest_pycollect_makeitem --> [] [hook] pytest_pycollect_makeitem [hook] collector: name: test_ctr_192 obj: pytest_generate_tests [hook] metafunc: <_pytest.python.Metafunc object at 0x7f1da2e32e00> pytest_make_parametrize_id [hook] config: <_pytest.config.Config object at 0x7f1da3c09270> val: argname: cipherobj finish pytest_make_parametrize_id --> None [hook] finish pytest_generate_tests --> [] [hook] finish pytest_pycollect_makeitem --> [] [hook] pytest_pycollect_makeitem [hook] collector: name: test_ctr_256 obj: pytest_generate_tests [hook] metafunc: <_pytest.python.Metafunc object at 0x7f1da2e32e00> pytest_make_parametrize_id [hook] config: <_pytest.config.Config object at 0x7f1da3c09270> val: argname: cipherobj finish pytest_make_parametrize_id --> None [hook] finish pytest_generate_tests --> [] [hook] finish pytest_pycollect_makeitem --> [] [hook] pytest_pycollect_makeitem [hook] collector: name: test_ctr_long obj: pytest_generate_tests [hook] metafunc: <_pytest.python.Metafunc object at 0x7f1da2e32e00> pytest_make_parametrize_id [hook] config: <_pytest.config.Config object at 0x7f1da3c09270> val: argname: cipherobj finish pytest_make_parametrize_id --> None [hook] finish pytest_generate_tests --> [] [hook] finish pytest_pycollect_makeitem --> [] [hook] pytest_pycollect_makeitem [hook] collector: name: test_ccm obj: pytest_generate_tests [hook] metafunc: <_pytest.python.Metafunc object at 0x7f1da2e32e00> pytest_make_parametrize_id [hook] config: <_pytest.config.Config object at 0x7f1da3c09270> val: argname: cipherobj finish pytest_make_parametrize_id --> None [hook] finish pytest_generate_tests --> [] [hook] finish pytest_pycollect_makeitem --> [] [hook] pytest_pycollect_makeitem [hook] collector: name: test_gcm_128 obj: pytest_generate_tests [hook] metafunc: <_pytest.python.Metafunc object at 0x7f1da2e32e00> pytest_make_parametrize_id [hook] config: <_pytest.config.Config object at 0x7f1da3c09270> val: argname: cipherobj finish pytest_make_parametrize_id --> None [hook] finish pytest_generate_tests --> [] [hook] finish pytest_pycollect_makeitem --> [] [hook] pytest_pycollect_makeitem [hook] collector: name: test_gcm_256 obj: pytest_generate_tests [hook] metafunc: <_pytest.python.Metafunc object at 0x7f1da2e32e00> pytest_make_parametrize_id [hook] config: <_pytest.config.Config object at 0x7f1da3c09270> val: argname: cipherobj finish pytest_make_parametrize_id --> None [hook] finish pytest_generate_tests --> [] [hook] finish pytest_pycollect_makeitem --> [] [hook] finish pytest_make_collect_report --> [hook] genitems [collection] pytest_itemcollected [hook] item: finish pytest_itemcollected --> [] [hook] genitems [collection] pytest_itemcollected [hook] item: finish pytest_itemcollected --> [] [hook] genitems [collection] pytest_itemcollected [hook] item: finish pytest_itemcollected --> [] [hook] genitems [collection] pytest_itemcollected [hook] item: finish pytest_itemcollected --> [] [hook] genitems [collection] pytest_itemcollected [hook] item: finish pytest_itemcollected --> [] [hook] genitems [collection] pytest_itemcollected [hook] item: finish pytest_itemcollected --> [] [hook] genitems [collection] pytest_itemcollected [hook] item: finish pytest_itemcollected --> [] [hook] genitems [collection] pytest_itemcollected [hook] item: finish pytest_itemcollected --> [] [hook] genitems [collection] pytest_itemcollected [hook] item: finish pytest_itemcollected --> [] [hook] genitems [collection] pytest_itemcollected [hook] item: finish pytest_itemcollected --> [] [hook] genitems [collection] pytest_itemcollected [hook] item: finish pytest_itemcollected --> [] [hook] genitems [collection] pytest_itemcollected [hook] item: finish pytest_itemcollected --> [] [hook] genitems [collection] pytest_itemcollected [hook] item: finish pytest_itemcollected --> [] [hook] genitems [collection] pytest_itemcollected [hook] item: finish pytest_itemcollected --> [] [hook] genitems [collection] pytest_itemcollected [hook] item: finish pytest_itemcollected --> [] [hook] genitems [collection] pytest_itemcollected [hook] item: finish pytest_itemcollected --> [] [hook] genitems [collection] pytest_itemcollected [hook] item: finish pytest_itemcollected --> [] [hook] genitems [collection] pytest_itemcollected [hook] item: finish pytest_itemcollected --> [] [hook] genitems [collection] pytest_itemcollected [hook] item: finish pytest_itemcollected --> [] [hook] genitems [collection] pytest_itemcollected [hook] item: finish pytest_itemcollected --> [] [hook] genitems [collection] pytest_itemcollected [hook] item: finish pytest_itemcollected --> [] [hook] genitems [collection] pytest_itemcollected [hook] item: finish pytest_itemcollected --> [] [hook] genitems [collection] pytest_itemcollected [hook] item: finish pytest_itemcollected --> [] [hook] genitems [collection] pytest_itemcollected [hook] item: finish pytest_itemcollected --> [] [hook] pytest_collectreport [hook] report: finish pytest_collectreport --> [] [hook] genitems [collection] pytest_collectstart [hook] collector: finish pytest_collectstart --> [] [hook] pytest_make_collect_report [hook] collector: find_module called for: tests.test_des [assertion] matched test file '/home/webdev/Desktop/octopwnweb/code/projects/unicrypto/tests/test_des.py' [assertion] found cached rewritten pyc for /home/webdev/Desktop/octopwnweb/code/projects/unicrypto/tests/test_des.py [assertion] pytest_pycollect_makeitem [hook] collector: name: @py_builtins obj: finish pytest_pycollect_makeitem --> None [hook] pytest_pycollect_makeitem [hook] collector: name: @pytest_ar obj: finish pytest_pycollect_makeitem --> None [hook] pytest_pycollect_makeitem [hook] collector: name: pytest obj: finish pytest_pycollect_makeitem --> None [hook] pytest_pycollect_makeitem [hook] collector: name: get_cipher_by_name obj: finish pytest_pycollect_makeitem --> None [hook] pytest_pycollect_makeitem [hook] collector: name: symmetric obj: finish pytest_pycollect_makeitem --> None [hook] pytest_pycollect_makeitem [hook] collector: name: des_ecb obj: [('0000000000000000', '0000000000000000', '8CA64DE9C1B123A7'), ('FFFFFFFFFFFFFFFF', 'FFFFFFFFFFFFFFFF', '7359B2163E4EDC58'), ('3000000000000000', '1000000000000001', '958E6E627A05557B'), ('1111111111111111', '1111111111111111', 'F40379AB9E0EC533'), ('0123456789ABCDEF', '1111111111111111', '17668DFC7292532D'), ('1111111111111111', '0123456789ABCDEF', '8A5AE1F81AB8F2DD'), ('FEDCBA9876543210', '0123456789ABCDEF', 'ED39D950FA74BCC4'), ('FEDCBA9876543210', '0123456789ABCDEF0123456789ABCDEF', 'ED39D950FA74BCC4ED39D950FA74BCC4')] finish pytest_pycollect_makeitem --> None [hook] pytest_pycollect_makeitem [hook] collector: name: des_cbc obj: [('0123456789abcdef', 'fedcba9876543210', '37363534333231204E6F77206973207468652074696D6520', 'ccd173ffab2039f4acd8aefddfd8a1eb468e91157888ba68')] finish pytest_pycollect_makeitem --> None [hook] pytest_pycollect_makeitem [hook] collector: name: ecb_enc obj: finish pytest_pycollect_makeitem --> None [hook] pytest_pycollect_makeitem [hook] collector: name: cbc_enc obj: finish pytest_pycollect_makeitem --> None [hook] pytest_pycollect_makeitem [hook] collector: name: test_ecb obj: pytest_generate_tests [hook] metafunc: <_pytest.python.Metafunc object at 0x7f1da2b280a0> pytest_make_parametrize_id [hook] config: <_pytest.config.Config object at 0x7f1da3c09270> val: argname: cipherobj finish pytest_make_parametrize_id --> None [hook] finish pytest_generate_tests --> [] [hook] finish pytest_pycollect_makeitem --> [] [hook] pytest_pycollect_makeitem [hook] collector: name: test_cbc obj: pytest_generate_tests [hook] metafunc: <_pytest.python.Metafunc object at 0x7f1da2b28160> pytest_make_parametrize_id [hook] config: <_pytest.config.Config object at 0x7f1da3c09270> val: argname: cipherobj finish pytest_make_parametrize_id --> None [hook] finish pytest_generate_tests --> [] [hook] finish pytest_pycollect_makeitem --> [] [hook] finish pytest_make_collect_report --> [hook] genitems [collection] pytest_itemcollected [hook] item: finish pytest_itemcollected --> [] [hook] genitems [collection] pytest_itemcollected [hook] item: finish pytest_itemcollected --> [] [hook] pytest_collectreport [hook] report: finish pytest_collectreport --> [] [hook] genitems [collection] pytest_collectstart [hook] collector: finish pytest_collectstart --> [] [hook] pytest_make_collect_report [hook] collector: find_module called for: tests.test_import [assertion] matched test file '/home/webdev/Desktop/octopwnweb/code/projects/unicrypto/tests/test_import.py' [assertion] found cached rewritten pyc for /home/webdev/Desktop/octopwnweb/code/projects/unicrypto/tests/test_import.py [assertion] pytest_pycollect_makeitem [hook] collector: name: @py_builtins obj: finish pytest_pycollect_makeitem --> None [hook] pytest_pycollect_makeitem [hook] collector: name: @pytest_ar obj: finish pytest_pycollect_makeitem --> None [hook] pytest_pycollect_makeitem [hook] collector: name: get_cipher_by_name obj: finish pytest_pycollect_makeitem --> None [hook] pytest_pycollect_makeitem [hook] collector: name: test_aes_mbedtls obj: pytest_generate_tests [hook] metafunc: <_pytest.python.Metafunc object at 0x7f1da2b2a440> finish pytest_generate_tests --> [] [hook] finish pytest_pycollect_makeitem --> [] [hook] pytest_pycollect_makeitem [hook] collector: name: test_aes_pycryptodome obj: pytest_generate_tests [hook] metafunc: <_pytest.python.Metafunc object at 0x7f1da2b28ee0> finish pytest_generate_tests --> [] [hook] finish pytest_pycollect_makeitem --> [] [hook] pytest_pycollect_makeitem [hook] collector: name: test_aes_cryptography obj: pytest_generate_tests [hook] metafunc: <_pytest.python.Metafunc object at 0x7f1da2b29ba0> finish pytest_generate_tests --> [] [hook] finish pytest_pycollect_makeitem --> [] [hook] pytest_pycollect_makeitem [hook] collector: name: test_aes_pure obj: pytest_generate_tests [hook] metafunc: <_pytest.python.Metafunc object at 0x7f1da2b28520> finish pytest_generate_tests --> [] [hook] finish pytest_pycollect_makeitem --> [] [hook] pytest_pycollect_makeitem [hook] collector: name: test_rc4_mbedtls obj: pytest_generate_tests [hook] metafunc: <_pytest.python.Metafunc object at 0x7f1da2b284c0> finish pytest_generate_tests --> [] [hook] finish pytest_pycollect_makeitem --> [] [hook] pytest_pycollect_makeitem [hook] collector: name: test_rc4_pycryptodome obj: pytest_generate_tests [hook] metafunc: <_pytest.python.Metafunc object at 0x7f1da2b28ac0> finish pytest_generate_tests --> [] [hook] finish pytest_pycollect_makeitem --> [] [hook] pytest_pycollect_makeitem [hook] collector: name: test_rc4_cryptography obj: pytest_generate_tests [hook] metafunc: <_pytest.python.Metafunc object at 0x7f1da2b29870> finish pytest_generate_tests --> [] [hook] finish pytest_pycollect_makeitem --> [] [hook] pytest_pycollect_makeitem [hook] collector: name: test_rc4_pure obj: pytest_generate_tests [hook] metafunc: <_pytest.python.Metafunc object at 0x7f1da2b29a50> finish pytest_generate_tests --> [] [hook] finish pytest_pycollect_makeitem --> [] [hook] pytest_pycollect_makeitem [hook] collector: name: test_rc4_pycryptodomex obj: pytest_generate_tests [hook] metafunc: <_pytest.python.Metafunc object at 0x7f1da2b29cc0> finish pytest_generate_tests --> [] [hook] finish pytest_pycollect_makeitem --> [] [hook] pytest_pycollect_makeitem [hook] collector: name: test_des_mbedtls obj: pytest_generate_tests [hook] metafunc: <_pytest.python.Metafunc object at 0x7f1da2b29db0> finish pytest_generate_tests --> [] [hook] finish pytest_pycollect_makeitem --> [] [hook] pytest_pycollect_makeitem [hook] collector: name: test_des_pycryptodome obj: pytest_generate_tests [hook] metafunc: <_pytest.python.Metafunc object at 0x7f1da2b29ea0> finish pytest_generate_tests --> [] [hook] finish pytest_pycollect_makeitem --> [] [hook] pytest_pycollect_makeitem [hook] collector: name: test_des_cryptography obj: pytest_generate_tests [hook] metafunc: <_pytest.python.Metafunc object at 0x7f1da2b29f90> finish pytest_generate_tests --> [] [hook] finish pytest_pycollect_makeitem --> [] [hook] pytest_pycollect_makeitem [hook] collector: name: test_des_pure obj: pytest_generate_tests [hook] metafunc: <_pytest.python.Metafunc object at 0x7f1da2b2a080> finish pytest_generate_tests --> [] [hook] finish pytest_pycollect_makeitem --> [] [hook] pytest_pycollect_makeitem [hook] collector: name: test_des_pycryptodomex obj: pytest_generate_tests [hook] metafunc: <_pytest.python.Metafunc object at 0x7f1da2b2a170> finish pytest_generate_tests --> [] [hook] finish pytest_pycollect_makeitem --> [] [hook] pytest_pycollect_makeitem [hook] collector: name: test_tdes_mbedtls obj: pytest_generate_tests [hook] metafunc: <_pytest.python.Metafunc object at 0x7f1da2b2a260> finish pytest_generate_tests --> [] [hook] finish pytest_pycollect_makeitem --> [] [hook] pytest_pycollect_makeitem [hook] collector: name: test_tdes_pycryptodome obj: pytest_generate_tests [hook] metafunc: <_pytest.python.Metafunc object at 0x7f1da2b29600> finish pytest_generate_tests --> [] [hook] finish pytest_pycollect_makeitem --> [] [hook] pytest_pycollect_makeitem [hook] collector: name: test_tdes_cryptography obj: pytest_generate_tests [hook] metafunc: <_pytest.python.Metafunc object at 0x7f1da2b2bc70> finish pytest_generate_tests --> [] [hook] finish pytest_pycollect_makeitem --> [] [hook] pytest_pycollect_makeitem [hook] collector: name: test_tdes_pure obj: pytest_generate_tests [hook] metafunc: <_pytest.python.Metafunc object at 0x7f1da2b2bb20> finish pytest_generate_tests --> [] [hook] finish pytest_pycollect_makeitem --> [] [hook] pytest_pycollect_makeitem [hook] collector: name: test_tdes_pycryptodomex obj: pytest_generate_tests [hook] metafunc: <_pytest.python.Metafunc object at 0x7f1da2b2b1f0> finish pytest_generate_tests --> [] [hook] finish pytest_pycollect_makeitem --> [] [hook] finish pytest_make_collect_report --> [hook] genitems [collection] pytest_itemcollected [hook] item: finish pytest_itemcollected --> [] [hook] genitems [collection] pytest_itemcollected [hook] item: finish pytest_itemcollected --> [] [hook] genitems [collection] pytest_itemcollected [hook] item: finish pytest_itemcollected --> [] [hook] genitems [collection] pytest_itemcollected [hook] item: finish pytest_itemcollected --> [] [hook] genitems [collection] pytest_itemcollected [hook] item: finish pytest_itemcollected --> [] [hook] genitems [collection] pytest_itemcollected [hook] item: finish pytest_itemcollected --> [] [hook] genitems [collection] pytest_itemcollected [hook] item: finish pytest_itemcollected --> [] [hook] genitems [collection] pytest_itemcollected [hook] item: finish pytest_itemcollected --> [] [hook] genitems [collection] pytest_itemcollected [hook] item: finish pytest_itemcollected --> [] [hook] genitems [collection] pytest_itemcollected [hook] item: finish pytest_itemcollected --> [] [hook] genitems [collection] pytest_itemcollected [hook] item: finish pytest_itemcollected --> [] [hook] genitems [collection] pytest_itemcollected [hook] item: finish pytest_itemcollected --> [] [hook] genitems [collection] pytest_itemcollected [hook] item: finish pytest_itemcollected --> [] [hook] genitems [collection] pytest_itemcollected [hook] item: finish pytest_itemcollected --> [] [hook] genitems [collection] pytest_itemcollected [hook] item: finish pytest_itemcollected --> [] [hook] genitems [collection] pytest_itemcollected [hook] item: finish pytest_itemcollected --> [] [hook] genitems [collection] pytest_itemcollected [hook] item: finish pytest_itemcollected --> [] [hook] genitems [collection] pytest_itemcollected [hook] item: finish pytest_itemcollected --> [] [hook] genitems [collection] pytest_itemcollected [hook] item: finish pytest_itemcollected --> [] [hook] pytest_collectreport [hook] report: finish pytest_collectreport --> [] [hook] genitems [collection] pytest_collectstart [hook] collector: finish pytest_collectstart --> [] [hook] pytest_make_collect_report [hook] collector: find_module called for: tests.test_pbkdf2 [assertion] matched test file '/home/webdev/Desktop/octopwnweb/code/projects/unicrypto/tests/test_pbkdf2.py' [assertion] found cached rewritten pyc for /home/webdev/Desktop/octopwnweb/code/projects/unicrypto/tests/test_pbkdf2.py [assertion] early skip of rewriting module: unicrypto.pbkdf2 [assertion] early skip of rewriting module: unicrypto.hmac [assertion] early skip of rewriting module: hmac [assertion] pytest_pycollect_makeitem [hook] collector: name: @py_builtins obj: finish pytest_pycollect_makeitem --> None [hook] pytest_pycollect_makeitem [hook] collector: name: @pytest_ar obj: finish pytest_pycollect_makeitem --> None [hook] pytest_pycollect_makeitem [hook] collector: name: pytest obj: finish pytest_pycollect_makeitem --> None [hook] pytest_pycollect_makeitem [hook] collector: name: hashlib obj: finish pytest_pycollect_makeitem --> None [hook] pytest_pycollect_makeitem [hook] collector: name: pbkdf2 obj: finish pytest_pycollect_makeitem --> None [hook] pytest_pycollect_makeitem [hook] collector: name: pbkdf2_sha1_test obj: [('password', 'salt', 1, 20, '0c60c80f961f0e71f3a9b524af6012062fe037a6'), ('password', 'salt', 2, 20, 'ea6c014dc72d6f8ccd1ed92ace1d41f0d8de8957'), ('password', 'salt', 4096, 20, '4b007901b765489abead49d926f721d065a429c1'), ('passwordPASSWORDpassword', 'saltSALTsaltSALTsaltSALTsaltSALTsalt', 4096, 25, '3d2eec4fe41c849b80c8d83662c0e44a8b291a964cf2f07038'), ('pass\x00word', 'sa\x00lt', 4096, 16, '56fa6aa75548099dcc37d7f03425e0c3')] finish pytest_pycollect_makeitem --> None [hook] pytest_pycollect_makeitem [hook] collector: name: pbkdf2_tester obj: finish pytest_pycollect_makeitem --> None [hook] pytest_pycollect_makeitem [hook] collector: name: test_sha1 obj: pytest_generate_tests [hook] metafunc: <_pytest.python.Metafunc object at 0x7f1da2b2ae90> finish pytest_generate_tests --> [] [hook] finish pytest_pycollect_makeitem --> [] [hook] finish pytest_make_collect_report --> [hook] genitems [collection] pytest_itemcollected [hook] item: finish pytest_itemcollected --> [] [hook] pytest_collectreport [hook] report: finish pytest_collectreport --> [] [hook] genitems [collection] pytest_collectstart [hook] collector: finish pytest_collectstart --> [] [hook] pytest_make_collect_report [hook] collector: find_module called for: tests.test_rc4 [assertion] matched test file '/home/webdev/Desktop/octopwnweb/code/projects/unicrypto/tests/test_rc4.py' [assertion] found cached rewritten pyc for /home/webdev/Desktop/octopwnweb/code/projects/unicrypto/tests/test_rc4.py [assertion] pytest_pycollect_makeitem [hook] collector: name: @py_builtins obj: finish pytest_pycollect_makeitem --> None [hook] pytest_pycollect_makeitem [hook] collector: name: @pytest_ar obj: finish pytest_pycollect_makeitem --> None [hook] pytest_pycollect_makeitem [hook] collector: name: pytest obj: finish pytest_pycollect_makeitem --> None [hook] pytest_pycollect_makeitem [hook] collector: name: get_cipher_by_name obj: finish pytest_pycollect_makeitem --> None [hook] pytest_pycollect_makeitem [hook] collector: name: symmetric obj: finish pytest_pycollect_makeitem --> None [hook] pytest_pycollect_makeitem [hook] collector: name: rc4_vectors obj: [('0102030405', '00', 'b2396305f03dc027ccc3524a0a1118a86982944f18fc82d589c403a47a0d091928cb1132c96ce286421dcaadb8b69eae1cfcf62b03eddb641d77dfcf7f8d8c9342b7d0cdd918a8a33dd51781c81f40416459844432a7da923cfb3eb4980661f6ec10327bde2beefd18f9277680457e22eb62638d4f0ba1fe9fca20e05bf8ff2b45129048e6a0ed0b56b490338f078da530abbcc7c20b01609f23ee2d5f6bb7df3294f744d8f9790507e70f62e5bbceead8729db41882259bee4f825325f5a1301eb14a0c13b3bf47fa2a0ba93ad45b8bcc582f8ba9f265e2b1be9112e975d2d7f2e30f9bd102ecbf75aaade9bc35c43cec0e11c479dc329dc8da7968fe965681068326a2118416d21f9d04b2cd1ca050ff25b58995996707e51fbdf08b34d875'), ('01020304050607', '00', '293f02d47f37c9b633f2af5285feb46be620f1390d19bd84e2e0fd752031afc1914f02531c9218810df60f67e338154cd0fdb583073ce85ab83917740ec011d575f81411e871cffa70b90c74c592e4540bb87202938dad609e87a5a1b079e5e4c2911246b612e7e7b903dfeda1dad86632828f91502b6291368de8081de36fc2f3b9a7e3b297bf9ad804512f9063eff18ecb67a9ba1f55a5a067e2b026a3676fd2aa902bd42d0d7cfd340cd45810529f78b272c96e42eab4c60bd914e39d06e3f4332fd31a079396ee3cee3f2a4ff04905459781d41fda7f30c1be7e1246c623adfd3868b8e51485d5e610017e3dd609ad26581c0c5be45f4cea01db2f3805d5f3172ceffc3b3d997c85ccd5af1a950ce74b0b9731227fd37c0ec08a47ddd8b8'), ('0102030405060708', '00', '97ab8a1bf0afb96132f2f67258da15a88263efdb45c4a18684ef87e6b19e5b099636ebc9841926f4f7d1f362bddf6e18d0a990ff2c05fef5b90373c9ff4b870a73239f1db7f41d80b643c0c52518ec63163b319923a6bdb4527c626126703c0f49d6c8af0f97144a87df21d91472f96644173a103b6616c5d5ad1cee40c863d0273c9c4b27f322e4e716ef53a47de7a4c6d0e7b226259fa9023490b26167ad1d1fe8986713f07c3d9ae1c163ff8cf9d38369e1a965610be887fbd0c79162aafb0a0127abb44484b9fbef5abcae1b579fc2cdadc6402e8ee866e1f37bdb47e42c26b51ea37df8e1d6f76fc3b66a7429b3bc7683205d4f443dc1f29dda3315c87bd5fa5a3469d29aaaf83d23589db8c85b3fb46e2c8f0f068edce8cdcd7dfc5862'), ('0102030405060708090a', '00', 'ede3b04643e586cc907dc2185170990203516ba78f413beb223aa5d4d2df67113cfd6cb58ee0fdde640176ad0000044d48532b21fb6079c9114c0ffd9c04a1ad3e8cea98017109979084b1ef92f99d86e20fb49bdb337ee48b8d8dc0f4afeffe5c2521eacd7966f15e056544bea0d315e067a7031931a246a6c3875d2f678acba64f70af88ae56b6f87581c0e23e6b08f449031de312814ec6f319291f4a0516bdae85924b3cb1d0a2e33a30c6d795998a0feddbac865a09bcd127fb562ed60ab55a0a5b51a12a8be34899c3e047511ad9a09cea3ce75fe39698070317a71339552225ed1177f44584ac8cfa6c4eb5fc7e82cbabfc95381b080998442129c2f81f135ed14ce60a91369d2322bef25e3c08b6be45124a43e2eb77953f84dc8553'), ('0102030405060708090a0b0c0d0e0f10', '00', '9ac7cc9a609d1ef7b2932899cde41b975248c4959014126a6e8a84f11d1a9e1c065902e4b620f6cc36c8589f66432f2bd39d566bc6bce3010768151549f3873fb6d1e6c4a5e4771cad79538df295fb11c68c1d5c559a974123df1dbc52a43b89c5ecf88de897fd57fed301701b82a259eccbe13de1fcc91c11a0b26c0bc8fa4de7a72574f8782ae26aabcf9ebcd66065bdf0324e6083dcc6d3cedd3ca8c53c16b40110c4190b5622a96116b0017ed297ffa0b514647ec04f6306b892ae661181d03d1bc03cd33d70dff9fa5d71963ebd8a44126411eaa78bd51e8d87a8879bf5fabeb76028ade2d0e48722e46c4615a3c05d88abd50357f935a63c59ee537623ff38265c1642c1abe8d3c2fe5e572bf8a36a4c301ae8ac13610ccbc12256cacc'), ('0102030405060708090a0b0c0d0e0f101112131415161718', '00', '0595e57fe5f0bb3c706edac8a4b2db11dfde31344a1af769c74f070aee9e2326b06b9b1e195d13d8f4a7995c4553ac056bd2378ec341c9a42f37ba79f88a32ffe70bce1df7645adb5d2c4130215c35229a5730c7fcb4c9af51ffda89c7f1ad220485055fd4f6f0d963ef5ab9a5476982591fc66bcda10e452b03d4551f6b62ac2753cc83988afa3e1688a1d3b42c9a0293610d523d1d3f0062b3c2a3bbc7c7f096c248610aadedfeaf8978c03de8205a0e317b3d1c73b9e9a4688f296d133a19bdf0e6c3cca5b5b9d533b69c56ada12088a218b6e2ece1e6246d44c759d19b106866397e95c140534f94263421006e4032cb0a1e9542c6b3b8b398abc3b0f1d529a0b8aed54a132324c62e423f54b4c83cb0f3b5020a98b82af9fe154484a168'), ('0102030405060708090a0b0c0d0e0f101112131415161718191a1b1c1d1e1f20', '00', 'eaa6bd25880bf93d3f5d1e4ca2611d91cfa45c9f7e714b54bdfa80027cb14380114ae344ded71b35f2e60febad727fd802e1e7056b0f623900496422943e97b691cb93c787964e10d9527d999c6f936b49b18b42f8e8367cbeb5ef104ba1c7cd87084b3ba700bade955610672745b374e7a7b9e9ec540d5ff43bdb12792d1b35c799b596738f6b018c76c74b1759bd907fec5bfd9f9b89ce6548309092d7e95840f250b26d1f096a4afd4c340a5888153e34135c79db010200767651cf263073f656abccf88dd827027b2ce917d464ec18b62503bfbc077fbabb98f20d98ab348aed95ee5b0dcbfbef4eb21d3a3f52f9625a1ab00ee39a5327346bddb01a9c18a13a7c79c7e119b5ab0296ab28c300b9f3e4c0a2e02d1d01f7f0a74618af2b48'), ('833222772a', '00', '80ad97bdc973df8a2e879e92a497efda20f060c2f2e5126501d3d4fea10d5fc0faa148e99046181fec6b2085f3b20ed9f0daf5bab3d596839857846f73fbfe5a1c7e2fc4639232fe297584b296996bc83db9b249406cc8edffac55ccd322ba12e4f9f7e0066154bbd125b745569bc89775d5ef262b44c41a9cf63ae14568e1b96da453dbf81e82334a3d8866cb50a1e37828d074119cab5c22b294d7a9bfa0bbadb89cea9a15fbe617295bd04b8ca05c6251d87fd4aaae9a7e4ad5c217d3f300e7119bd6dd9b22afe8f89585432881e2785b60fd7ec4e9fcb6545f350d660fabafecc037fdb7b0838eb3d70bcd268382dbc1a7b49d57358cc9fa6d61d73b7cf06349d126a37afcba89794f9804914fdcbf42c3018c2f7c66bfde524975768115'), ('1910833222772a', '00', 'bc9222dbd3274d8fc66d14ccbda6690b7ae627410c9a2be693df5bb7485a63e33f0931aa03defb300f060103826f2a64beaa9ec8d59bb68129f3027c9636118174e04db46d28648d7dee8a0064b06cfe9b5e81c62fe023c55be42f87bbf932b8ce178fc1826efecbc182f57999a461408bdf55cd55061c06dba6be11de4a578a626f5f4dce652501f3087d39c92cc34942daac6a8f9ab9a7fd137c6037825682cc03fdb79192a207312f53f5d4dc33d9f70f14122a1c98a3155d28b8a0a8a41d2a3a307ab2708a9c00fe0b42f9c2d6a1862617627d2261eab0b1246597ca0ae955f877ce4f2e1ddbbf8e13e2cde0fdc81b1556cb935f173337705fbb5d501fc1ecd0e96602be7f8d5092816cccf2c2e9027881fab4993a1c262024a94fff3f61'), ('641910833222772a', '00', 'bbf609de9413172d07660cb68071692646101a6dab43115d6c522b4fe93604a9cbe1fff21c96f3eef61e8fe0542cbdf0347938bffa4009c512cfb4034b0dd1a77867a786d00a7147904d76ddf1e520e38d3e9e1caefcccb3fbf8d18f64120b32942337f8fd76f0fae8c52d7954810672b8548c10f51667f6e60e182fa19b30f70211c7c6190c9efd1237c34c8f2e06c4bda64f65276d2aacb8f90212203a808ebd3820f732ffb53ec193e79d33e27c73d0168616861907d482e36cdac8cf574997b0f0f224b2d2317114808fb03af7a0e59616e469787939a063ceea9af956d1c47e0dc1660919c11101208f9e69aa1f5ae4f12896b8379a2aad89b5b553d6b06b6b098d0c293bc2993d80bf0518b6d98170cc3ccd92a698621b939dd38fe7b9'), ('8b37641910833222772a', '00', 'ab65c26eddb287600db2fda10d1e605cbb759010c29658f2c72d93a2d16d2930b901e8036ed1c383cd3c4c4dd0a6ab053d25ce4922924c55f064943353d78a6c12c1aa44bbf87e75e611f69b2c38f49b28f2b3434b65c09877470044c6ea170dbd9ef822de5288196134cf8af783930467559c23f052158470a296f725735a328bab26fbc2c12b0f13e2ab185eabf24131185a6d696f0cfa9b42808b38e132a2564d3dae183c5234c8af1e51061c44b53c0778a7b5f72d3c23a3135c7d67b9f4f34369890fcf16fb517dcaae4463b2dd02f31c81e8200731b899b028e791bfa772da646283228c14300853701795616f4e0a8c6f7934a788e2265e81d6d0c8f4438dd5eafea0111b6f36b4b938da2a685f6bfc73815874d97100f086979357d8'), ('ebb46227c6cc8b37641910833222772a', '00', '720c94b63edf44e131d950ca211a5a30c366fdeacf9ca80436be7c358424d20bb3394a40aabf75cba42282ef25a0059f4847d81da4942dbc249defc48c922b9f08128c469f275342adda202b2b58da95970dacef40ad98723bac5d6955b817613cb89993b07b0ced93de13d2a11013acef2d676f1545c2c13dc680a02f4adbfeb60595514f24bc9fe522a6cad7393644b515a8c5011754f59003058bdb81514e3c70047e8cbc038e3b9820db601da4951175da6ee756de46a53e2b075660b77000a542bba02111cc2c65b38ebdba587e5865fdbb5b48064104e830b380f2aede34b21ad2ad44e999db2d7f0863f0d9b684a9218fc36e8a5f2ccfbeae53a27d25a2221a11b833ccb498a59540f0545f4a5bbeb4787d59e5373fdbea6c6f75c29b'), ('c109163908ebe51debb46227c6cc8b37641910833222772a', '00', '54b64e6b5a20b5e2ec84593dc7989da7c135eee237a85465ff97dc03924f45cecfcc922fb4a14ab45d6175aabbf2d201837b87e2a446ad0ef798acd02b94124f17a6dbd664926a0636b3f4c37a4f46944a5f9f26aeeed4d4a25f632d305233d980a3d01ef00c8e9a4209c17f4eeb358cd15e7d5ffaaabc0207bf200a117793a2349682bf588eaa52d0aa1560346aeafaf5854cdb76c889e3ad63354e5f7275e3532c7ceccb39df3236318405a4b1279cbaefe6d9ceb651842260e0d1e05e3b90e82d8c6db54e3c633f581c952ba042074b16e50abd381bd70900a9cd9a62cb233682ee33bd148bd9f58656cd8f30d9fb1e5a0b8475045d9b20b2628624edfd9e63edd684fb826282fe528f9c0e9237bce4dd2e98d6960fae0b43545456743391'), ('1ada31d5cf688221c109163908ebe51debb46227c6cc8b37641910833222772a', '00', 'dd5bcb0018e922d494759d7c395d02d3c8446f8f77abf737685353eb89a1c9ebaf3e30f9c095045938151575c3fb9098f8cb6274db99b80b1d2012a98ed48f0e25c3005a1cb85de076259839ab7198ab9dcbc183e8cb994b727b75be3180769ca1d3078dfa9169503ed9d4491dee4eb28514a5495858096f596e4bcd66b106655f40d59ec1b03b33738efa60b2255d313477c7f764a41baceff90bf14f92b7ccac4e95368d99b9eb78b8da8f81ffa7958c3c13f8c2388bb73f38576e65b7c44613c4b9c1dfb66579eddd8a280b9f7316ddd27820550126698efaadc64b64f66ef08f2e66d28ed143f3a237cf9de735599ea36c525531b880ba124334f57b0b70d5a39e3dfcc50280bac4a6b5aa0dca7d370b1c1fe655916d97fd0d47ca1d72b8')] finish pytest_pycollect_makeitem --> None [hook] pytest_pycollect_makeitem [hook] collector: name: rc4_segments obj: [0, 16, 240, 256, 496, 512, 752, 768, 1008, 1024, 1520, 1536, 2032, 2048, 3056, 3072, 4080, 4096] finish pytest_pycollect_makeitem --> None [hook] pytest_pycollect_makeitem [hook] collector: name: rc4_enc obj: finish pytest_pycollect_makeitem --> None [hook] pytest_pycollect_makeitem [hook] collector: name: test_rc4 obj: pytest_generate_tests [hook] metafunc: <_pytest.python.Metafunc object at 0x7f1da2b2b760> pytest_make_parametrize_id [hook] config: <_pytest.config.Config object at 0x7f1da3c09270> val: argname: cipherobj finish pytest_make_parametrize_id --> None [hook] finish pytest_generate_tests --> [] [hook] finish pytest_pycollect_makeitem --> [] [hook] finish pytest_make_collect_report --> [hook] genitems [collection] pytest_itemcollected [hook] item: finish pytest_itemcollected --> [] [hook] pytest_collectreport [hook] report: finish pytest_collectreport --> [] [hook] genitems [collection] pytest_collectstart [hook] collector: finish pytest_collectstart --> [] [hook] pytest_make_collect_report [hook] collector: find_module called for: tests.test_tdes [assertion] matched test file '/home/webdev/Desktop/octopwnweb/code/projects/unicrypto/tests/test_tdes.py' [assertion] found cached rewritten pyc for /home/webdev/Desktop/octopwnweb/code/projects/unicrypto/tests/test_tdes.py [assertion] pytest_pycollect_makeitem [hook] collector: name: @py_builtins obj: finish pytest_pycollect_makeitem --> None [hook] pytest_pycollect_makeitem [hook] collector: name: @pytest_ar obj: finish pytest_pycollect_makeitem --> None [hook] pytest_pycollect_makeitem [hook] collector: name: pytest obj: finish pytest_pycollect_makeitem --> None [hook] pytest_pycollect_makeitem [hook] collector: name: get_cipher_by_name obj: finish pytest_pycollect_makeitem --> None [hook] pytest_pycollect_makeitem [hook] collector: name: symmetric obj: finish pytest_pycollect_makeitem --> None [hook] pytest_pycollect_makeitem [hook] collector: name: tdes_ecb obj: [('000102030405060708090A0B0C0D0E0F1011121314151617', '982662605553244D', '0011223344556677')] finish pytest_pycollect_makeitem --> None [hook] pytest_pycollect_makeitem [hook] collector: name: tdes_cbc obj: [('0123456789abcdeff1e0d3c2b5a49786fedcba9876543210', 'fedcba9876543210', '37363534333231204E6F77206973207468652074696D6520666F722000000000', '3FE301C962AC01D02213763C1CBD4CDC799657C064ECF5D41C673812CFDE9675')] finish pytest_pycollect_makeitem --> None [hook] pytest_pycollect_makeitem [hook] collector: name: ecb_enc obj: finish pytest_pycollect_makeitem --> None [hook] pytest_pycollect_makeitem [hook] collector: name: cbc_enc obj: finish pytest_pycollect_makeitem --> None [hook] pytest_pycollect_makeitem [hook] collector: name: test_ecb obj: pytest_generate_tests [hook] metafunc: <_pytest.python.Metafunc object at 0x7f1da2b2ba60> pytest_make_parametrize_id [hook] config: <_pytest.config.Config object at 0x7f1da3c09270> val: argname: cipherobj finish pytest_make_parametrize_id --> None [hook] finish pytest_generate_tests --> [] [hook] finish pytest_pycollect_makeitem --> [] [hook] pytest_pycollect_makeitem [hook] collector: name: test_cbc obj: pytest_generate_tests [hook] metafunc: <_pytest.python.Metafunc object at 0x7f1da2b291e0> pytest_make_parametrize_id [hook] config: <_pytest.config.Config object at 0x7f1da3c09270> val: argname: cipherobj finish pytest_make_parametrize_id --> None [hook] finish pytest_generate_tests --> [] [hook] finish pytest_pycollect_makeitem --> [] [hook] finish pytest_make_collect_report --> [hook] genitems [collection] pytest_itemcollected [hook] item: finish pytest_itemcollected --> [] [hook] genitems [collection] pytest_itemcollected [hook] item: finish pytest_itemcollected --> [] [hook] pytest_collectreport [hook] report: finish pytest_collectreport --> [] [hook] pytest_collectreport [hook] report: finish pytest_collectreport --> [] [hook] pytest_collection_modifyitems [hook] session: testsfailed=0 testscollected=0> config: <_pytest.config.Config object at 0x7f1da3c09270> items: [, , , , , , , , , , , , , , , , , , , , , , , , , , , , , , , , , , , , , , , , , , , , , , , , ] finish pytest_collection_modifyitems --> [] [hook] pytest_collection_finish [hook] session: testsfailed=0 testscollected=0> pytest_report_collectionfinish [hook] config: <_pytest.config.Config object at 0x7f1da3c09270> items: [, , , , , , , , , , , , , , , , , , , , , , , , , , , , , , , , , , , , , , , , , , , , , , , , ] start_path: /home/webdev/Desktop/octopwnweb/code/projects/unicrypto/tests startdir: /home/webdev/Desktop/octopwnweb/code/projects/unicrypto/tests finish pytest_report_collectionfinish --> [] [hook] finish pytest_collection_finish --> [] [hook] finish pytest_collection --> None [hook] pytest_runtestloop [hook] session: testsfailed=0 testscollected=49> pytest_runtest_protocol [hook] item: nextitem: pytest_runtest_logstart [hook] nodeid: tests/test_aes.py::test_ecb_128[AES] location: ('tests/test_aes.py', 843, 'test_ecb_128[AES]') finish pytest_runtest_logstart --> [] [hook] pytest_runtest_setup [hook] item: pytest_fixture_setup [hook] fixturedef: request: > finish pytest_fixture_setup --> [hook] finish pytest_runtest_setup --> [] [hook] pytest_runtest_makereport [hook] item: call: finish pytest_runtest_makereport --> [hook] pytest_runtest_logreport [hook] report: pytest_report_teststatus [hook] report: config: <_pytest.config.Config object at 0x7f1da3c09270> finish pytest_report_teststatus --> ('', '', '') [hook] finish pytest_runtest_logreport --> [] [hook] pytest_runtest_call [hook] item: pytest_pyfunc_call [hook] pyfuncitem: finish pytest_pyfunc_call --> True [hook] finish pytest_runtest_call --> [] [hook] pytest_runtest_makereport [hook] item: call: finish pytest_runtest_makereport --> [hook] pytest_runtest_logreport [hook] report: pytest_report_teststatus [hook] report: config: <_pytest.config.Config object at 0x7f1da3c09270> finish pytest_report_teststatus --> ('passed', '.', 'PASSED') [hook] finish pytest_runtest_logreport --> [] [hook] pytest_runtest_teardown [hook] item: nextitem: pytest_fixture_post_finalizer [hook] fixturedef: request: > finish pytest_fixture_post_finalizer --> [] [hook] finish pytest_runtest_teardown --> [] [hook] pytest_runtest_makereport [hook] item: call: finish pytest_runtest_makereport --> [hook] pytest_runtest_logreport [hook] report: pytest_report_teststatus [hook] report: config: <_pytest.config.Config object at 0x7f1da3c09270> finish pytest_report_teststatus --> ('', '', '') [hook] finish pytest_runtest_logreport --> [] [hook] pytest_runtest_logfinish [hook] nodeid: tests/test_aes.py::test_ecb_128[AES] location: ('tests/test_aes.py', 843, 'test_ecb_128[AES]') finish pytest_runtest_logfinish --> [] [hook] finish pytest_runtest_protocol --> True [hook] pytest_runtest_protocol [hook] item: nextitem: pytest_runtest_logstart [hook] nodeid: tests/test_aes.py::test_ecb_192[AES] location: ('tests/test_aes.py', 847, 'test_ecb_192[AES]') finish pytest_runtest_logstart --> [] [hook] pytest_runtest_setup [hook] item: pytest_fixture_setup [hook] fixturedef: request: > finish pytest_fixture_setup --> [hook] finish pytest_runtest_setup --> [] [hook] pytest_runtest_makereport [hook] item: call: finish pytest_runtest_makereport --> [hook] pytest_runtest_logreport [hook] report: pytest_report_teststatus [hook] report: config: <_pytest.config.Config object at 0x7f1da3c09270> finish pytest_report_teststatus --> ('', '', '') [hook] finish pytest_runtest_logreport --> [] [hook] pytest_runtest_call [hook] item: pytest_pyfunc_call [hook] pyfuncitem: finish pytest_pyfunc_call --> True [hook] finish pytest_runtest_call --> [] [hook] pytest_runtest_makereport [hook] item: call: finish pytest_runtest_makereport --> [hook] pytest_runtest_logreport [hook] report: pytest_report_teststatus [hook] report: config: <_pytest.config.Config object at 0x7f1da3c09270> finish pytest_report_teststatus --> ('passed', '.', 'PASSED') [hook] finish pytest_runtest_logreport --> [] [hook] pytest_runtest_teardown [hook] item: nextitem: pytest_fixture_post_finalizer [hook] fixturedef: request: > finish pytest_fixture_post_finalizer --> [] [hook] finish pytest_runtest_teardown --> [] [hook] pytest_runtest_makereport [hook] item: call: finish pytest_runtest_makereport --> [hook] pytest_runtest_logreport [hook] report: pytest_report_teststatus [hook] report: config: <_pytest.config.Config object at 0x7f1da3c09270> finish pytest_report_teststatus --> ('', '', '') [hook] finish pytest_runtest_logreport --> [] [hook] pytest_runtest_logfinish [hook] nodeid: tests/test_aes.py::test_ecb_192[AES] location: ('tests/test_aes.py', 847, 'test_ecb_192[AES]') finish pytest_runtest_logfinish --> [] [hook] finish pytest_runtest_protocol --> True [hook] pytest_runtest_protocol [hook] item: nextitem: pytest_runtest_logstart [hook] nodeid: tests/test_aes.py::test_ecb_256[AES] location: ('tests/test_aes.py', 851, 'test_ecb_256[AES]') finish pytest_runtest_logstart --> [] [hook] pytest_runtest_setup [hook] item: pytest_fixture_setup [hook] fixturedef: request: > finish pytest_fixture_setup --> [hook] finish pytest_runtest_setup --> [] [hook] pytest_runtest_makereport [hook] item: call: finish pytest_runtest_makereport --> [hook] pytest_runtest_logreport [hook] report: pytest_report_teststatus [hook] report: config: <_pytest.config.Config object at 0x7f1da3c09270> finish pytest_report_teststatus --> ('', '', '') [hook] finish pytest_runtest_logreport --> [] [hook] pytest_runtest_call [hook] item: pytest_pyfunc_call [hook] pyfuncitem: finish pytest_pyfunc_call --> True [hook] finish pytest_runtest_call --> [] [hook] pytest_runtest_makereport [hook] item: call: finish pytest_runtest_makereport --> [hook] pytest_runtest_logreport [hook] report: pytest_report_teststatus [hook] report: config: <_pytest.config.Config object at 0x7f1da3c09270> finish pytest_report_teststatus --> ('passed', '.', 'PASSED') [hook] finish pytest_runtest_logreport --> [] [hook] pytest_runtest_teardown [hook] item: nextitem: pytest_fixture_post_finalizer [hook] fixturedef: request: > finish pytest_fixture_post_finalizer --> [] [hook] finish pytest_runtest_teardown --> [] [hook] pytest_runtest_makereport [hook] item: call: finish pytest_runtest_makereport --> [hook] pytest_runtest_logreport [hook] report: pytest_report_teststatus [hook] report: config: <_pytest.config.Config object at 0x7f1da3c09270> finish pytest_report_teststatus --> ('', '', '') [hook] finish pytest_runtest_logreport --> [] [hook] pytest_runtest_logfinish [hook] nodeid: tests/test_aes.py::test_ecb_256[AES] location: ('tests/test_aes.py', 851, 'test_ecb_256[AES]') finish pytest_runtest_logfinish --> [] [hook] finish pytest_runtest_protocol --> True [hook] pytest_runtest_protocol [hook] item: nextitem: pytest_runtest_logstart [hook] nodeid: tests/test_aes.py::test_ecb_long[AES] location: ('tests/test_aes.py', 855, 'test_ecb_long[AES]') finish pytest_runtest_logstart --> [] [hook] pytest_runtest_setup [hook] item: pytest_fixture_setup [hook] fixturedef: request: > finish pytest_fixture_setup --> [hook] finish pytest_runtest_setup --> [] [hook] pytest_runtest_makereport [hook] item: call: finish pytest_runtest_makereport --> [hook] pytest_runtest_logreport [hook] report: pytest_report_teststatus [hook] report: config: <_pytest.config.Config object at 0x7f1da3c09270> finish pytest_report_teststatus --> ('', '', '') [hook] finish pytest_runtest_logreport --> [] [hook] pytest_runtest_call [hook] item: pytest_pyfunc_call [hook] pyfuncitem: finish pytest_pyfunc_call --> True [hook] finish pytest_runtest_call --> [] [hook] pytest_runtest_makereport [hook] item: call: finish pytest_runtest_makereport --> [hook] pytest_runtest_logreport [hook] report: pytest_report_teststatus [hook] report: config: <_pytest.config.Config object at 0x7f1da3c09270> finish pytest_report_teststatus --> ('passed', '.', 'PASSED') [hook] finish pytest_runtest_logreport --> [] [hook] pytest_runtest_teardown [hook] item: nextitem: pytest_fixture_post_finalizer [hook] fixturedef: request: > finish pytest_fixture_post_finalizer --> [] [hook] finish pytest_runtest_teardown --> [] [hook] pytest_runtest_makereport [hook] item: call: finish pytest_runtest_makereport --> [hook] pytest_runtest_logreport [hook] report: pytest_report_teststatus [hook] report: config: <_pytest.config.Config object at 0x7f1da3c09270> finish pytest_report_teststatus --> ('', '', '') [hook] finish pytest_runtest_logreport --> [] [hook] pytest_runtest_logfinish [hook] nodeid: tests/test_aes.py::test_ecb_long[AES] location: ('tests/test_aes.py', 855, 'test_ecb_long[AES]') finish pytest_runtest_logfinish --> [] [hook] finish pytest_runtest_protocol --> True [hook] pytest_runtest_protocol [hook] item: nextitem: pytest_runtest_logstart [hook] nodeid: tests/test_aes.py::test_cbc_128[AES] location: ('tests/test_aes.py', 859, 'test_cbc_128[AES]') finish pytest_runtest_logstart --> [] [hook] pytest_runtest_setup [hook] item: pytest_fixture_setup [hook] fixturedef: request: > finish pytest_fixture_setup --> [hook] finish pytest_runtest_setup --> [] [hook] pytest_runtest_makereport [hook] item: call: finish pytest_runtest_makereport --> [hook] pytest_runtest_logreport [hook] report: pytest_report_teststatus [hook] report: config: <_pytest.config.Config object at 0x7f1da3c09270> finish pytest_report_teststatus --> ('', '', '') [hook] finish pytest_runtest_logreport --> [] [hook] pytest_runtest_call [hook] item: pytest_pyfunc_call [hook] pyfuncitem: finish pytest_pyfunc_call --> True [hook] finish pytest_runtest_call --> [] [hook] pytest_runtest_makereport [hook] item: call: finish pytest_runtest_makereport --> [hook] pytest_runtest_logreport [hook] report: pytest_report_teststatus [hook] report: config: <_pytest.config.Config object at 0x7f1da3c09270> finish pytest_report_teststatus --> ('passed', '.', 'PASSED') [hook] finish pytest_runtest_logreport --> [] [hook] pytest_runtest_teardown [hook] item: nextitem: pytest_fixture_post_finalizer [hook] fixturedef: request: > finish pytest_fixture_post_finalizer --> [] [hook] finish pytest_runtest_teardown --> [] [hook] pytest_runtest_makereport [hook] item: call: finish pytest_runtest_makereport --> [hook] pytest_runtest_logreport [hook] report: pytest_report_teststatus [hook] report: config: <_pytest.config.Config object at 0x7f1da3c09270> finish pytest_report_teststatus --> ('', '', '') [hook] finish pytest_runtest_logreport --> [] [hook] pytest_runtest_logfinish [hook] nodeid: tests/test_aes.py::test_cbc_128[AES] location: ('tests/test_aes.py', 859, 'test_cbc_128[AES]') finish pytest_runtest_logfinish --> [] [hook] finish pytest_runtest_protocol --> True [hook] pytest_runtest_protocol [hook] item: nextitem: pytest_runtest_logstart [hook] nodeid: tests/test_aes.py::test_cbc_192[AES] location: ('tests/test_aes.py', 863, 'test_cbc_192[AES]') finish pytest_runtest_logstart --> [] [hook] pytest_runtest_setup [hook] item: pytest_fixture_setup [hook] fixturedef: request: > finish pytest_fixture_setup --> [hook] finish pytest_runtest_setup --> [] [hook] pytest_runtest_makereport [hook] item: call: finish pytest_runtest_makereport --> [hook] pytest_runtest_logreport [hook] report: pytest_report_teststatus [hook] report: config: <_pytest.config.Config object at 0x7f1da3c09270> finish pytest_report_teststatus --> ('', '', '') [hook] finish pytest_runtest_logreport --> [] [hook] pytest_runtest_call [hook] item: pytest_pyfunc_call [hook] pyfuncitem: finish pytest_pyfunc_call --> True [hook] finish pytest_runtest_call --> [] [hook] pytest_runtest_makereport [hook] item: call: finish pytest_runtest_makereport --> [hook] pytest_runtest_logreport [hook] report: pytest_report_teststatus [hook] report: config: <_pytest.config.Config object at 0x7f1da3c09270> finish pytest_report_teststatus --> ('passed', '.', 'PASSED') [hook] finish pytest_runtest_logreport --> [] [hook] pytest_runtest_teardown [hook] item: nextitem: pytest_fixture_post_finalizer [hook] fixturedef: request: > finish pytest_fixture_post_finalizer --> [] [hook] finish pytest_runtest_teardown --> [] [hook] pytest_runtest_makereport [hook] item: call: finish pytest_runtest_makereport --> [hook] pytest_runtest_logreport [hook] report: pytest_report_teststatus [hook] report: config: <_pytest.config.Config object at 0x7f1da3c09270> finish pytest_report_teststatus --> ('', '', '') [hook] finish pytest_runtest_logreport --> [] [hook] pytest_runtest_logfinish [hook] nodeid: tests/test_aes.py::test_cbc_192[AES] location: ('tests/test_aes.py', 863, 'test_cbc_192[AES]') finish pytest_runtest_logfinish --> [] [hook] finish pytest_runtest_protocol --> True [hook] pytest_runtest_protocol [hook] item: nextitem: pytest_runtest_logstart [hook] nodeid: tests/test_aes.py::test_cbc_256[AES] location: ('tests/test_aes.py', 867, 'test_cbc_256[AES]') finish pytest_runtest_logstart --> [] [hook] pytest_runtest_setup [hook] item: pytest_fixture_setup [hook] fixturedef: request: > finish pytest_fixture_setup --> [hook] finish pytest_runtest_setup --> [] [hook] pytest_runtest_makereport [hook] item: call: finish pytest_runtest_makereport --> [hook] pytest_runtest_logreport [hook] report: pytest_report_teststatus [hook] report: config: <_pytest.config.Config object at 0x7f1da3c09270> finish pytest_report_teststatus --> ('', '', '') [hook] finish pytest_runtest_logreport --> [] [hook] pytest_runtest_call [hook] item: pytest_pyfunc_call [hook] pyfuncitem: finish pytest_pyfunc_call --> True [hook] finish pytest_runtest_call --> [] [hook] pytest_runtest_makereport [hook] item: call: finish pytest_runtest_makereport --> [hook] pytest_runtest_logreport [hook] report: pytest_report_teststatus [hook] report: config: <_pytest.config.Config object at 0x7f1da3c09270> finish pytest_report_teststatus --> ('passed', '.', 'PASSED') [hook] finish pytest_runtest_logreport --> [] [hook] pytest_runtest_teardown [hook] item: nextitem: pytest_fixture_post_finalizer [hook] fixturedef: request: > finish pytest_fixture_post_finalizer --> [] [hook] finish pytest_runtest_teardown --> [] [hook] pytest_runtest_makereport [hook] item: call: finish pytest_runtest_makereport --> [hook] pytest_runtest_logreport [hook] report: pytest_report_teststatus [hook] report: config: <_pytest.config.Config object at 0x7f1da3c09270> finish pytest_report_teststatus --> ('', '', '') [hook] finish pytest_runtest_logreport --> [] [hook] pytest_runtest_logfinish [hook] nodeid: tests/test_aes.py::test_cbc_256[AES] location: ('tests/test_aes.py', 867, 'test_cbc_256[AES]') finish pytest_runtest_logfinish --> [] [hook] finish pytest_runtest_protocol --> True [hook] pytest_runtest_protocol [hook] item: nextitem: pytest_runtest_logstart [hook] nodeid: tests/test_aes.py::test_cbc_long[AES] location: ('tests/test_aes.py', 871, 'test_cbc_long[AES]') finish pytest_runtest_logstart --> [] [hook] pytest_runtest_setup [hook] item: pytest_fixture_setup [hook] fixturedef: request: > finish pytest_fixture_setup --> [hook] finish pytest_runtest_setup --> [] [hook] pytest_runtest_makereport [hook] item: call: finish pytest_runtest_makereport --> [hook] pytest_runtest_logreport [hook] report: pytest_report_teststatus [hook] report: config: <_pytest.config.Config object at 0x7f1da3c09270> finish pytest_report_teststatus --> ('', '', '') [hook] finish pytest_runtest_logreport --> [] [hook] pytest_runtest_call [hook] item: pytest_pyfunc_call [hook] pyfuncitem: finish pytest_pyfunc_call --> True [hook] finish pytest_runtest_call --> [] [hook] pytest_runtest_makereport [hook] item: call: finish pytest_runtest_makereport --> [hook] pytest_runtest_logreport [hook] report: pytest_report_teststatus [hook] report: config: <_pytest.config.Config object at 0x7f1da3c09270> finish pytest_report_teststatus --> ('passed', '.', 'PASSED') [hook] finish pytest_runtest_logreport --> [] [hook] pytest_runtest_teardown [hook] item: nextitem: pytest_fixture_post_finalizer [hook] fixturedef: request: > finish pytest_fixture_post_finalizer --> [] [hook] finish pytest_runtest_teardown --> [] [hook] pytest_runtest_makereport [hook] item: call: finish pytest_runtest_makereport --> [hook] pytest_runtest_logreport [hook] report: pytest_report_teststatus [hook] report: config: <_pytest.config.Config object at 0x7f1da3c09270> finish pytest_report_teststatus --> ('', '', '') [hook] finish pytest_runtest_logreport --> [] [hook] pytest_runtest_logfinish [hook] nodeid: tests/test_aes.py::test_cbc_long[AES] location: ('tests/test_aes.py', 871, 'test_cbc_long[AES]') finish pytest_runtest_logfinish --> [] [hook] finish pytest_runtest_protocol --> True [hook] pytest_runtest_protocol [hook] item: nextitem: pytest_runtest_logstart [hook] nodeid: tests/test_aes.py::test_cfb_fb1[AES] location: ('tests/test_aes.py', 778, 'test_cfb_fb1[AES]') finish pytest_runtest_logstart --> [] [hook] pytest_runtest_setup [hook] item: pytest_fixture_setup [hook] fixturedef: request: > finish pytest_fixture_setup --> [hook] finish pytest_runtest_setup --> [] [hook] pytest_runtest_makereport [hook] item: call: finish pytest_runtest_makereport --> [hook] pytest_runtest_logreport [hook] report: pytest_report_teststatus [hook] report: config: <_pytest.config.Config object at 0x7f1da3c09270> finish pytest_report_teststatus --> ('', '', '') [hook] finish pytest_runtest_logreport --> [] [hook] pytest_runtest_call [hook] item: pytest_pyfunc_call [hook] pyfuncitem: finish pytest_pyfunc_call --> True [hook] finish pytest_runtest_call --> [] [hook] pytest_runtest_makereport [hook] item: call: finish pytest_runtest_makereport --> [hook] pytest_runtest_logreport [hook] report: pytest_report_teststatus [hook] report: config: <_pytest.config.Config object at 0x7f1da3c09270> finish pytest_report_teststatus --> ('passed', '.', 'PASSED') [hook] finish pytest_runtest_logreport --> [] [hook] pytest_runtest_teardown [hook] item: nextitem: pytest_fixture_post_finalizer [hook] fixturedef: request: > finish pytest_fixture_post_finalizer --> [] [hook] finish pytest_runtest_teardown --> [] [hook] pytest_runtest_makereport [hook] item: call: finish pytest_runtest_makereport --> [hook] pytest_runtest_logreport [hook] report: pytest_report_teststatus [hook] report: config: <_pytest.config.Config object at 0x7f1da3c09270> finish pytest_report_teststatus --> ('', '', '') [hook] finish pytest_runtest_logreport --> [] [hook] pytest_runtest_logfinish [hook] nodeid: tests/test_aes.py::test_cfb_fb1[AES] location: ('tests/test_aes.py', 778, 'test_cfb_fb1[AES]') finish pytest_runtest_logfinish --> [] [hook] finish pytest_runtest_protocol --> True [hook] pytest_runtest_protocol [hook] item: nextitem: pytest_runtest_logstart [hook] nodeid: tests/test_aes.py::test_cfb_128_fb16[AES] location: ('tests/test_aes.py', 879, 'test_cfb_128_fb16[AES]') finish pytest_runtest_logstart --> [] [hook] pytest_runtest_setup [hook] item: pytest_fixture_setup [hook] fixturedef: request: > finish pytest_fixture_setup --> [hook] finish pytest_runtest_setup --> [] [hook] pytest_runtest_makereport [hook] item: call: finish pytest_runtest_makereport --> [hook] pytest_runtest_logreport [hook] report: pytest_report_teststatus [hook] report: config: <_pytest.config.Config object at 0x7f1da3c09270> finish pytest_report_teststatus --> ('', '', '') [hook] finish pytest_runtest_logreport --> [] [hook] pytest_runtest_call [hook] item: pytest_pyfunc_call [hook] pyfuncitem: finish pytest_pyfunc_call --> True [hook] finish pytest_runtest_call --> [] [hook] pytest_runtest_makereport [hook] item: call: finish pytest_runtest_makereport --> [hook] pytest_runtest_logreport [hook] report: pytest_report_teststatus [hook] report: config: <_pytest.config.Config object at 0x7f1da3c09270> finish pytest_report_teststatus --> ('passed', '.', 'PASSED') [hook] finish pytest_runtest_logreport --> [] [hook] pytest_runtest_teardown [hook] item: nextitem: pytest_fixture_post_finalizer [hook] fixturedef: request: > finish pytest_fixture_post_finalizer --> [] [hook] finish pytest_runtest_teardown --> [] [hook] pytest_runtest_makereport [hook] item: call: finish pytest_runtest_makereport --> [hook] pytest_runtest_logreport [hook] report: pytest_report_teststatus [hook] report: config: <_pytest.config.Config object at 0x7f1da3c09270> finish pytest_report_teststatus --> ('', '', '') [hook] finish pytest_runtest_logreport --> [] [hook] pytest_runtest_logfinish [hook] nodeid: tests/test_aes.py::test_cfb_128_fb16[AES] location: ('tests/test_aes.py', 879, 'test_cfb_128_fb16[AES]') finish pytest_runtest_logfinish --> [] [hook] finish pytest_runtest_protocol --> True [hook] pytest_runtest_protocol [hook] item: nextitem: pytest_runtest_logstart [hook] nodeid: tests/test_aes.py::test_cfb_192_fb16[AES] location: ('tests/test_aes.py', 883, 'test_cfb_192_fb16[AES]') finish pytest_runtest_logstart --> [] [hook] pytest_runtest_setup [hook] item: pytest_fixture_setup [hook] fixturedef: request: > finish pytest_fixture_setup --> [hook] finish pytest_runtest_setup --> [] [hook] pytest_runtest_makereport [hook] item: call: finish pytest_runtest_makereport --> [hook] pytest_runtest_logreport [hook] report: pytest_report_teststatus [hook] report: config: <_pytest.config.Config object at 0x7f1da3c09270> finish pytest_report_teststatus --> ('', '', '') [hook] finish pytest_runtest_logreport --> [] [hook] pytest_runtest_call [hook] item: pytest_pyfunc_call [hook] pyfuncitem: finish pytest_pyfunc_call --> True [hook] finish pytest_runtest_call --> [] [hook] pytest_runtest_makereport [hook] item: call: finish pytest_runtest_makereport --> [hook] pytest_runtest_logreport [hook] report: pytest_report_teststatus [hook] report: config: <_pytest.config.Config object at 0x7f1da3c09270> finish pytest_report_teststatus --> ('passed', '.', 'PASSED') [hook] finish pytest_runtest_logreport --> [] [hook] pytest_runtest_teardown [hook] item: nextitem: pytest_fixture_post_finalizer [hook] fixturedef: request: > finish pytest_fixture_post_finalizer --> [] [hook] finish pytest_runtest_teardown --> [] [hook] pytest_runtest_makereport [hook] item: call: finish pytest_runtest_makereport --> [hook] pytest_runtest_logreport [hook] report: pytest_report_teststatus [hook] report: config: <_pytest.config.Config object at 0x7f1da3c09270> finish pytest_report_teststatus --> ('', '', '') [hook] finish pytest_runtest_logreport --> [] [hook] pytest_runtest_logfinish [hook] nodeid: tests/test_aes.py::test_cfb_192_fb16[AES] location: ('tests/test_aes.py', 883, 'test_cfb_192_fb16[AES]') finish pytest_runtest_logfinish --> [] [hook] finish pytest_runtest_protocol --> True [hook] pytest_runtest_protocol [hook] item: nextitem: pytest_runtest_logstart [hook] nodeid: tests/test_aes.py::test_cfb_256_fb16[AES] location: ('tests/test_aes.py', 887, 'test_cfb_256_fb16[AES]') finish pytest_runtest_logstart --> [] [hook] pytest_runtest_setup [hook] item: pytest_fixture_setup [hook] fixturedef: request: > finish pytest_fixture_setup --> [hook] finish pytest_runtest_setup --> [] [hook] pytest_runtest_makereport [hook] item: call: finish pytest_runtest_makereport --> [hook] pytest_runtest_logreport [hook] report: pytest_report_teststatus [hook] report: config: <_pytest.config.Config object at 0x7f1da3c09270> finish pytest_report_teststatus --> ('', '', '') [hook] finish pytest_runtest_logreport --> [] [hook] pytest_runtest_call [hook] item: pytest_pyfunc_call [hook] pyfuncitem: finish pytest_pyfunc_call --> True [hook] finish pytest_runtest_call --> [] [hook] pytest_runtest_makereport [hook] item: call: finish pytest_runtest_makereport --> [hook] pytest_runtest_logreport [hook] report: pytest_report_teststatus [hook] report: config: <_pytest.config.Config object at 0x7f1da3c09270> finish pytest_report_teststatus --> ('passed', '.', 'PASSED') [hook] finish pytest_runtest_logreport --> [] [hook] pytest_runtest_teardown [hook] item: nextitem: pytest_fixture_post_finalizer [hook] fixturedef: request: > finish pytest_fixture_post_finalizer --> [] [hook] finish pytest_runtest_teardown --> [] [hook] pytest_runtest_makereport [hook] item: call: finish pytest_runtest_makereport --> [hook] pytest_runtest_logreport [hook] report: pytest_report_teststatus [hook] report: config: <_pytest.config.Config object at 0x7f1da3c09270> finish pytest_report_teststatus --> ('', '', '') [hook] finish pytest_runtest_logreport --> [] [hook] pytest_runtest_logfinish [hook] nodeid: tests/test_aes.py::test_cfb_256_fb16[AES] location: ('tests/test_aes.py', 887, 'test_cfb_256_fb16[AES]') finish pytest_runtest_logfinish --> [] [hook] finish pytest_runtest_protocol --> True [hook] pytest_runtest_protocol [hook] item: nextitem: pytest_runtest_logstart [hook] nodeid: tests/test_aes.py::test_cfb_long_fb16[AES] location: ('tests/test_aes.py', 891, 'test_cfb_long_fb16[AES]') finish pytest_runtest_logstart --> [] [hook] pytest_runtest_setup [hook] item: pytest_fixture_setup [hook] fixturedef: request: > finish pytest_fixture_setup --> [hook] finish pytest_runtest_setup --> [] [hook] pytest_runtest_makereport [hook] item: call: finish pytest_runtest_makereport --> [hook] pytest_runtest_logreport [hook] report: pytest_report_teststatus [hook] report: config: <_pytest.config.Config object at 0x7f1da3c09270> finish pytest_report_teststatus --> ('', '', '') [hook] finish pytest_runtest_logreport --> [] [hook] pytest_runtest_call [hook] item: pytest_pyfunc_call [hook] pyfuncitem: finish pytest_pyfunc_call --> True [hook] finish pytest_runtest_call --> [] [hook] pytest_runtest_makereport [hook] item: call: finish pytest_runtest_makereport --> [hook] pytest_runtest_logreport [hook] report: pytest_report_teststatus [hook] report: config: <_pytest.config.Config object at 0x7f1da3c09270> finish pytest_report_teststatus --> ('passed', '.', 'PASSED') [hook] finish pytest_runtest_logreport --> [] [hook] pytest_runtest_teardown [hook] item: nextitem: pytest_fixture_post_finalizer [hook] fixturedef: request: > finish pytest_fixture_post_finalizer --> [] [hook] finish pytest_runtest_teardown --> [] [hook] pytest_runtest_makereport [hook] item: call: finish pytest_runtest_makereport --> [hook] pytest_runtest_logreport [hook] report: pytest_report_teststatus [hook] report: config: <_pytest.config.Config object at 0x7f1da3c09270> finish pytest_report_teststatus --> ('', '', '') [hook] finish pytest_runtest_logreport --> [] [hook] pytest_runtest_logfinish [hook] nodeid: tests/test_aes.py::test_cfb_long_fb16[AES] location: ('tests/test_aes.py', 891, 'test_cfb_long_fb16[AES]') finish pytest_runtest_logfinish --> [] [hook] finish pytest_runtest_protocol --> True [hook] pytest_runtest_protocol [hook] item: nextitem: pytest_runtest_logstart [hook] nodeid: tests/test_aes.py::test_ofb_128[AES] location: ('tests/test_aes.py', 895, 'test_ofb_128[AES]') finish pytest_runtest_logstart --> [] [hook] pytest_runtest_setup [hook] item: pytest_fixture_setup [hook] fixturedef: request: > finish pytest_fixture_setup --> [hook] finish pytest_runtest_setup --> [] [hook] pytest_runtest_makereport [hook] item: call: finish pytest_runtest_makereport --> [hook] pytest_runtest_logreport [hook] report: pytest_report_teststatus [hook] report: config: <_pytest.config.Config object at 0x7f1da3c09270> finish pytest_report_teststatus --> ('', '', '') [hook] finish pytest_runtest_logreport --> [] [hook] pytest_runtest_call [hook] item: pytest_pyfunc_call [hook] pyfuncitem: finish pytest_pyfunc_call --> True [hook] finish pytest_runtest_call --> [] [hook] pytest_runtest_makereport [hook] item: call: finish pytest_runtest_makereport --> [hook] pytest_runtest_logreport [hook] report: pytest_report_teststatus [hook] report: config: <_pytest.config.Config object at 0x7f1da3c09270> finish pytest_report_teststatus --> ('passed', '.', 'PASSED') [hook] finish pytest_runtest_logreport --> [] [hook] pytest_runtest_teardown [hook] item: nextitem: pytest_fixture_post_finalizer [hook] fixturedef: request: > finish pytest_fixture_post_finalizer --> [] [hook] finish pytest_runtest_teardown --> [] [hook] pytest_runtest_makereport [hook] item: call: finish pytest_runtest_makereport --> [hook] pytest_runtest_logreport [hook] report: pytest_report_teststatus [hook] report: config: <_pytest.config.Config object at 0x7f1da3c09270> finish pytest_report_teststatus --> ('', '', '') [hook] finish pytest_runtest_logreport --> [] [hook] pytest_runtest_logfinish [hook] nodeid: tests/test_aes.py::test_ofb_128[AES] location: ('tests/test_aes.py', 895, 'test_ofb_128[AES]') finish pytest_runtest_logfinish --> [] [hook] finish pytest_runtest_protocol --> True [hook] pytest_runtest_protocol [hook] item: nextitem: pytest_runtest_logstart [hook] nodeid: tests/test_aes.py::test_ofb_192[AES] location: ('tests/test_aes.py', 899, 'test_ofb_192[AES]') finish pytest_runtest_logstart --> [] [hook] pytest_runtest_setup [hook] item: pytest_fixture_setup [hook] fixturedef: request: > finish pytest_fixture_setup --> [hook] finish pytest_runtest_setup --> [] [hook] pytest_runtest_makereport [hook] item: call: finish pytest_runtest_makereport --> [hook] pytest_runtest_logreport [hook] report: pytest_report_teststatus [hook] report: config: <_pytest.config.Config object at 0x7f1da3c09270> finish pytest_report_teststatus --> ('', '', '') [hook] finish pytest_runtest_logreport --> [] [hook] pytest_runtest_call [hook] item: pytest_pyfunc_call [hook] pyfuncitem: finish pytest_pyfunc_call --> True [hook] finish pytest_runtest_call --> [] [hook] pytest_runtest_makereport [hook] item: call: finish pytest_runtest_makereport --> [hook] pytest_runtest_logreport [hook] report: pytest_report_teststatus [hook] report: config: <_pytest.config.Config object at 0x7f1da3c09270> finish pytest_report_teststatus --> ('passed', '.', 'PASSED') [hook] finish pytest_runtest_logreport --> [] [hook] pytest_runtest_teardown [hook] item: nextitem: pytest_fixture_post_finalizer [hook] fixturedef: request: > finish pytest_fixture_post_finalizer --> [] [hook] finish pytest_runtest_teardown --> [] [hook] pytest_runtest_makereport [hook] item: call: finish pytest_runtest_makereport --> [hook] pytest_runtest_logreport [hook] report: pytest_report_teststatus [hook] report: config: <_pytest.config.Config object at 0x7f1da3c09270> finish pytest_report_teststatus --> ('', '', '') [hook] finish pytest_runtest_logreport --> [] [hook] pytest_runtest_logfinish [hook] nodeid: tests/test_aes.py::test_ofb_192[AES] location: ('tests/test_aes.py', 899, 'test_ofb_192[AES]') finish pytest_runtest_logfinish --> [] [hook] finish pytest_runtest_protocol --> True [hook] pytest_runtest_protocol [hook] item: nextitem: pytest_runtest_logstart [hook] nodeid: tests/test_aes.py::test_ofb_256[AES] location: ('tests/test_aes.py', 903, 'test_ofb_256[AES]') finish pytest_runtest_logstart --> [] [hook] pytest_runtest_setup [hook] item: pytest_fixture_setup [hook] fixturedef: request: > finish pytest_fixture_setup --> [hook] finish pytest_runtest_setup --> [] [hook] pytest_runtest_makereport [hook] item: call: finish pytest_runtest_makereport --> [hook] pytest_runtest_logreport [hook] report: pytest_report_teststatus [hook] report: config: <_pytest.config.Config object at 0x7f1da3c09270> finish pytest_report_teststatus --> ('', '', '') [hook] finish pytest_runtest_logreport --> [] [hook] pytest_runtest_call [hook] item: pytest_pyfunc_call [hook] pyfuncitem: finish pytest_pyfunc_call --> True [hook] finish pytest_runtest_call --> [] [hook] pytest_runtest_makereport [hook] item: call: finish pytest_runtest_makereport --> [hook] pytest_runtest_logreport [hook] report: pytest_report_teststatus [hook] report: config: <_pytest.config.Config object at 0x7f1da3c09270> finish pytest_report_teststatus --> ('passed', '.', 'PASSED') [hook] finish pytest_runtest_logreport --> [] [hook] pytest_runtest_teardown [hook] item: nextitem: pytest_fixture_post_finalizer [hook] fixturedef: request: > finish pytest_fixture_post_finalizer --> [] [hook] finish pytest_runtest_teardown --> [] [hook] pytest_runtest_makereport [hook] item: call: finish pytest_runtest_makereport --> [hook] pytest_runtest_logreport [hook] report: pytest_report_teststatus [hook] report: config: <_pytest.config.Config object at 0x7f1da3c09270> finish pytest_report_teststatus --> ('', '', '') [hook] finish pytest_runtest_logreport --> [] [hook] pytest_runtest_logfinish [hook] nodeid: tests/test_aes.py::test_ofb_256[AES] location: ('tests/test_aes.py', 903, 'test_ofb_256[AES]') finish pytest_runtest_logfinish --> [] [hook] finish pytest_runtest_protocol --> True [hook] pytest_runtest_protocol [hook] item: nextitem: pytest_runtest_logstart [hook] nodeid: tests/test_aes.py::test_ofb_long[AES] location: ('tests/test_aes.py', 907, 'test_ofb_long[AES]') finish pytest_runtest_logstart --> [] [hook] pytest_runtest_setup [hook] item: pytest_fixture_setup [hook] fixturedef: request: > finish pytest_fixture_setup --> [hook] finish pytest_runtest_setup --> [] [hook] pytest_runtest_makereport [hook] item: call: finish pytest_runtest_makereport --> [hook] pytest_runtest_logreport [hook] report: pytest_report_teststatus [hook] report: config: <_pytest.config.Config object at 0x7f1da3c09270> finish pytest_report_teststatus --> ('', '', '') [hook] finish pytest_runtest_logreport --> [] [hook] pytest_runtest_call [hook] item: pytest_pyfunc_call [hook] pyfuncitem: finish pytest_pyfunc_call --> True [hook] finish pytest_runtest_call --> [] [hook] pytest_runtest_makereport [hook] item: call: finish pytest_runtest_makereport --> [hook] pytest_runtest_logreport [hook] report: pytest_report_teststatus [hook] report: config: <_pytest.config.Config object at 0x7f1da3c09270> finish pytest_report_teststatus --> ('passed', '.', 'PASSED') [hook] finish pytest_runtest_logreport --> [] [hook] pytest_runtest_teardown [hook] item: nextitem: pytest_fixture_post_finalizer [hook] fixturedef: request: > finish pytest_fixture_post_finalizer --> [] [hook] finish pytest_runtest_teardown --> [] [hook] pytest_runtest_makereport [hook] item: call: finish pytest_runtest_makereport --> [hook] pytest_runtest_logreport [hook] report: pytest_report_teststatus [hook] report: config: <_pytest.config.Config object at 0x7f1da3c09270> finish pytest_report_teststatus --> ('', '', '') [hook] finish pytest_runtest_logreport --> [] [hook] pytest_runtest_logfinish [hook] nodeid: tests/test_aes.py::test_ofb_long[AES] location: ('tests/test_aes.py', 907, 'test_ofb_long[AES]') finish pytest_runtest_logfinish --> [] [hook] finish pytest_runtest_protocol --> True [hook] pytest_runtest_protocol [hook] item: nextitem: pytest_runtest_logstart [hook] nodeid: tests/test_aes.py::test_ctr_128[AES] location: ('tests/test_aes.py', 911, 'test_ctr_128[AES]') finish pytest_runtest_logstart --> [] [hook] pytest_runtest_setup [hook] item: pytest_fixture_setup [hook] fixturedef: request: > finish pytest_fixture_setup --> [hook] finish pytest_runtest_setup --> [] [hook] pytest_runtest_makereport [hook] item: call: finish pytest_runtest_makereport --> [hook] pytest_runtest_logreport [hook] report: pytest_report_teststatus [hook] report: config: <_pytest.config.Config object at 0x7f1da3c09270> finish pytest_report_teststatus --> ('', '', '') [hook] finish pytest_runtest_logreport --> [] [hook] pytest_runtest_call [hook] item: pytest_pyfunc_call [hook] pyfuncitem: finish pytest_pyfunc_call --> True [hook] finish pytest_runtest_call --> [] [hook] pytest_runtest_makereport [hook] item: call: finish pytest_runtest_makereport --> [hook] pytest_runtest_logreport [hook] report: pytest_report_teststatus [hook] report: config: <_pytest.config.Config object at 0x7f1da3c09270> finish pytest_report_teststatus --> ('passed', '.', 'PASSED') [hook] finish pytest_runtest_logreport --> [] [hook] pytest_runtest_teardown [hook] item: nextitem: pytest_fixture_post_finalizer [hook] fixturedef: request: > finish pytest_fixture_post_finalizer --> [] [hook] finish pytest_runtest_teardown --> [] [hook] pytest_runtest_makereport [hook] item: call: finish pytest_runtest_makereport --> [hook] pytest_runtest_logreport [hook] report: pytest_report_teststatus [hook] report: config: <_pytest.config.Config object at 0x7f1da3c09270> finish pytest_report_teststatus --> ('', '', '') [hook] finish pytest_runtest_logreport --> [] [hook] pytest_runtest_logfinish [hook] nodeid: tests/test_aes.py::test_ctr_128[AES] location: ('tests/test_aes.py', 911, 'test_ctr_128[AES]') finish pytest_runtest_logfinish --> [] [hook] finish pytest_runtest_protocol --> True [hook] pytest_runtest_protocol [hook] item: nextitem: pytest_runtest_logstart [hook] nodeid: tests/test_aes.py::test_ctr_192[AES] location: ('tests/test_aes.py', 915, 'test_ctr_192[AES]') finish pytest_runtest_logstart --> [] [hook] pytest_runtest_setup [hook] item: pytest_fixture_setup [hook] fixturedef: request: > finish pytest_fixture_setup --> [hook] finish pytest_runtest_setup --> [] [hook] pytest_runtest_makereport [hook] item: call: finish pytest_runtest_makereport --> [hook] pytest_runtest_logreport [hook] report: pytest_report_teststatus [hook] report: config: <_pytest.config.Config object at 0x7f1da3c09270> finish pytest_report_teststatus --> ('', '', '') [hook] finish pytest_runtest_logreport --> [] [hook] pytest_runtest_call [hook] item: pytest_pyfunc_call [hook] pyfuncitem: finish pytest_pyfunc_call --> True [hook] finish pytest_runtest_call --> [] [hook] pytest_runtest_makereport [hook] item: call: finish pytest_runtest_makereport --> [hook] pytest_runtest_logreport [hook] report: pytest_report_teststatus [hook] report: config: <_pytest.config.Config object at 0x7f1da3c09270> finish pytest_report_teststatus --> ('passed', '.', 'PASSED') [hook] finish pytest_runtest_logreport --> [] [hook] pytest_runtest_teardown [hook] item: nextitem: pytest_fixture_post_finalizer [hook] fixturedef: request: > finish pytest_fixture_post_finalizer --> [] [hook] finish pytest_runtest_teardown --> [] [hook] pytest_runtest_makereport [hook] item: call: finish pytest_runtest_makereport --> [hook] pytest_runtest_logreport [hook] report: pytest_report_teststatus [hook] report: config: <_pytest.config.Config object at 0x7f1da3c09270> finish pytest_report_teststatus --> ('', '', '') [hook] finish pytest_runtest_logreport --> [] [hook] pytest_runtest_logfinish [hook] nodeid: tests/test_aes.py::test_ctr_192[AES] location: ('tests/test_aes.py', 915, 'test_ctr_192[AES]') finish pytest_runtest_logfinish --> [] [hook] finish pytest_runtest_protocol --> True [hook] pytest_runtest_protocol [hook] item: nextitem: pytest_runtest_logstart [hook] nodeid: tests/test_aes.py::test_ctr_256[AES] location: ('tests/test_aes.py', 919, 'test_ctr_256[AES]') finish pytest_runtest_logstart --> [] [hook] pytest_runtest_setup [hook] item: pytest_fixture_setup [hook] fixturedef: request: > finish pytest_fixture_setup --> [hook] finish pytest_runtest_setup --> [] [hook] pytest_runtest_makereport [hook] item: call: finish pytest_runtest_makereport --> [hook] pytest_runtest_logreport [hook] report: pytest_report_teststatus [hook] report: config: <_pytest.config.Config object at 0x7f1da3c09270> finish pytest_report_teststatus --> ('', '', '') [hook] finish pytest_runtest_logreport --> [] [hook] pytest_runtest_call [hook] item: pytest_pyfunc_call [hook] pyfuncitem: finish pytest_pyfunc_call --> True [hook] finish pytest_runtest_call --> [] [hook] pytest_runtest_makereport [hook] item: call: finish pytest_runtest_makereport --> [hook] pytest_runtest_logreport [hook] report: pytest_report_teststatus [hook] report: config: <_pytest.config.Config object at 0x7f1da3c09270> finish pytest_report_teststatus --> ('passed', '.', 'PASSED') [hook] finish pytest_runtest_logreport --> [] [hook] pytest_runtest_teardown [hook] item: nextitem: pytest_fixture_post_finalizer [hook] fixturedef: request: > finish pytest_fixture_post_finalizer --> [] [hook] finish pytest_runtest_teardown --> [] [hook] pytest_runtest_makereport [hook] item: call: finish pytest_runtest_makereport --> [hook] pytest_runtest_logreport [hook] report: pytest_report_teststatus [hook] report: config: <_pytest.config.Config object at 0x7f1da3c09270> finish pytest_report_teststatus --> ('', '', '') [hook] finish pytest_runtest_logreport --> [] [hook] pytest_runtest_logfinish [hook] nodeid: tests/test_aes.py::test_ctr_256[AES] location: ('tests/test_aes.py', 919, 'test_ctr_256[AES]') finish pytest_runtest_logfinish --> [] [hook] finish pytest_runtest_protocol --> True [hook] pytest_runtest_protocol [hook] item: nextitem: pytest_runtest_logstart [hook] nodeid: tests/test_aes.py::test_ctr_long[AES] location: ('tests/test_aes.py', 923, 'test_ctr_long[AES]') finish pytest_runtest_logstart --> [] [hook] pytest_runtest_setup [hook] item: pytest_fixture_setup [hook] fixturedef: request: > finish pytest_fixture_setup --> [hook] finish pytest_runtest_setup --> [] [hook] pytest_runtest_makereport [hook] item: call: finish pytest_runtest_makereport --> [hook] pytest_runtest_logreport [hook] report: pytest_report_teststatus [hook] report: config: <_pytest.config.Config object at 0x7f1da3c09270> finish pytest_report_teststatus --> ('', '', '') [hook] finish pytest_runtest_logreport --> [] [hook] pytest_runtest_call [hook] item: pytest_pyfunc_call [hook] pyfuncitem: finish pytest_pyfunc_call --> True [hook] finish pytest_runtest_call --> [] [hook] pytest_runtest_makereport [hook] item: call: finish pytest_runtest_makereport --> [hook] pytest_runtest_logreport [hook] report: pytest_report_teststatus [hook] report: config: <_pytest.config.Config object at 0x7f1da3c09270> finish pytest_report_teststatus --> ('passed', '.', 'PASSED') [hook] finish pytest_runtest_logreport --> [] [hook] pytest_runtest_teardown [hook] item: nextitem: pytest_fixture_post_finalizer [hook] fixturedef: request: > finish pytest_fixture_post_finalizer --> [] [hook] finish pytest_runtest_teardown --> [] [hook] pytest_runtest_makereport [hook] item: call: finish pytest_runtest_makereport --> [hook] pytest_runtest_logreport [hook] report: pytest_report_teststatus [hook] report: config: <_pytest.config.Config object at 0x7f1da3c09270> finish pytest_report_teststatus --> ('', '', '') [hook] finish pytest_runtest_logreport --> [] [hook] pytest_runtest_logfinish [hook] nodeid: tests/test_aes.py::test_ctr_long[AES] location: ('tests/test_aes.py', 923, 'test_ctr_long[AES]') finish pytest_runtest_logfinish --> [] [hook] finish pytest_runtest_protocol --> True [hook] pytest_runtest_protocol [hook] item: nextitem: pytest_runtest_logstart [hook] nodeid: tests/test_aes.py::test_ccm[AES] location: ('tests/test_aes.py', 927, 'test_ccm[AES]') finish pytest_runtest_logstart --> [] [hook] pytest_runtest_setup [hook] item: pytest_fixture_setup [hook] fixturedef: request: > finish pytest_fixture_setup --> [hook] finish pytest_runtest_setup --> [] [hook] pytest_runtest_makereport [hook] item: call: finish pytest_runtest_makereport --> [hook] pytest_runtest_logreport [hook] report: pytest_report_teststatus [hook] report: config: <_pytest.config.Config object at 0x7f1da3c09270> finish pytest_report_teststatus --> ('', '', '') [hook] finish pytest_runtest_logreport --> [] [hook] pytest_runtest_call [hook] item: pytest_pyfunc_call [hook] pyfuncitem: finish pytest_pyfunc_call --> True [hook] finish pytest_runtest_call --> [] [hook] pytest_runtest_makereport [hook] item: call: finish pytest_runtest_makereport --> [hook] pytest_runtest_logreport [hook] report: pytest_report_teststatus [hook] report: config: <_pytest.config.Config object at 0x7f1da3c09270> finish pytest_report_teststatus --> ('passed', '.', 'PASSED') [hook] finish pytest_runtest_logreport --> [] [hook] pytest_runtest_teardown [hook] item: nextitem: pytest_fixture_post_finalizer [hook] fixturedef: request: > finish pytest_fixture_post_finalizer --> [] [hook] finish pytest_runtest_teardown --> [] [hook] pytest_runtest_makereport [hook] item: call: finish pytest_runtest_makereport --> [hook] pytest_runtest_logreport [hook] report: pytest_report_teststatus [hook] report: config: <_pytest.config.Config object at 0x7f1da3c09270> finish pytest_report_teststatus --> ('', '', '') [hook] finish pytest_runtest_logreport --> [] [hook] pytest_runtest_logfinish [hook] nodeid: tests/test_aes.py::test_ccm[AES] location: ('tests/test_aes.py', 927, 'test_ccm[AES]') finish pytest_runtest_logfinish --> [] [hook] finish pytest_runtest_protocol --> True [hook] pytest_runtest_protocol [hook] item: nextitem: pytest_runtest_logstart [hook] nodeid: tests/test_aes.py::test_gcm_128[AES] location: ('tests/test_aes.py', 834, 'test_gcm_128[AES]') finish pytest_runtest_logstart --> [] [hook] pytest_runtest_setup [hook] item: pytest_fixture_setup [hook] fixturedef: request: > finish pytest_fixture_setup --> [hook] finish pytest_runtest_setup --> [] [hook] pytest_runtest_makereport [hook] item: call: finish pytest_runtest_makereport --> [hook] pytest_runtest_logreport [hook] report: pytest_report_teststatus [hook] report: config: <_pytest.config.Config object at 0x7f1da3c09270> finish pytest_report_teststatus --> ('', '', '') [hook] finish pytest_runtest_logreport --> [] [hook] pytest_runtest_call [hook] item: pytest_pyfunc_call [hook] pyfuncitem: early skip of rewriting module: unicrypto.backends.pure.external.AES.AESGCM [assertion] finish pytest_pyfunc_call --> True [hook] finish pytest_runtest_call --> [] [hook] pytest_runtest_makereport [hook] item: call: finish pytest_runtest_makereport --> [hook] pytest_runtest_logreport [hook] report: pytest_report_teststatus [hook] report: config: <_pytest.config.Config object at 0x7f1da3c09270> finish pytest_report_teststatus --> ('passed', '.', 'PASSED') [hook] finish pytest_runtest_logreport --> [] [hook] pytest_runtest_teardown [hook] item: nextitem: pytest_fixture_post_finalizer [hook] fixturedef: request: > finish pytest_fixture_post_finalizer --> [] [hook] finish pytest_runtest_teardown --> [] [hook] pytest_runtest_makereport [hook] item: call: finish pytest_runtest_makereport --> [hook] pytest_runtest_logreport [hook] report: pytest_report_teststatus [hook] report: config: <_pytest.config.Config object at 0x7f1da3c09270> finish pytest_report_teststatus --> ('', '', '') [hook] finish pytest_runtest_logreport --> [] [hook] pytest_runtest_logfinish [hook] nodeid: tests/test_aes.py::test_gcm_128[AES] location: ('tests/test_aes.py', 834, 'test_gcm_128[AES]') finish pytest_runtest_logfinish --> [] [hook] finish pytest_runtest_protocol --> True [hook] pytest_runtest_protocol [hook] item: nextitem: pytest_runtest_logstart [hook] nodeid: tests/test_aes.py::test_gcm_256[AES] location: ('tests/test_aes.py', 838, 'test_gcm_256[AES]') finish pytest_runtest_logstart --> [] [hook] pytest_runtest_setup [hook] item: pytest_fixture_setup [hook] fixturedef: request: > finish pytest_fixture_setup --> [hook] finish pytest_runtest_setup --> [] [hook] pytest_runtest_makereport [hook] item: call: finish pytest_runtest_makereport --> [hook] pytest_runtest_logreport [hook] report: pytest_report_teststatus [hook] report: config: <_pytest.config.Config object at 0x7f1da3c09270> finish pytest_report_teststatus --> ('', '', '') [hook] finish pytest_runtest_logreport --> [] [hook] pytest_runtest_call [hook] item: pytest_pyfunc_call [hook] pyfuncitem: finish pytest_pyfunc_call --> True [hook] finish pytest_runtest_call --> [] [hook] pytest_runtest_makereport [hook] item: call: finish pytest_runtest_makereport --> [hook] pytest_runtest_logreport [hook] report: pytest_report_teststatus [hook] report: config: <_pytest.config.Config object at 0x7f1da3c09270> finish pytest_report_teststatus --> ('passed', '.', 'PASSED') [hook] finish pytest_runtest_logreport --> [] [hook] pytest_runtest_teardown [hook] item: nextitem: pytest_fixture_post_finalizer [hook] fixturedef: request: > finish pytest_fixture_post_finalizer --> [] [hook] finish pytest_runtest_teardown --> [] [hook] pytest_runtest_makereport [hook] item: call: finish pytest_runtest_makereport --> [hook] pytest_runtest_logreport [hook] report: pytest_report_teststatus [hook] report: config: <_pytest.config.Config object at 0x7f1da3c09270> finish pytest_report_teststatus --> ('', '', '') [hook] finish pytest_runtest_logreport --> [] [hook] pytest_runtest_logfinish [hook] nodeid: tests/test_aes.py::test_gcm_256[AES] location: ('tests/test_aes.py', 838, 'test_gcm_256[AES]') finish pytest_runtest_logfinish --> [] [hook] finish pytest_runtest_protocol --> True [hook] pytest_runtest_protocol [hook] item: nextitem: pytest_runtest_logstart [hook] nodeid: tests/test_des.py::test_ecb[DES] location: ('tests/test_des.py', 96, 'test_ecb[DES]') finish pytest_runtest_logstart --> [] [hook] pytest_runtest_setup [hook] item: pytest_fixture_setup [hook] fixturedef: request: > finish pytest_fixture_setup --> [hook] finish pytest_runtest_setup --> [] [hook] pytest_runtest_makereport [hook] item: call: finish pytest_runtest_makereport --> [hook] pytest_runtest_logreport [hook] report: pytest_report_teststatus [hook] report: config: <_pytest.config.Config object at 0x7f1da3c09270> finish pytest_report_teststatus --> ('', '', '') [hook] finish pytest_runtest_logreport --> [] [hook] pytest_runtest_call [hook] item: pytest_pyfunc_call [hook] pyfuncitem: finish pytest_pyfunc_call --> True [hook] finish pytest_runtest_call --> [] [hook] pytest_runtest_makereport [hook] item: call: finish pytest_runtest_makereport --> [hook] pytest_runtest_logreport [hook] report: pytest_report_teststatus [hook] report: config: <_pytest.config.Config object at 0x7f1da3c09270> finish pytest_report_teststatus --> ('passed', '.', 'PASSED') [hook] finish pytest_runtest_logreport --> [] [hook] pytest_runtest_teardown [hook] item: nextitem: pytest_fixture_post_finalizer [hook] fixturedef: request: > finish pytest_fixture_post_finalizer --> [] [hook] finish pytest_runtest_teardown --> [] [hook] pytest_runtest_makereport [hook] item: call: finish pytest_runtest_makereport --> [hook] pytest_runtest_logreport [hook] report: pytest_report_teststatus [hook] report: config: <_pytest.config.Config object at 0x7f1da3c09270> finish pytest_report_teststatus --> ('', '', '') [hook] finish pytest_runtest_logreport --> [] [hook] pytest_runtest_logfinish [hook] nodeid: tests/test_des.py::test_ecb[DES] location: ('tests/test_des.py', 96, 'test_ecb[DES]') finish pytest_runtest_logfinish --> [] [hook] finish pytest_runtest_protocol --> True [hook] pytest_runtest_protocol [hook] item: nextitem: pytest_runtest_logstart [hook] nodeid: tests/test_des.py::test_cbc[DES] location: ('tests/test_des.py', 100, 'test_cbc[DES]') finish pytest_runtest_logstart --> [] [hook] pytest_runtest_setup [hook] item: pytest_fixture_setup [hook] fixturedef: request: > finish pytest_fixture_setup --> [hook] finish pytest_runtest_setup --> [] [hook] pytest_runtest_makereport [hook] item: call: finish pytest_runtest_makereport --> [hook] pytest_runtest_logreport [hook] report: pytest_report_teststatus [hook] report: config: <_pytest.config.Config object at 0x7f1da3c09270> finish pytest_report_teststatus --> ('', '', '') [hook] finish pytest_runtest_logreport --> [] [hook] pytest_runtest_call [hook] item: pytest_pyfunc_call [hook] pyfuncitem: finish pytest_pyfunc_call --> True [hook] finish pytest_runtest_call --> [] [hook] pytest_runtest_makereport [hook] item: call: finish pytest_runtest_makereport --> [hook] pytest_runtest_logreport [hook] report: pytest_report_teststatus [hook] report: config: <_pytest.config.Config object at 0x7f1da3c09270> finish pytest_report_teststatus --> ('passed', '.', 'PASSED') [hook] finish pytest_runtest_logreport --> [] [hook] pytest_runtest_teardown [hook] item: nextitem: pytest_fixture_post_finalizer [hook] fixturedef: request: > finish pytest_fixture_post_finalizer --> [] [hook] finish pytest_runtest_teardown --> [] [hook] pytest_runtest_makereport [hook] item: call: finish pytest_runtest_makereport --> [hook] pytest_runtest_logreport [hook] report: pytest_report_teststatus [hook] report: config: <_pytest.config.Config object at 0x7f1da3c09270> finish pytest_report_teststatus --> ('', '', '') [hook] finish pytest_runtest_logreport --> [] [hook] pytest_runtest_logfinish [hook] nodeid: tests/test_des.py::test_cbc[DES] location: ('tests/test_des.py', 100, 'test_cbc[DES]') finish pytest_runtest_logfinish --> [] [hook] finish pytest_runtest_protocol --> True [hook] pytest_runtest_protocol [hook] item: nextitem: pytest_runtest_logstart [hook] nodeid: tests/test_import.py::test_aes_mbedtls location: ('tests/test_import.py', 2, 'test_aes_mbedtls') finish pytest_runtest_logstart --> [] [hook] pytest_runtest_setup [hook] item: finish pytest_runtest_setup --> [] [hook] pytest_runtest_makereport [hook] item: call: finish pytest_runtest_makereport --> [hook] pytest_runtest_logreport [hook] report: pytest_report_teststatus [hook] report: config: <_pytest.config.Config object at 0x7f1da3c09270> finish pytest_report_teststatus --> ('', '', '') [hook] finish pytest_runtest_logreport --> [] [hook] pytest_runtest_call [hook] item: pytest_pyfunc_call [hook] pyfuncitem: finish pytest_pyfunc_call --> True [hook] finish pytest_runtest_call --> [] [hook] pytest_runtest_makereport [hook] item: call: finish pytest_runtest_makereport --> [hook] pytest_runtest_logreport [hook] report: pytest_report_teststatus [hook] report: config: <_pytest.config.Config object at 0x7f1da3c09270> finish pytest_report_teststatus --> ('passed', '.', 'PASSED') [hook] finish pytest_runtest_logreport --> [] [hook] pytest_runtest_teardown [hook] item: nextitem: finish pytest_runtest_teardown --> [] [hook] pytest_runtest_makereport [hook] item: call: finish pytest_runtest_makereport --> [hook] pytest_runtest_logreport [hook] report: pytest_report_teststatus [hook] report: config: <_pytest.config.Config object at 0x7f1da3c09270> finish pytest_report_teststatus --> ('', '', '') [hook] finish pytest_runtest_logreport --> [] [hook] pytest_runtest_logfinish [hook] nodeid: tests/test_import.py::test_aes_mbedtls location: ('tests/test_import.py', 2, 'test_aes_mbedtls') finish pytest_runtest_logfinish --> [] [hook] finish pytest_runtest_protocol --> True [hook] pytest_runtest_protocol [hook] item: nextitem: pytest_runtest_logstart [hook] nodeid: tests/test_import.py::test_aes_pycryptodome location: ('tests/test_import.py', 12, 'test_aes_pycryptodome') finish pytest_runtest_logstart --> [] [hook] pytest_runtest_setup [hook] item: finish pytest_runtest_setup --> [] [hook] pytest_runtest_makereport [hook] item: call: finish pytest_runtest_makereport --> [hook] pytest_runtest_logreport [hook] report: pytest_report_teststatus [hook] report: config: <_pytest.config.Config object at 0x7f1da3c09270> finish pytest_report_teststatus --> ('', '', '') [hook] finish pytest_runtest_logreport --> [] [hook] pytest_runtest_call [hook] item: pytest_pyfunc_call [hook] pyfuncitem: finish pytest_pyfunc_call --> True [hook] finish pytest_runtest_call --> [] [hook] pytest_runtest_makereport [hook] item: call: finish pytest_runtest_makereport --> [hook] pytest_runtest_logreport [hook] report: pytest_report_teststatus [hook] report: config: <_pytest.config.Config object at 0x7f1da3c09270> finish pytest_report_teststatus --> ('passed', '.', 'PASSED') [hook] finish pytest_runtest_logreport --> [] [hook] pytest_runtest_teardown [hook] item: nextitem: finish pytest_runtest_teardown --> [] [hook] pytest_runtest_makereport [hook] item: call: finish pytest_runtest_makereport --> [hook] pytest_runtest_logreport [hook] report: pytest_report_teststatus [hook] report: config: <_pytest.config.Config object at 0x7f1da3c09270> finish pytest_report_teststatus --> ('', '', '') [hook] finish pytest_runtest_logreport --> [] [hook] pytest_runtest_logfinish [hook] nodeid: tests/test_import.py::test_aes_pycryptodome location: ('tests/test_import.py', 12, 'test_aes_pycryptodome') finish pytest_runtest_logfinish --> [] [hook] finish pytest_runtest_protocol --> True [hook] pytest_runtest_protocol [hook] item: nextitem: pytest_runtest_logstart [hook] nodeid: tests/test_import.py::test_aes_cryptography location: ('tests/test_import.py', 17, 'test_aes_cryptography') finish pytest_runtest_logstart --> [] [hook] pytest_runtest_setup [hook] item: finish pytest_runtest_setup --> [] [hook] pytest_runtest_makereport [hook] item: call: finish pytest_runtest_makereport --> [hook] pytest_runtest_logreport [hook] report: pytest_report_teststatus [hook] report: config: <_pytest.config.Config object at 0x7f1da3c09270> finish pytest_report_teststatus --> ('', '', '') [hook] finish pytest_runtest_logreport --> [] [hook] pytest_runtest_call [hook] item: pytest_pyfunc_call [hook] pyfuncitem: finish pytest_pyfunc_call --> True [hook] finish pytest_runtest_call --> [] [hook] pytest_runtest_makereport [hook] item: call: finish pytest_runtest_makereport --> [hook] pytest_runtest_logreport [hook] report: pytest_report_teststatus [hook] report: config: <_pytest.config.Config object at 0x7f1da3c09270> finish pytest_report_teststatus --> ('passed', '.', 'PASSED') [hook] finish pytest_runtest_logreport --> [] [hook] pytest_runtest_teardown [hook] item: nextitem: finish pytest_runtest_teardown --> [] [hook] pytest_runtest_makereport [hook] item: call: finish pytest_runtest_makereport --> [hook] pytest_runtest_logreport [hook] report: pytest_report_teststatus [hook] report: config: <_pytest.config.Config object at 0x7f1da3c09270> finish pytest_report_teststatus --> ('', '', '') [hook] finish pytest_runtest_logreport --> [] [hook] pytest_runtest_logfinish [hook] nodeid: tests/test_import.py::test_aes_cryptography location: ('tests/test_import.py', 17, 'test_aes_cryptography') finish pytest_runtest_logfinish --> [] [hook] finish pytest_runtest_protocol --> True [hook] pytest_runtest_protocol [hook] item: nextitem: pytest_runtest_logstart [hook] nodeid: tests/test_import.py::test_aes_pure location: ('tests/test_import.py', 22, 'test_aes_pure') finish pytest_runtest_logstart --> [] [hook] pytest_runtest_setup [hook] item: finish pytest_runtest_setup --> [] [hook] pytest_runtest_makereport [hook] item: call: finish pytest_runtest_makereport --> [hook] pytest_runtest_logreport [hook] report: pytest_report_teststatus [hook] report: config: <_pytest.config.Config object at 0x7f1da3c09270> finish pytest_report_teststatus --> ('', '', '') [hook] finish pytest_runtest_logreport --> [] [hook] pytest_runtest_call [hook] item: pytest_pyfunc_call [hook] pyfuncitem: finish pytest_pyfunc_call --> True [hook] finish pytest_runtest_call --> [] [hook] pytest_runtest_makereport [hook] item: call: finish pytest_runtest_makereport --> [hook] pytest_runtest_logreport [hook] report: pytest_report_teststatus [hook] report: config: <_pytest.config.Config object at 0x7f1da3c09270> finish pytest_report_teststatus --> ('passed', '.', 'PASSED') [hook] finish pytest_runtest_logreport --> [] [hook] pytest_runtest_teardown [hook] item: nextitem: finish pytest_runtest_teardown --> [] [hook] pytest_runtest_makereport [hook] item: call: finish pytest_runtest_makereport --> [hook] pytest_runtest_logreport [hook] report: pytest_report_teststatus [hook] report: config: <_pytest.config.Config object at 0x7f1da3c09270> finish pytest_report_teststatus --> ('', '', '') [hook] finish pytest_runtest_logreport --> [] [hook] pytest_runtest_logfinish [hook] nodeid: tests/test_import.py::test_aes_pure location: ('tests/test_import.py', 22, 'test_aes_pure') finish pytest_runtest_logfinish --> [] [hook] finish pytest_runtest_protocol --> True [hook] pytest_runtest_protocol [hook] item: nextitem: pytest_runtest_logstart [hook] nodeid: tests/test_import.py::test_rc4_mbedtls location: ('tests/test_import.py', 103, 'test_rc4_mbedtls') finish pytest_runtest_logstart --> [] [hook] pytest_runtest_setup [hook] item: finish pytest_runtest_setup --> [] [hook] pytest_runtest_makereport [hook] item: call: finish pytest_runtest_makereport --> [hook] pytest_runtest_logreport [hook] report: pytest_report_teststatus [hook] report: config: <_pytest.config.Config object at 0x7f1da3c09270> finish pytest_report_teststatus --> ('', '', '') [hook] finish pytest_runtest_logreport --> [] [hook] pytest_runtest_call [hook] item: pytest_pyfunc_call [hook] pyfuncitem: finish pytest_pyfunc_call --> True [hook] finish pytest_runtest_call --> [] [hook] pytest_runtest_makereport [hook] item: call: finish pytest_runtest_makereport --> [hook] pytest_runtest_logreport [hook] report: pytest_report_teststatus [hook] report: config: <_pytest.config.Config object at 0x7f1da3c09270> finish pytest_report_teststatus --> ('passed', '.', 'PASSED') [hook] finish pytest_runtest_logreport --> [] [hook] pytest_runtest_teardown [hook] item: nextitem: finish pytest_runtest_teardown --> [] [hook] pytest_runtest_makereport [hook] item: call: finish pytest_runtest_makereport --> [hook] pytest_runtest_logreport [hook] report: pytest_report_teststatus [hook] report: config: <_pytest.config.Config object at 0x7f1da3c09270> finish pytest_report_teststatus --> ('', '', '') [hook] finish pytest_runtest_logreport --> [] [hook] pytest_runtest_logfinish [hook] nodeid: tests/test_import.py::test_rc4_mbedtls location: ('tests/test_import.py', 103, 'test_rc4_mbedtls') finish pytest_runtest_logfinish --> [] [hook] finish pytest_runtest_protocol --> True [hook] pytest_runtest_protocol [hook] item: nextitem: pytest_runtest_logstart [hook] nodeid: tests/test_import.py::test_rc4_pycryptodome location: ('tests/test_import.py', 108, 'test_rc4_pycryptodome') finish pytest_runtest_logstart --> [] [hook] pytest_runtest_setup [hook] item: finish pytest_runtest_setup --> [] [hook] pytest_runtest_makereport [hook] item: call: finish pytest_runtest_makereport --> [hook] pytest_runtest_logreport [hook] report: pytest_report_teststatus [hook] report: config: <_pytest.config.Config object at 0x7f1da3c09270> finish pytest_report_teststatus --> ('', '', '') [hook] finish pytest_runtest_logreport --> [] [hook] pytest_runtest_call [hook] item: pytest_pyfunc_call [hook] pyfuncitem: finish pytest_pyfunc_call --> True [hook] finish pytest_runtest_call --> [] [hook] pytest_runtest_makereport [hook] item: call: finish pytest_runtest_makereport --> [hook] pytest_runtest_logreport [hook] report: pytest_report_teststatus [hook] report: config: <_pytest.config.Config object at 0x7f1da3c09270> finish pytest_report_teststatus --> ('passed', '.', 'PASSED') [hook] finish pytest_runtest_logreport --> [] [hook] pytest_runtest_teardown [hook] item: nextitem: finish pytest_runtest_teardown --> [] [hook] pytest_runtest_makereport [hook] item: call: finish pytest_runtest_makereport --> [hook] pytest_runtest_logreport [hook] report: pytest_report_teststatus [hook] report: config: <_pytest.config.Config object at 0x7f1da3c09270> finish pytest_report_teststatus --> ('', '', '') [hook] finish pytest_runtest_logreport --> [] [hook] pytest_runtest_logfinish [hook] nodeid: tests/test_import.py::test_rc4_pycryptodome location: ('tests/test_import.py', 108, 'test_rc4_pycryptodome') finish pytest_runtest_logfinish --> [] [hook] finish pytest_runtest_protocol --> True [hook] pytest_runtest_protocol [hook] item: nextitem: pytest_runtest_logstart [hook] nodeid: tests/test_import.py::test_rc4_cryptography location: ('tests/test_import.py', 113, 'test_rc4_cryptography') finish pytest_runtest_logstart --> [] [hook] pytest_runtest_setup [hook] item: finish pytest_runtest_setup --> [] [hook] pytest_runtest_makereport [hook] item: call: finish pytest_runtest_makereport --> [hook] pytest_runtest_logreport [hook] report: pytest_report_teststatus [hook] report: config: <_pytest.config.Config object at 0x7f1da3c09270> finish pytest_report_teststatus --> ('', '', '') [hook] finish pytest_runtest_logreport --> [] [hook] pytest_runtest_call [hook] item: pytest_pyfunc_call [hook] pyfuncitem: finish pytest_pyfunc_call --> True [hook] finish pytest_runtest_call --> [] [hook] pytest_runtest_makereport [hook] item: call: finish pytest_runtest_makereport --> [hook] pytest_runtest_logreport [hook] report: pytest_report_teststatus [hook] report: config: <_pytest.config.Config object at 0x7f1da3c09270> finish pytest_report_teststatus --> ('passed', '.', 'PASSED') [hook] finish pytest_runtest_logreport --> [] [hook] pytest_runtest_teardown [hook] item: nextitem: finish pytest_runtest_teardown --> [] [hook] pytest_runtest_makereport [hook] item: call: finish pytest_runtest_makereport --> [hook] pytest_runtest_logreport [hook] report: pytest_report_teststatus [hook] report: config: <_pytest.config.Config object at 0x7f1da3c09270> finish pytest_report_teststatus --> ('', '', '') [hook] finish pytest_runtest_logreport --> [] [hook] pytest_runtest_logfinish [hook] nodeid: tests/test_import.py::test_rc4_cryptography location: ('tests/test_import.py', 113, 'test_rc4_cryptography') finish pytest_runtest_logfinish --> [] [hook] finish pytest_runtest_protocol --> True [hook] pytest_runtest_protocol [hook] item: nextitem: pytest_runtest_logstart [hook] nodeid: tests/test_import.py::test_rc4_pure location: ('tests/test_import.py', 118, 'test_rc4_pure') finish pytest_runtest_logstart --> [] [hook] pytest_runtest_setup [hook] item: finish pytest_runtest_setup --> [] [hook] pytest_runtest_makereport [hook] item: call: finish pytest_runtest_makereport --> [hook] pytest_runtest_logreport [hook] report: pytest_report_teststatus [hook] report: config: <_pytest.config.Config object at 0x7f1da3c09270> finish pytest_report_teststatus --> ('', '', '') [hook] finish pytest_runtest_logreport --> [] [hook] pytest_runtest_call [hook] item: pytest_pyfunc_call [hook] pyfuncitem: finish pytest_pyfunc_call --> True [hook] finish pytest_runtest_call --> [] [hook] pytest_runtest_makereport [hook] item: call: finish pytest_runtest_makereport --> [hook] pytest_runtest_logreport [hook] report: pytest_report_teststatus [hook] report: config: <_pytest.config.Config object at 0x7f1da3c09270> finish pytest_report_teststatus --> ('passed', '.', 'PASSED') [hook] finish pytest_runtest_logreport --> [] [hook] pytest_runtest_teardown [hook] item: nextitem: finish pytest_runtest_teardown --> [] [hook] pytest_runtest_makereport [hook] item: call: finish pytest_runtest_makereport --> [hook] pytest_runtest_logreport [hook] report: pytest_report_teststatus [hook] report: config: <_pytest.config.Config object at 0x7f1da3c09270> finish pytest_report_teststatus --> ('', '', '') [hook] finish pytest_runtest_logreport --> [] [hook] pytest_runtest_logfinish [hook] nodeid: tests/test_import.py::test_rc4_pure location: ('tests/test_import.py', 118, 'test_rc4_pure') finish pytest_runtest_logfinish --> [] [hook] finish pytest_runtest_protocol --> True [hook] pytest_runtest_protocol [hook] item: nextitem: pytest_runtest_logstart [hook] nodeid: tests/test_import.py::test_rc4_pycryptodomex location: ('tests/test_import.py', 123, 'test_rc4_pycryptodomex') finish pytest_runtest_logstart --> [] [hook] pytest_runtest_setup [hook] item: finish pytest_runtest_setup --> [] [hook] pytest_runtest_makereport [hook] item: call: finish pytest_runtest_makereport --> [hook] pytest_runtest_logreport [hook] report: pytest_report_teststatus [hook] report: config: <_pytest.config.Config object at 0x7f1da3c09270> finish pytest_report_teststatus --> ('', '', '') [hook] finish pytest_runtest_logreport --> [] [hook] pytest_runtest_call [hook] item: pytest_pyfunc_call [hook] pyfuncitem: finish pytest_pyfunc_call --> True [hook] finish pytest_runtest_call --> [] [hook] pytest_runtest_makereport [hook] item: call: finish pytest_runtest_makereport --> [hook] pytest_runtest_logreport [hook] report: pytest_report_teststatus [hook] report: config: <_pytest.config.Config object at 0x7f1da3c09270> finish pytest_report_teststatus --> ('passed', '.', 'PASSED') [hook] finish pytest_runtest_logreport --> [] [hook] pytest_runtest_teardown [hook] item: nextitem: finish pytest_runtest_teardown --> [] [hook] pytest_runtest_makereport [hook] item: call: finish pytest_runtest_makereport --> [hook] pytest_runtest_logreport [hook] report: pytest_report_teststatus [hook] report: config: <_pytest.config.Config object at 0x7f1da3c09270> finish pytest_report_teststatus --> ('', '', '') [hook] finish pytest_runtest_logreport --> [] [hook] pytest_runtest_logfinish [hook] nodeid: tests/test_import.py::test_rc4_pycryptodomex location: ('tests/test_import.py', 123, 'test_rc4_pycryptodomex') finish pytest_runtest_logfinish --> [] [hook] finish pytest_runtest_protocol --> True [hook] pytest_runtest_protocol [hook] item: nextitem: pytest_runtest_logstart [hook] nodeid: tests/test_import.py::test_des_mbedtls location: ('tests/test_import.py', 52, 'test_des_mbedtls') finish pytest_runtest_logstart --> [] [hook] pytest_runtest_setup [hook] item: finish pytest_runtest_setup --> [] [hook] pytest_runtest_makereport [hook] item: call: finish pytest_runtest_makereport --> [hook] pytest_runtest_logreport [hook] report: pytest_report_teststatus [hook] report: config: <_pytest.config.Config object at 0x7f1da3c09270> finish pytest_report_teststatus --> ('', '', '') [hook] finish pytest_runtest_logreport --> [] [hook] pytest_runtest_call [hook] item: pytest_pyfunc_call [hook] pyfuncitem: finish pytest_pyfunc_call --> True [hook] finish pytest_runtest_call --> [] [hook] pytest_runtest_makereport [hook] item: call: finish pytest_runtest_makereport --> [hook] pytest_runtest_logreport [hook] report: pytest_report_teststatus [hook] report: config: <_pytest.config.Config object at 0x7f1da3c09270> finish pytest_report_teststatus --> ('passed', '.', 'PASSED') [hook] finish pytest_runtest_logreport --> [] [hook] pytest_runtest_teardown [hook] item: nextitem: finish pytest_runtest_teardown --> [] [hook] pytest_runtest_makereport [hook] item: call: finish pytest_runtest_makereport --> [hook] pytest_runtest_logreport [hook] report: pytest_report_teststatus [hook] report: config: <_pytest.config.Config object at 0x7f1da3c09270> finish pytest_report_teststatus --> ('', '', '') [hook] finish pytest_runtest_logreport --> [] [hook] pytest_runtest_logfinish [hook] nodeid: tests/test_import.py::test_des_mbedtls location: ('tests/test_import.py', 52, 'test_des_mbedtls') finish pytest_runtest_logfinish --> [] [hook] finish pytest_runtest_protocol --> True [hook] pytest_runtest_protocol [hook] item: nextitem: pytest_runtest_logstart [hook] nodeid: tests/test_import.py::test_des_pycryptodome location: ('tests/test_import.py', 57, 'test_des_pycryptodome') finish pytest_runtest_logstart --> [] [hook] pytest_runtest_setup [hook] item: finish pytest_runtest_setup --> [] [hook] pytest_runtest_makereport [hook] item: call: finish pytest_runtest_makereport --> [hook] pytest_runtest_logreport [hook] report: pytest_report_teststatus [hook] report: config: <_pytest.config.Config object at 0x7f1da3c09270> finish pytest_report_teststatus --> ('', '', '') [hook] finish pytest_runtest_logreport --> [] [hook] pytest_runtest_call [hook] item: pytest_pyfunc_call [hook] pyfuncitem: finish pytest_pyfunc_call --> True [hook] finish pytest_runtest_call --> [] [hook] pytest_runtest_makereport [hook] item: call: finish pytest_runtest_makereport --> [hook] pytest_runtest_logreport [hook] report: pytest_report_teststatus [hook] report: config: <_pytest.config.Config object at 0x7f1da3c09270> finish pytest_report_teststatus --> ('passed', '.', 'PASSED') [hook] finish pytest_runtest_logreport --> [] [hook] pytest_runtest_teardown [hook] item: nextitem: finish pytest_runtest_teardown --> [] [hook] pytest_runtest_makereport [hook] item: call: finish pytest_runtest_makereport --> [hook] pytest_runtest_logreport [hook] report: pytest_report_teststatus [hook] report: config: <_pytest.config.Config object at 0x7f1da3c09270> finish pytest_report_teststatus --> ('', '', '') [hook] finish pytest_runtest_logreport --> [] [hook] pytest_runtest_logfinish [hook] nodeid: tests/test_import.py::test_des_pycryptodome location: ('tests/test_import.py', 57, 'test_des_pycryptodome') finish pytest_runtest_logfinish --> [] [hook] finish pytest_runtest_protocol --> True [hook] pytest_runtest_protocol [hook] item: nextitem: pytest_runtest_logstart [hook] nodeid: tests/test_import.py::test_des_cryptography location: ('tests/test_import.py', 62, 'test_des_cryptography') finish pytest_runtest_logstart --> [] [hook] pytest_runtest_setup [hook] item: finish pytest_runtest_setup --> [] [hook] pytest_runtest_makereport [hook] item: call: finish pytest_runtest_makereport --> [hook] pytest_runtest_logreport [hook] report: pytest_report_teststatus [hook] report: config: <_pytest.config.Config object at 0x7f1da3c09270> finish pytest_report_teststatus --> ('', '', '') [hook] finish pytest_runtest_logreport --> [] [hook] pytest_runtest_call [hook] item: pytest_pyfunc_call [hook] pyfuncitem: finish pytest_pyfunc_call --> True [hook] finish pytest_runtest_call --> [] [hook] pytest_runtest_makereport [hook] item: call: finish pytest_runtest_makereport --> [hook] pytest_runtest_logreport [hook] report: pytest_report_teststatus [hook] report: config: <_pytest.config.Config object at 0x7f1da3c09270> finish pytest_report_teststatus --> ('passed', '.', 'PASSED') [hook] finish pytest_runtest_logreport --> [] [hook] pytest_runtest_teardown [hook] item: nextitem: finish pytest_runtest_teardown --> [] [hook] pytest_runtest_makereport [hook] item: call: finish pytest_runtest_makereport --> [hook] pytest_runtest_logreport [hook] report: pytest_report_teststatus [hook] report: config: <_pytest.config.Config object at 0x7f1da3c09270> finish pytest_report_teststatus --> ('', '', '') [hook] finish pytest_runtest_logreport --> [] [hook] pytest_runtest_logfinish [hook] nodeid: tests/test_import.py::test_des_cryptography location: ('tests/test_import.py', 62, 'test_des_cryptography') finish pytest_runtest_logfinish --> [] [hook] finish pytest_runtest_protocol --> True [hook] pytest_runtest_protocol [hook] item: nextitem: pytest_runtest_logstart [hook] nodeid: tests/test_import.py::test_des_pure location: ('tests/test_import.py', 67, 'test_des_pure') finish pytest_runtest_logstart --> [] [hook] pytest_runtest_setup [hook] item: finish pytest_runtest_setup --> [] [hook] pytest_runtest_makereport [hook] item: call: finish pytest_runtest_makereport --> [hook] pytest_runtest_logreport [hook] report: pytest_report_teststatus [hook] report: config: <_pytest.config.Config object at 0x7f1da3c09270> finish pytest_report_teststatus --> ('', '', '') [hook] finish pytest_runtest_logreport --> [] [hook] pytest_runtest_call [hook] item: pytest_pyfunc_call [hook] pyfuncitem: finish pytest_pyfunc_call --> True [hook] finish pytest_runtest_call --> [] [hook] pytest_runtest_makereport [hook] item: call: finish pytest_runtest_makereport --> [hook] pytest_runtest_logreport [hook] report: pytest_report_teststatus [hook] report: config: <_pytest.config.Config object at 0x7f1da3c09270> finish pytest_report_teststatus --> ('passed', '.', 'PASSED') [hook] finish pytest_runtest_logreport --> [] [hook] pytest_runtest_teardown [hook] item: nextitem: finish pytest_runtest_teardown --> [] [hook] pytest_runtest_makereport [hook] item: call: finish pytest_runtest_makereport --> [hook] pytest_runtest_logreport [hook] report: pytest_report_teststatus [hook] report: config: <_pytest.config.Config object at 0x7f1da3c09270> finish pytest_report_teststatus --> ('', '', '') [hook] finish pytest_runtest_logreport --> [] [hook] pytest_runtest_logfinish [hook] nodeid: tests/test_import.py::test_des_pure location: ('tests/test_import.py', 67, 'test_des_pure') finish pytest_runtest_logfinish --> [] [hook] finish pytest_runtest_protocol --> True [hook] pytest_runtest_protocol [hook] item: nextitem: pytest_runtest_logstart [hook] nodeid: tests/test_import.py::test_des_pycryptodomex location: ('tests/test_import.py', 72, 'test_des_pycryptodomex') finish pytest_runtest_logstart --> [] [hook] pytest_runtest_setup [hook] item: finish pytest_runtest_setup --> [] [hook] pytest_runtest_makereport [hook] item: call: finish pytest_runtest_makereport --> [hook] pytest_runtest_logreport [hook] report: pytest_report_teststatus [hook] report: config: <_pytest.config.Config object at 0x7f1da3c09270> finish pytest_report_teststatus --> ('', '', '') [hook] finish pytest_runtest_logreport --> [] [hook] pytest_runtest_call [hook] item: pytest_pyfunc_call [hook] pyfuncitem: finish pytest_pyfunc_call --> True [hook] finish pytest_runtest_call --> [] [hook] pytest_runtest_makereport [hook] item: call: finish pytest_runtest_makereport --> [hook] pytest_runtest_logreport [hook] report: pytest_report_teststatus [hook] report: config: <_pytest.config.Config object at 0x7f1da3c09270> finish pytest_report_teststatus --> ('passed', '.', 'PASSED') [hook] finish pytest_runtest_logreport --> [] [hook] pytest_runtest_teardown [hook] item: nextitem: finish pytest_runtest_teardown --> [] [hook] pytest_runtest_makereport [hook] item: call: finish pytest_runtest_makereport --> [hook] pytest_runtest_logreport [hook] report: pytest_report_teststatus [hook] report: config: <_pytest.config.Config object at 0x7f1da3c09270> finish pytest_report_teststatus --> ('', '', '') [hook] finish pytest_runtest_logreport --> [] [hook] pytest_runtest_logfinish [hook] nodeid: tests/test_import.py::test_des_pycryptodomex location: ('tests/test_import.py', 72, 'test_des_pycryptodomex') finish pytest_runtest_logfinish --> [] [hook] finish pytest_runtest_protocol --> True [hook] pytest_runtest_protocol [hook] item: nextitem: pytest_runtest_logstart [hook] nodeid: tests/test_import.py::test_tdes_mbedtls location: ('tests/test_import.py', 78, 'test_tdes_mbedtls') finish pytest_runtest_logstart --> [] [hook] pytest_runtest_setup [hook] item: finish pytest_runtest_setup --> [] [hook] pytest_runtest_makereport [hook] item: call: finish pytest_runtest_makereport --> [hook] pytest_runtest_logreport [hook] report: pytest_report_teststatus [hook] report: config: <_pytest.config.Config object at 0x7f1da3c09270> finish pytest_report_teststatus --> ('', '', '') [hook] finish pytest_runtest_logreport --> [] [hook] pytest_runtest_call [hook] item: pytest_pyfunc_call [hook] pyfuncitem: finish pytest_pyfunc_call --> True [hook] finish pytest_runtest_call --> [] [hook] pytest_runtest_makereport [hook] item: call: finish pytest_runtest_makereport --> [hook] pytest_runtest_logreport [hook] report: pytest_report_teststatus [hook] report: config: <_pytest.config.Config object at 0x7f1da3c09270> finish pytest_report_teststatus --> ('passed', '.', 'PASSED') [hook] finish pytest_runtest_logreport --> [] [hook] pytest_runtest_teardown [hook] item: nextitem: finish pytest_runtest_teardown --> [] [hook] pytest_runtest_makereport [hook] item: call: finish pytest_runtest_makereport --> [hook] pytest_runtest_logreport [hook] report: pytest_report_teststatus [hook] report: config: <_pytest.config.Config object at 0x7f1da3c09270> finish pytest_report_teststatus --> ('', '', '') [hook] finish pytest_runtest_logreport --> [] [hook] pytest_runtest_logfinish [hook] nodeid: tests/test_import.py::test_tdes_mbedtls location: ('tests/test_import.py', 78, 'test_tdes_mbedtls') finish pytest_runtest_logfinish --> [] [hook] finish pytest_runtest_protocol --> True [hook] pytest_runtest_protocol [hook] item: nextitem: pytest_runtest_logstart [hook] nodeid: tests/test_import.py::test_tdes_pycryptodome location: ('tests/test_import.py', 83, 'test_tdes_pycryptodome') finish pytest_runtest_logstart --> [] [hook] pytest_runtest_setup [hook] item: finish pytest_runtest_setup --> [] [hook] pytest_runtest_makereport [hook] item: call: finish pytest_runtest_makereport --> [hook] pytest_runtest_logreport [hook] report: pytest_report_teststatus [hook] report: config: <_pytest.config.Config object at 0x7f1da3c09270> finish pytest_report_teststatus --> ('', '', '') [hook] finish pytest_runtest_logreport --> [] [hook] pytest_runtest_call [hook] item: pytest_pyfunc_call [hook] pyfuncitem: finish pytest_pyfunc_call --> True [hook] finish pytest_runtest_call --> [] [hook] pytest_runtest_makereport [hook] item: call: finish pytest_runtest_makereport --> [hook] pytest_runtest_logreport [hook] report: pytest_report_teststatus [hook] report: config: <_pytest.config.Config object at 0x7f1da3c09270> finish pytest_report_teststatus --> ('passed', '.', 'PASSED') [hook] finish pytest_runtest_logreport --> [] [hook] pytest_runtest_teardown [hook] item: nextitem: finish pytest_runtest_teardown --> [] [hook] pytest_runtest_makereport [hook] item: call: finish pytest_runtest_makereport --> [hook] pytest_runtest_logreport [hook] report: pytest_report_teststatus [hook] report: config: <_pytest.config.Config object at 0x7f1da3c09270> finish pytest_report_teststatus --> ('', '', '') [hook] finish pytest_runtest_logreport --> [] [hook] pytest_runtest_logfinish [hook] nodeid: tests/test_import.py::test_tdes_pycryptodome location: ('tests/test_import.py', 83, 'test_tdes_pycryptodome') finish pytest_runtest_logfinish --> [] [hook] finish pytest_runtest_protocol --> True [hook] pytest_runtest_protocol [hook] item: nextitem: pytest_runtest_logstart [hook] nodeid: tests/test_import.py::test_tdes_cryptography location: ('tests/test_import.py', 88, 'test_tdes_cryptography') finish pytest_runtest_logstart --> [] [hook] pytest_runtest_setup [hook] item: finish pytest_runtest_setup --> [] [hook] pytest_runtest_makereport [hook] item: call: finish pytest_runtest_makereport --> [hook] pytest_runtest_logreport [hook] report: pytest_report_teststatus [hook] report: config: <_pytest.config.Config object at 0x7f1da3c09270> finish pytest_report_teststatus --> ('', '', '') [hook] finish pytest_runtest_logreport --> [] [hook] pytest_runtest_call [hook] item: pytest_pyfunc_call [hook] pyfuncitem: finish pytest_pyfunc_call --> True [hook] finish pytest_runtest_call --> [] [hook] pytest_runtest_makereport [hook] item: call: finish pytest_runtest_makereport --> [hook] pytest_runtest_logreport [hook] report: pytest_report_teststatus [hook] report: config: <_pytest.config.Config object at 0x7f1da3c09270> finish pytest_report_teststatus --> ('passed', '.', 'PASSED') [hook] finish pytest_runtest_logreport --> [] [hook] pytest_runtest_teardown [hook] item: nextitem: finish pytest_runtest_teardown --> [] [hook] pytest_runtest_makereport [hook] item: call: finish pytest_runtest_makereport --> [hook] pytest_runtest_logreport [hook] report: pytest_report_teststatus [hook] report: config: <_pytest.config.Config object at 0x7f1da3c09270> finish pytest_report_teststatus --> ('', '', '') [hook] finish pytest_runtest_logreport --> [] [hook] pytest_runtest_logfinish [hook] nodeid: tests/test_import.py::test_tdes_cryptography location: ('tests/test_import.py', 88, 'test_tdes_cryptography') finish pytest_runtest_logfinish --> [] [hook] finish pytest_runtest_protocol --> True [hook] pytest_runtest_protocol [hook] item: nextitem: pytest_runtest_logstart [hook] nodeid: tests/test_import.py::test_tdes_pure location: ('tests/test_import.py', 93, 'test_tdes_pure') finish pytest_runtest_logstart --> [] [hook] pytest_runtest_setup [hook] item: finish pytest_runtest_setup --> [] [hook] pytest_runtest_makereport [hook] item: call: finish pytest_runtest_makereport --> [hook] pytest_runtest_logreport [hook] report: pytest_report_teststatus [hook] report: config: <_pytest.config.Config object at 0x7f1da3c09270> finish pytest_report_teststatus --> ('', '', '') [hook] finish pytest_runtest_logreport --> [] [hook] pytest_runtest_call [hook] item: pytest_pyfunc_call [hook] pyfuncitem: finish pytest_pyfunc_call --> True [hook] finish pytest_runtest_call --> [] [hook] pytest_runtest_makereport [hook] item: call: finish pytest_runtest_makereport --> [hook] pytest_runtest_logreport [hook] report: pytest_report_teststatus [hook] report: config: <_pytest.config.Config object at 0x7f1da3c09270> finish pytest_report_teststatus --> ('passed', '.', 'PASSED') [hook] finish pytest_runtest_logreport --> [] [hook] pytest_runtest_teardown [hook] item: nextitem: finish pytest_runtest_teardown --> [] [hook] pytest_runtest_makereport [hook] item: call: finish pytest_runtest_makereport --> [hook] pytest_runtest_logreport [hook] report: pytest_report_teststatus [hook] report: config: <_pytest.config.Config object at 0x7f1da3c09270> finish pytest_report_teststatus --> ('', '', '') [hook] finish pytest_runtest_logreport --> [] [hook] pytest_runtest_logfinish [hook] nodeid: tests/test_import.py::test_tdes_pure location: ('tests/test_import.py', 93, 'test_tdes_pure') finish pytest_runtest_logfinish --> [] [hook] finish pytest_runtest_protocol --> True [hook] pytest_runtest_protocol [hook] item: nextitem: pytest_runtest_logstart [hook] nodeid: tests/test_import.py::test_tdes_pycryptodomex location: ('tests/test_import.py', 98, 'test_tdes_pycryptodomex') finish pytest_runtest_logstart --> [] [hook] pytest_runtest_setup [hook] item: finish pytest_runtest_setup --> [] [hook] pytest_runtest_makereport [hook] item: call: finish pytest_runtest_makereport --> [hook] pytest_runtest_logreport [hook] report: pytest_report_teststatus [hook] report: config: <_pytest.config.Config object at 0x7f1da3c09270> finish pytest_report_teststatus --> ('', '', '') [hook] finish pytest_runtest_logreport --> [] [hook] pytest_runtest_call [hook] item: pytest_pyfunc_call [hook] pyfuncitem: finish pytest_pyfunc_call --> True [hook] finish pytest_runtest_call --> [] [hook] pytest_runtest_makereport [hook] item: call: finish pytest_runtest_makereport --> [hook] pytest_runtest_logreport [hook] report: pytest_report_teststatus [hook] report: config: <_pytest.config.Config object at 0x7f1da3c09270> finish pytest_report_teststatus --> ('passed', '.', 'PASSED') [hook] finish pytest_runtest_logreport --> [] [hook] pytest_runtest_teardown [hook] item: nextitem: finish pytest_runtest_teardown --> [] [hook] pytest_runtest_makereport [hook] item: call: finish pytest_runtest_makereport --> [hook] pytest_runtest_logreport [hook] report: pytest_report_teststatus [hook] report: config: <_pytest.config.Config object at 0x7f1da3c09270> finish pytest_report_teststatus --> ('', '', '') [hook] finish pytest_runtest_logreport --> [] [hook] pytest_runtest_logfinish [hook] nodeid: tests/test_import.py::test_tdes_pycryptodomex location: ('tests/test_import.py', 98, 'test_tdes_pycryptodomex') finish pytest_runtest_logfinish --> [] [hook] finish pytest_runtest_protocol --> True [hook] pytest_runtest_protocol [hook] item: nextitem: pytest_runtest_logstart [hook] nodeid: tests/test_pbkdf2.py::test_sha1 location: ('tests/test_pbkdf2.py', 28, 'test_sha1') finish pytest_runtest_logstart --> [] [hook] pytest_runtest_setup [hook] item: finish pytest_runtest_setup --> [] [hook] pytest_runtest_makereport [hook] item: call: finish pytest_runtest_makereport --> [hook] pytest_runtest_logreport [hook] report: pytest_report_teststatus [hook] report: config: <_pytest.config.Config object at 0x7f1da3c09270> finish pytest_report_teststatus --> ('', '', '') [hook] finish pytest_runtest_logreport --> [] [hook] pytest_runtest_call [hook] item: pytest_pyfunc_call [hook] pyfuncitem: finish pytest_pyfunc_call --> True [hook] finish pytest_runtest_call --> [] [hook] pytest_runtest_makereport [hook] item: call: finish pytest_runtest_makereport --> [hook] pytest_runtest_logreport [hook] report: pytest_report_teststatus [hook] report: config: <_pytest.config.Config object at 0x7f1da3c09270> finish pytest_report_teststatus --> ('passed', '.', 'PASSED') [hook] finish pytest_runtest_logreport --> [] [hook] pytest_runtest_teardown [hook] item: nextitem: finish pytest_runtest_teardown --> [] [hook] pytest_runtest_makereport [hook] item: call: finish pytest_runtest_makereport --> [hook] pytest_runtest_logreport [hook] report: pytest_report_teststatus [hook] report: config: <_pytest.config.Config object at 0x7f1da3c09270> finish pytest_report_teststatus --> ('', '', '') [hook] finish pytest_runtest_logreport --> [] [hook] pytest_runtest_logfinish [hook] nodeid: tests/test_pbkdf2.py::test_sha1 location: ('tests/test_pbkdf2.py', 28, 'test_sha1') finish pytest_runtest_logfinish --> [] [hook] finish pytest_runtest_protocol --> True [hook] pytest_runtest_protocol [hook] item: nextitem: pytest_runtest_logstart [hook] nodeid: tests/test_rc4.py::test_rc4[RC4] location: ('tests/test_rc4.py', 68, 'test_rc4[RC4]') finish pytest_runtest_logstart --> [] [hook] pytest_runtest_setup [hook] item: pytest_fixture_setup [hook] fixturedef: request: > finish pytest_fixture_setup --> [hook] finish pytest_runtest_setup --> [] [hook] pytest_runtest_makereport [hook] item: call: finish pytest_runtest_makereport --> [hook] pytest_runtest_logreport [hook] report: pytest_report_teststatus [hook] report: config: <_pytest.config.Config object at 0x7f1da3c09270> finish pytest_report_teststatus --> ('', '', '') [hook] finish pytest_runtest_logreport --> [] [hook] pytest_runtest_call [hook] item: pytest_pyfunc_call [hook] pyfuncitem: early skip of rewriting module: cryptography.hazmat.backends.openssl [assertion] early skip of rewriting module: cryptography.hazmat.backends.openssl.backend [assertion] early skip of rewriting module: cryptography.x509 [assertion] early skip of rewriting module: cryptography.x509.certificate_transparency [assertion] early skip of rewriting module: cryptography.hazmat.primitives.hashes [assertion] early skip of rewriting module: cryptography.x509.base [assertion] early skip of rewriting module: cryptography.hazmat.primitives.serialization [assertion] early skip of rewriting module: cryptography.hazmat.primitives._serialization [assertion] early skip of rewriting module: cryptography.hazmat.primitives.serialization.base [assertion] early skip of rewriting module: cryptography.hazmat.primitives.asymmetric [assertion] early skip of rewriting module: cryptography.hazmat.primitives.asymmetric.dh [assertion] early skip of rewriting module: cryptography.hazmat.primitives.asymmetric.types [assertion] early skip of rewriting module: cryptography.hazmat.primitives.asymmetric.dsa [assertion] early skip of rewriting module: cryptography.hazmat.primitives.asymmetric.utils [assertion] early skip of rewriting module: cryptography.hazmat.primitives.asymmetric.ec [assertion] early skip of rewriting module: cryptography.hazmat._oid [assertion] early skip of rewriting module: cryptography.hazmat.primitives.asymmetric.ed448 [assertion] early skip of rewriting module: cryptography.hazmat.primitives.asymmetric.ed25519 [assertion] early skip of rewriting module: cryptography.hazmat.primitives.asymmetric.rsa [assertion] early skip of rewriting module: cryptography.hazmat.primitives._asymmetric [assertion] early skip of rewriting module: cryptography.hazmat.primitives.asymmetric.x448 [assertion] early skip of rewriting module: cryptography.hazmat.primitives.asymmetric.x25519 [assertion] early skip of rewriting module: cryptography.hazmat.primitives.serialization.ssh [assertion] early skip of rewriting module: bcrypt [assertion] early skip of rewriting module: cryptography.x509.extensions [assertion] early skip of rewriting module: ipaddress [assertion] early skip of rewriting module: cryptography.hazmat.primitives.constant_time [assertion] early skip of rewriting module: cryptography.x509.general_name [assertion] early skip of rewriting module: cryptography.x509.name [assertion] early skip of rewriting module: cryptography.x509.oid [assertion] early skip of rewriting module: cryptography.hazmat.backends.openssl.aead [assertion] early skip of rewriting module: cryptography.hazmat.backends.openssl.ciphers [assertion] early skip of rewriting module: cryptography.hazmat.backends.openssl.cmac [assertion] early skip of rewriting module: cryptography.hazmat.backends.openssl.dh [assertion] early skip of rewriting module: cryptography.hazmat.backends.openssl.dsa [assertion] early skip of rewriting module: cryptography.hazmat.backends.openssl.utils [assertion] early skip of rewriting module: cryptography.hazmat.backends.openssl.ec [assertion] early skip of rewriting module: cryptography.hazmat.backends.openssl.ed448 [assertion] early skip of rewriting module: cryptography.hazmat.backends.openssl.ed25519 [assertion] early skip of rewriting module: cryptography.hazmat.backends.openssl.hashes [assertion] early skip of rewriting module: cryptography.hazmat.backends.openssl.hmac [assertion] early skip of rewriting module: cryptography.hazmat.backends.openssl.poly1305 [assertion] early skip of rewriting module: cryptography.hazmat.backends.openssl.rsa [assertion] early skip of rewriting module: cryptography.hazmat.primitives.asymmetric.padding [assertion] early skip of rewriting module: cryptography.hazmat.backends.openssl.x448 [assertion] early skip of rewriting module: cryptography.hazmat.backends.openssl.x25519 [assertion] early skip of rewriting module: cryptography.hazmat.bindings.openssl [assertion] early skip of rewriting module: cryptography.hazmat.bindings.openssl.binding [assertion] early skip of rewriting module: cryptography.hazmat.bindings._openssl [assertion] early skip of rewriting module: cryptography.hazmat.bindings.openssl._conditional [assertion] early skip of rewriting module: cryptography.hazmat.primitives.kdf [assertion] early skip of rewriting module: cryptography.hazmat.primitives.kdf.scrypt [assertion] early skip of rewriting module: cryptography.hazmat.primitives.serialization.pkcs12 [assertion] finish pytest_pyfunc_call --> True [hook] finish pytest_runtest_call --> [] [hook] pytest_runtest_makereport [hook] item: call: finish pytest_runtest_makereport --> [hook] pytest_runtest_logreport [hook] report: pytest_report_teststatus [hook] report: config: <_pytest.config.Config object at 0x7f1da3c09270> finish pytest_report_teststatus --> ('passed', '.', 'PASSED') [hook] finish pytest_runtest_logreport --> [] [hook] pytest_runtest_teardown [hook] item: nextitem: pytest_fixture_post_finalizer [hook] fixturedef: request: > finish pytest_fixture_post_finalizer --> [] [hook] finish pytest_runtest_teardown --> [] [hook] pytest_runtest_makereport [hook] item: call: finish pytest_runtest_makereport --> [hook] pytest_runtest_logreport [hook] report: pytest_report_teststatus [hook] report: config: <_pytest.config.Config object at 0x7f1da3c09270> finish pytest_report_teststatus --> ('', '', '') [hook] finish pytest_runtest_logreport --> [] [hook] pytest_runtest_logfinish [hook] nodeid: tests/test_rc4.py::test_rc4[RC4] location: ('tests/test_rc4.py', 68, 'test_rc4[RC4]') finish pytest_runtest_logfinish --> [] [hook] finish pytest_runtest_protocol --> True [hook] pytest_runtest_protocol [hook] item: nextitem: pytest_runtest_logstart [hook] nodeid: tests/test_tdes.py::test_ecb[TDES] location: ('tests/test_tdes.py', 93, 'test_ecb[TDES]') finish pytest_runtest_logstart --> [] [hook] pytest_runtest_setup [hook] item: pytest_fixture_setup [hook] fixturedef: request: > finish pytest_fixture_setup --> [hook] finish pytest_runtest_setup --> [] [hook] pytest_runtest_makereport [hook] item: call: finish pytest_runtest_makereport --> [hook] pytest_runtest_logreport [hook] report: pytest_report_teststatus [hook] report: config: <_pytest.config.Config object at 0x7f1da3c09270> finish pytest_report_teststatus --> ('', '', '') [hook] finish pytest_runtest_logreport --> [] [hook] pytest_runtest_call [hook] item: pytest_pyfunc_call [hook] pyfuncitem: finish pytest_pyfunc_call --> True [hook] finish pytest_runtest_call --> [] [hook] pytest_runtest_makereport [hook] item: call: finish pytest_runtest_makereport --> [hook] pytest_runtest_logreport [hook] report: pytest_report_teststatus [hook] report: config: <_pytest.config.Config object at 0x7f1da3c09270> finish pytest_report_teststatus --> ('passed', '.', 'PASSED') [hook] finish pytest_runtest_logreport --> [] [hook] pytest_runtest_teardown [hook] item: nextitem: pytest_fixture_post_finalizer [hook] fixturedef: request: > finish pytest_fixture_post_finalizer --> [] [hook] finish pytest_runtest_teardown --> [] [hook] pytest_runtest_makereport [hook] item: call: finish pytest_runtest_makereport --> [hook] pytest_runtest_logreport [hook] report: pytest_report_teststatus [hook] report: config: <_pytest.config.Config object at 0x7f1da3c09270> finish pytest_report_teststatus --> ('', '', '') [hook] finish pytest_runtest_logreport --> [] [hook] pytest_runtest_logfinish [hook] nodeid: tests/test_tdes.py::test_ecb[TDES] location: ('tests/test_tdes.py', 93, 'test_ecb[TDES]') finish pytest_runtest_logfinish --> [] [hook] finish pytest_runtest_protocol --> True [hook] pytest_runtest_protocol [hook] item: nextitem: None pytest_runtest_logstart [hook] nodeid: tests/test_tdes.py::test_cbc[TDES] location: ('tests/test_tdes.py', 97, 'test_cbc[TDES]') finish pytest_runtest_logstart --> [] [hook] pytest_runtest_setup [hook] item: pytest_fixture_setup [hook] fixturedef: request: > finish pytest_fixture_setup --> [hook] finish pytest_runtest_setup --> [] [hook] pytest_runtest_makereport [hook] item: call: finish pytest_runtest_makereport --> [hook] pytest_runtest_logreport [hook] report: pytest_report_teststatus [hook] report: config: <_pytest.config.Config object at 0x7f1da3c09270> finish pytest_report_teststatus --> ('', '', '') [hook] finish pytest_runtest_logreport --> [] [hook] pytest_runtest_call [hook] item: pytest_pyfunc_call [hook] pyfuncitem: finish pytest_pyfunc_call --> True [hook] finish pytest_runtest_call --> [] [hook] pytest_runtest_makereport [hook] item: call: finish pytest_runtest_makereport --> [hook] pytest_runtest_logreport [hook] report: pytest_report_teststatus [hook] report: config: <_pytest.config.Config object at 0x7f1da3c09270> finish pytest_report_teststatus --> ('passed', '.', 'PASSED') [hook] finish pytest_runtest_logreport --> [] [hook] pytest_runtest_teardown [hook] item: nextitem: None pytest_fixture_post_finalizer [hook] fixturedef: request: > finish pytest_fixture_post_finalizer --> [] [hook] finish pytest_runtest_teardown --> [] [hook] pytest_runtest_makereport [hook] item: call: finish pytest_runtest_makereport --> [hook] pytest_runtest_logreport [hook] report: pytest_report_teststatus [hook] report: config: <_pytest.config.Config object at 0x7f1da3c09270> finish pytest_report_teststatus --> ('', '', '') [hook] finish pytest_runtest_logreport --> [] [hook] pytest_runtest_logfinish [hook] nodeid: tests/test_tdes.py::test_cbc[TDES] location: ('tests/test_tdes.py', 97, 'test_cbc[TDES]') finish pytest_runtest_logfinish --> [] [hook] finish pytest_runtest_protocol --> True [hook] finish pytest_runtestloop --> True [hook] pytest_sessionfinish [hook] session: exitstatus: 0 pytest_terminal_summary [hook] terminalreporter: <_pytest.terminal.TerminalReporter object at 0x7f1da350ea10> exitstatus: 0 config: <_pytest.config.Config object at 0x7f1da3c09270> finish pytest_terminal_summary --> [] [hook] finish pytest_sessionfinish --> [] [hook] pytest_unconfigure [hook] config: <_pytest.config.Config object at 0x7f1da3c09270> finish pytest_unconfigure --> [] [hook] unicrypto-0.0.10/unicrypto/000077500000000000000000000000001437177004600156715ustar00rootroot00000000000000unicrypto-0.0.10/unicrypto/__init__.py000066400000000000000000000053361437177004600200110ustar00rootroot00000000000000import importlib import importlib.util import logging logger = logging.getLogger(__name__) handler = logging.StreamHandler() formatter = logging.Formatter('%(asctime)s %(name)-12s %(levelname)-8s %(message)s') handler.setFormatter(formatter) logger.addHandler(handler) logger.setLevel(logging.INFO) #https://stackoverflow.com/questions/8790003/dynamically-import-a-method-in-a-file-from-a-string def import_from(module, name): module = __import__(module, fromlist=[name]) return getattr(module, name) pref_to_module = { 'mbedtls' : 'mbedtls', 'cryptography' : 'cryptography', 'pyCryptodomex': 'Cryptodome', # see https://github.com/Legrandin/pycryptodome/blob/master/Changelog.rst#30-24-june-2014 'pyCryptodome': 'Crypto.Cipher.Salsa20', 'pyCrypto' : 'Crypto.Random.OSRNG' } # preferred modules for each cipher, in order of preferance preftable = { 'DES' : ['pyCryptodomex','pyCryptodome','cryptography','pyCrypto','mbedtls','pure'], 'TDES': ['pyCryptodomex','pyCryptodome','cryptography','pyCrypto','mbedtls','pure'], 'AES' : ['pyCryptodomex','pyCryptodome','cryptography','pyCrypto','mbedtls','pure'], 'RC4' : ['pyCryptodomex','pyCryptodome','cryptography','pyCrypto','mbedtls','pure'], } available_modules = { 'DES' : ['pure'], 'TDES' : ['pure'], 'AES' : ['pure'], 'RC4' : ['pure'], } override_library = None for prefname in pref_to_module: try: importlib.util.find_spec(pref_to_module[prefname]) except ModuleNotFoundError: continue if importlib.util.find_spec(pref_to_module[prefname]) is not None: for k in available_modules: available_modules[k].append(prefname) def get_cipher_by_name(ciphername, cryptolibname): logging.debug('symmetric using "%s" for "%s"' % (cryptolibname, ciphername)) moduleName = 'unicrypto.backends.%s.%s' % (cryptolibname.lower(), ciphername) return import_from(moduleName , ciphername) def get_preferred_cipher(ciphername): if override_library is None: if ciphername not in preftable: raise Exception('Cipher "%s" is not supported!' % ciphername) #print('available_modules %s' % available_modules) possible_prefmodule = list(set(preftable[ciphername]).intersection(set(available_modules[ciphername]))) #print('possible_prefmodule %s' % possible_prefmodule) selected_module = None for moduleName in preftable[ciphername]: if moduleName in possible_prefmodule: selected_module = moduleName break if selected_module is None: raise Exception('Could not find any modules to load cipher "%s"' % ciphername) else: selected_module = override_library #print('Preferred module selected for cipher %s is %s' % (ciphername, selected_module)) return get_cipher_by_name(ciphername, selected_module) def use_library(libname): global override_library override_library = libname unicrypto-0.0.10/unicrypto/_version.py000066400000000000000000000002041437177004600200630ustar00rootroot00000000000000__version__ = "0.0.10" __banner__ = \ """ # unicrypto %s # Author: Tamas Jos @skelsec (info@skelsecprojects.com) """ % __version__ unicrypto-0.0.10/unicrypto/backends/000077500000000000000000000000001437177004600174435ustar00rootroot00000000000000unicrypto-0.0.10/unicrypto/backends/__init__.py000066400000000000000000000000001437177004600215420ustar00rootroot00000000000000unicrypto-0.0.10/unicrypto/backends/cmac.py000066400000000000000000000156631437177004600207330ustar00rootroot00000000000000# SECUREAUTH LABS. Copyright 2018 SecureAuth Corporation. All rights reserved. # # This software is provided under under a slightly modified version # of the Apache Software License. See the accompanying LICENSE file # for more information. # # Author: Alberto Solino (beto@coresecurity.com) # # Description: # RFC 4493 implementation (https://www.ietf.org/rfc/rfc4493.txt) # RFC 4615 implementation (https://www.ietf.org/rfc/rfc4615.txt) # # NIST SP 800-108 Section 5.1, with PRF HMAC-SHA256 implementation # (https://tools.ietf.org/html/draft-irtf-cfrg-kdf-uses-00#ref-SP800-108) # # [MS-LSAD] Section 5.1.2 # [MS-SAMR] Section 2.2.11.1.1 from struct import pack, unpack def CMAC(K, M, length, cipherobj): # +++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++ # + Algorithm AES-CMAC + # +++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++ # + + # + Input : K ( 128-bit key ) + # + : M ( message to be authenticated ) + # + : len ( length of the message in octets ) + # + Output : T ( message authentication code ) + # + + # +++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++ # + Constants: const_Zero is 0x00000000000000000000000000000000 + # + const_Bsize is 16 + # + + # + Variables: K1, K2 for 128-bit subkeys + # + M_i is the i-th block (i=1..ceil(len/const_Bsize)) + # + M_last is the last block xor-ed with K1 or K2 + # + n for number of blocks to be processed + # + r for number of octets of last block + # + flag for denoting if last block is complete or not + # + + # + Step 1. (K1,K2) := Generate_Subkey(K); + # + Step 2. n := ceil(len/const_Bsize); + # + Step 3. if n = 0 + # + then + # + n := 1; + # + flag := false; + # + else + # + if len mod const_Bsize is 0 + # + then flag := true; + # + else flag := false; + # + + # + Step 4. if flag is true + # + then M_last := M_n XOR K1; + # + else M_last := padding(M_n) XOR K2; + # + Step 5. X := const_Zero; + # + Step 6. for i := 1 to n-1 do + # + begin + # + Y := X XOR M_i; + # + X := AES-128(K,Y); + # + end + # + Y := M_last XOR X; + # + T := AES-128(K,Y); + # + Step 7. return T; + # +++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++ const_Bsize = 16 const_Zero = bytearray(16) AES_128= cipherobj(K) M = bytearray(M[:length]) K1, K2 = Generate_Subkey(K, cipherobj) n = len(M)//const_Bsize if n == 0: n = 1 flag = False else: if (length % const_Bsize) == 0: flag = True else: n += 1 flag = False M_n = M[(n-1)*const_Bsize:] if flag is True: M_last = XOR_128(M_n,K1) else: M_last = XOR_128(PAD(M_n),K2) X = const_Zero for i in range(n-1): M_i = M[(i)*const_Bsize:][:16] Y = XOR_128(X, M_i) X = bytearray(AES_128.encrypt(bytes(Y))) Y = XOR_128(M_last, X) T = AES_128.encrypt(bytes(Y)) return T def Generate_Subkey(K, cipherobj): # +++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++ # + Algorithm Generate_Subkey + # +++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++ # + + # + Input : K (128-bit key) + # + Output : K1 (128-bit first subkey) + # + K2 (128-bit second subkey) + # +-------------------------------------------------------------------+ # + + # + Constants: const_Zero is 0x00000000000000000000000000000000 + # + const_Rb is 0x00000000000000000000000000000087 + # + Variables: L for output of AES-128 applied to 0^128 + # + + # + Step 1. L := AES-128(K, const_Zero); + # + Step 2. if MSB(L) is equal to 0 + # + then K1 := L << 1; + # + else K1 := (L << 1) XOR const_Rb; + # + Step 3. if MSB(K1) is equal to 0 + # + then K2 := K1 << 1; + # + else K2 := (K1 << 1) XOR const_Rb; + # + Step 4. return K1, K2; + # + + # +++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++ AES_128 = cipherobj(K) L = AES_128.encrypt(bytes(bytearray(16))) LHigh = unpack('>Q',L[:8])[0] LLow = unpack('>Q',L[8:])[0] K1High = ((LHigh << 1) | ( LLow >> 63 )) & 0xFFFFFFFFFFFFFFFF K1Low = (LLow << 1) & 0xFFFFFFFFFFFFFFFF if (LHigh >> 63): K1Low ^= 0x87 K2High = ((K1High << 1) | (K1Low >> 63)) & 0xFFFFFFFFFFFFFFFF K2Low = ((K1Low << 1)) & 0xFFFFFFFFFFFFFFFF if (K1High >> 63): K2Low ^= 0x87 K1 = bytearray(pack('>QQ', K1High, K1Low)) K2 = bytearray(pack('>QQ', K2High, K2Low)) return K1, K2 def XOR_128(N1,N2): J = bytearray() for i in range(len(N1)): #J.append(indexbytes(N1,i) ^ indexbytes(N2,i)) J.append(N1[i] ^ N2[i]) return J def PAD(N): padLen = 16-len(N) return N + b'\x80' + b'\x00'*(padLen-1)unicrypto-0.0.10/unicrypto/backends/cryptography/000077500000000000000000000000001437177004600221765ustar00rootroot00000000000000unicrypto-0.0.10/unicrypto/backends/cryptography/AES.py000066400000000000000000000037561437177004600231730ustar00rootroot00000000000000from unicrypto.symmetric import symmetricBASE, cipherMODE from cryptography.hazmat.primitives.ciphers import Cipher, algorithms, modes from cryptography.hazmat.primitives import padding from cryptography.hazmat.backends import default_backend from unicrypto.symmetric import symmetricBASE, cipherMODE class AES(symmetricBASE): def __init__(self, key, mode = cipherMODE.ECB, IV = None, pad = None, segment_size = 128): self.encryptor = None self.decryptor = None symmetricBASE.__init__(self, key, mode, IV, segment_size=segment_size) def setup_cipher(self): if self.mode == cipherMODE.ECB: self.IV = modes.ECB() elif self.mode == cipherMODE.CBC: self.IV = modes.CBC(self.IV) elif self.mode == cipherMODE.CTR: self.IV = modes.CTR(self.IV) elif self.mode == cipherMODE.CFB: if self.segment_size == 8: self.IV = modes.CFB8(self.IV) elif self.segment_size == 128: self.IV = modes.CFB(self.IV) elif self.mode == cipherMODE.OFB: self.IV = modes.OFB(self.IV) elif self.mode == cipherMODE.CCM: from cryptography.hazmat.primitives.ciphers.aead import AESCCM self._cipher = AESCCM(self.key, tag_length=self.segment_size) return elif self.mode == cipherMODE.GCM: from cryptography.hazmat.primitives.ciphers.aead import AESGCM self._cipher = AESGCM(self.key) return else: raise Exception('Unknown cipher mode!') algorithm = algorithms.AES(self.key) self._cipher = Cipher(algorithm, mode=self.IV, backend=default_backend()) self.encryptor = self._cipher.encryptor() self.decryptor = self._cipher.decryptor() def encrypt(self, data, aad = None): if self.mode == cipherMODE.CCM or self.mode == cipherMODE.GCM: res = self._cipher.encrypt(self.IV, data, aad) return res[:-16], res[-16:] else: return self.encryptor.update(data) def decrypt(self, data, aad = None, mac = None): if self.mode == cipherMODE.CCM or self.mode == cipherMODE.GCM: return self._cipher.decrypt(self.IV, data+mac, aad) else: return self.decryptor.update(data)unicrypto-0.0.10/unicrypto/backends/cryptography/DES.py000066400000000000000000000021131437177004600231600ustar00rootroot00000000000000from cryptography.hazmat.primitives.ciphers import Cipher, algorithms, modes from cryptography.hazmat.backends import default_backend from unicrypto.symmetric import symmetricBASE, cipherMODE, expand_DES_key class DES(symmetricBASE): def __init__(self, key, mode = cipherMODE.ECB, IV = None, pad = None, padMode = None): self.encryptor = None self.decryptor = None symmetricBASE.__init__(self, key, mode, IV) def setup_cipher(self): if len(self.key) == 7: self.key = expand_DES_key(self.key) self.key = self.key*3 # since there is no single-des in this module if self.mode == cipherMODE.ECB: self.IV = modes.ECB() elif self.mode == cipherMODE.CBC: self.IV = modes.CBC(self.IV) else: raise Exception('Unknown cipher mode!') algorithm = algorithms.TripleDES(self.key) self._cipher = Cipher(algorithm, mode=self.IV, backend=default_backend()) self.encryptor = self._cipher.encryptor() self.decryptor = self._cipher.decryptor() def encrypt(self, data): return self.encryptor.update(data) def decrypt(self, data): return self.decryptor.update(data) unicrypto-0.0.10/unicrypto/backends/cryptography/RC4.py000066400000000000000000000012551437177004600231430ustar00rootroot00000000000000 from cryptography.hazmat.primitives.ciphers import Cipher, algorithms, modes from cryptography.hazmat.backends import default_backend from unicrypto.symmetric import symmetricBASE, cipherMODE class RC4(symmetricBASE): def __init__(self, key): self.encryptor = None self.decryptor = None symmetricBASE.__init__(self, key) def setup_cipher(self): algorithm = algorithms.ARC4(self.key) self._cipher = Cipher(algorithm, mode=None, backend=default_backend()) self.encryptor = self._cipher.encryptor() self.decryptor = self._cipher.decryptor() def encrypt(self, data): return self.encryptor.update(data) def decrypt(self, data): return self.decryptor.update(data)unicrypto-0.0.10/unicrypto/backends/cryptography/TDES.py000066400000000000000000000017151437177004600233130ustar00rootroot00000000000000 from cryptography.hazmat.primitives.ciphers import Cipher, algorithms, modes from cryptography.hazmat.primitives import padding from cryptography.hazmat.backends import default_backend from unicrypto.symmetric import symmetricBASE, cipherMODE class TDES(symmetricBASE): def __init__(self, key, mode = cipherMODE.ECB, IV = None): self.encryptor = None self.decryptor = None symmetricBASE.__init__(self, key, mode, IV) def setup_cipher(self): if self.mode == cipherMODE.ECB: self.IV = modes.ECB() elif self.mode == cipherMODE.CBC: self.IV = modes.CBC(self.IV) else: raise Exception('Unknown cipher mode!') algorithm = algorithms.TripleDES(self.key) self._cipher = Cipher(algorithm, mode=self.IV, backend=default_backend()) self.encryptor = self._cipher.encryptor() self.decryptor = self._cipher.decryptor() def encrypt(self, data): return self.encryptor.update(data) def decrypt(self, data): return self.decryptor.update(data) unicrypto-0.0.10/unicrypto/backends/cryptography/__init__.py000066400000000000000000000000431437177004600243040ustar00rootroot00000000000000from . import AES, DES, RC4, TDES unicrypto-0.0.10/unicrypto/backends/kdf.py000066400000000000000000000032351437177004600205640ustar00rootroot00000000000000# SECUREAUTH LABS. Copyright 2018 SecureAuth Corporation. All rights reserved. # # This software is provided under under a slightly modified version # of the Apache Software License. See the accompanying LICENSE file # for more information. # # Author: Alberto Solino (beto@coresecurity.com) # # Description: # RFC 4493 implementation (https://www.ietf.org/rfc/rfc4493.txt) # RFC 4615 implementation (https://www.ietf.org/rfc/rfc4615.txt) # # NIST SP 800-108 Section 5.1, with PRF HMAC-SHA256 implementation # (https://tools.ietf.org/html/draft-irtf-cfrg-kdf-uses-00#ref-SP800-108) # # [MS-LSAD] Section 5.1.2 # [MS-SAMR] Section 2.2.11.1.1 from struct import pack, unpack def KDF_CounterMode(KI, Label, Context, L, hmac_obj): # Implements NIST SP 800-108 Section 5.1, with PRF HMAC-SHA256 # https://tools.ietf.org/html/draft-irtf-cfrg-kdf-uses-00#ref-SP800-108 # Fixed values: # 1. h - The length of the output of the PRF in bits, and # 2. r - The length of the binary representation of the counter i. # Input: KI, Label, Context, and L. # Process: # 1. n := [L/h] # 2. If n > 2r-1, then indicate an error and stop. # 3. result(0):= empty . # 4. For i = 1 to n, do # a. K(i) := PRF (KI, [i]2 || Label || 0x00 || Context || [L]2) # b. result(i) := result(i-1) || K(i). # 5. Return: KO := the leftmost L bits of result(n). h = 256 r = 32 n = L // h if n == 0: n = 1 if n > (pow(2,r)-1): raise Exception("Error computing KDF_CounterMode") result = b'' K = b'' for i in range(1,n+1): input = pack('>L', i) + Label + b'\x00' + Context + pack('>L',L) K = hmac_obj.new(KI, input, 'sha256').digest() result = result + K return result[:(L//8)] unicrypto-0.0.10/unicrypto/backends/mbedtls/000077500000000000000000000000001437177004600210755ustar00rootroot00000000000000unicrypto-0.0.10/unicrypto/backends/mbedtls/AES.py000066400000000000000000000146101437177004600220610ustar00rootroot00000000000000 from mbedtls import cipher as mbedcipher from unicrypto.symmetric import symmetricBASE, cipherMODE import struct from unicrypto import hashlib class AES(symmetricBASE): def __init__(self, key, mode = cipherMODE.ECB, IV = None, segment_size = 128): self.ctrint = None self.ctrlen = None self._ccm_cipher_ctr = None self._ccm_cipher_cbc = None symmetricBASE.__init__(self, key, mode, IV, segment_size=segment_size) def setup_cipher(self): if self.mode == cipherMODE.ECB: self._cipher = mbedcipher.AES.new(self.key, mbedcipher.MODE_ECB, b'') elif self.mode == cipherMODE.CBC: self._cipher = mbedcipher.AES.new(self.key, mbedcipher.MODE_CBC, self.IV) elif self.mode == cipherMODE.CTR: self.ctrlen = len(self.IV) self.ctrint = int.from_bytes(self.IV, byteorder = 'big', signed= False) self._cipher = mbedcipher.AES.new(self.key, mbedcipher.MODE_CTR, self.IV) elif self.mode == cipherMODE.OFB: self._cipher = mbedcipher.AES.new(self.key, mbedcipher.MODE_OFB, self.IV) elif self.mode == cipherMODE.CFB: self._cipher = mbedcipher.AES.new(self.key, mbedcipher.MODE_CFB, self.IV) elif self.mode == cipherMODE.CCM: if self.segment_size not in (4, 6, 8, 10, 12, 14, 16): raise ValueError("Parameter 'mac_len' must be even and in the range 4..16 (not %d)" % self.segment_size) if not (self.IV and 7 <= len(self.IV) <= 13): raise ValueError("Length of parameter 'nonce' must be in the range 7..13 bytes") q = 15 - len(self.IV) t_nonce = struct.pack("B", q - 1) + self.IV t_noncepad = b'\x00'*(16 - (len(t_nonce) % 16)) # 16 is the blocksize t_nonce += t_noncepad self.ctrlen = len(t_nonce) self.ctrint = int.from_bytes(t_nonce, byteorder = 'big', signed= False) self._ccm_cipher_ctr = mbedcipher.AES.new(self.key, mbedcipher.MODE_CTR, t_nonce) self._ccm_cipher_cbc = mbedcipher.AES.new(self.key, mbedcipher.MODE_CBC, b'\x00'*16) #self._ccm_cipher_ctr.set_padding_mode(4) #self._ccm_cipher_cbc.set_padding_mode(4) return elif self.mode == cipherMODE.GCM: self._cipher = None #aad needed... else: raise Exception('Unknown cipher mode!') #self._cipher.set_padding_mode(4) def encrypt(self, data, aad = None): if self.mode == cipherMODE.CCM: return self.__ccm_encrypt(data, aad) elif self.mode == cipherMODE.GCM: self._cipher = mbedcipher.AES.new(self.key, mbedcipher.MODE_GCM, self.IV, aad) return self._cipher.encrypt(data) res = self._cipher.encrypt(data) return res def decrypt(self, data, aad = None, mac = None): if self.mode == cipherMODE.CCM: return self.__ccm_decrypt(data, aad, mac) elif self.mode == cipherMODE.GCM: if self._cipher is None: self._cipher = mbedcipher.AES.new(self.key, mbedcipher.MODE_GCM, self.IV, aad) return self._cipher.decrypt(data, mac) res = self._cipher.decrypt(data) return res def __ccm_encrypt(self, plaintext, aad): q = 15 - len(self.IV) blockSize = 16 # For AES... s0 = self._ccm_cipher_ctr.encrypt(b'\x00'*16) # For mac self.ctrint += 1 self._ccm_cipher_ctr = mbedcipher.AES.new(self.key, mbedcipher.MODE_CTR, self.ctrint.to_bytes(self.ctrlen, byteorder='big', signed = False)) c = self._ccm_cipher_ctr.encrypt(plaintext) # Mac pLen = len(plaintext) aadLen = len(aad) flags = (64 * (aadLen > 0) + 8 * ((self.segment_size - 2) // 2) + (q - 1)) b0 = struct.pack("B", flags) + self.IV + pLen.to_bytes(q, 'big') assocLenEncoded = b'' if aadLen > 0: if aadLen < (2 ** 16 - 2 ** 8): encSize = 2 elif aadLen < (2 ** 32): assocLenEncoded = b'\xFF\xFE' encSize = 4 else: assocLenEncoded = b'\xFF\xFF' encSize = 8 assocLenEncoded += aadLen.to_bytes(encSize, 'big') aadPadded = assocLenEncoded + aad #print(f"aad Format before pad: {len(aadPadded)}" ) aadPad = b'' if len(aadPadded) % blockSize != 0: #print("need to padd aad") aadPad = b'\x00'*(blockSize - (len(aadPadded) % blockSize)) aadPadded += aadPad ptxtPadded = plaintext #ptxt padding ptxtPad = b'' if (pLen % blockSize) != 0: #print("Should pad ptxt") ptxtPad = b'\x00'*(blockSize - (pLen % blockSize)) ptxtPadded += ptxtPad macData = b0 + aadPadded + ptxtPadded #print(f"MAC input {macData}") t = self._ccm_cipher_cbc.encrypt(macData) t = t[-16:] tag = bytes([a ^ b for (a,b) in zip(t,s0)])[:self.segment_size] return (c, tag) def __ccm_decrypt(self, ciphertext, aad, macvalue): q = 15 - len(self.IV) s0 = self._ccm_cipher_ctr.encrypt(b'\x00'*16) # For mac self.ctrint += 1 self._ccm_cipher_ctr = mbedcipher.AES.new(self.key, mbedcipher.MODE_CTR, self.ctrint.to_bytes(self.ctrlen, byteorder='big', signed = False)) plaintext = self._ccm_cipher_ctr.encrypt(ciphertext) pLen = len(plaintext) aadLen = len(aad) flags = (64 * (aadLen > 0) + 8 * ((self.segment_size - 2) // 2) + (q - 1)) b0 = struct.pack("B", flags) + self.IV + pLen.to_bytes(q, 'big') assocLenEncoded = b'' if aadLen > 0: if aadLen < (2 ** 16 - 2 ** 8): encSize = 2 elif aadLen < (2 ** 32): assocLenEncoded = b'\xFF\xFE' encSize = 4 else: assocLenEncoded = b'\xFF\xFF' encSize = 8 assocLenEncoded += aadLen.to_bytes(encSize, 'big') aadPadded = assocLenEncoded + aad aadPad = b'' if len(aadPadded) % 16 != 0: aadPad = b'\x00'*(16 - (len(aadPadded) % 16)) aadPadded += aadPad ptxtPadded = plaintext #ptxt padding ptxtPad = b'' if pLen % 16 != 0: #print("Should pad ptxt") ptxtPad = b'\x00'*(16 - (pLen % 16)) ptxtPadded += ptxtPad macData = b0 + aadPadded + ptxtPadded t = self._ccm_cipher_cbc.encrypt(macData) t = t[-16:] tag = bytes([a ^ b for (a,b) in zip(t,s0)])[:self.segment_size] #return plaintext ## Attempt to secure comparison... Idea: hash expected and received macs and compare the result in constant time... ## Ideally should be done with HMAC with a RANDOM KEY! Doesn't cost much on a performance level. ## For now we use shake_128(SHA3 without a key) #print(f"received mac {macvalue} \nComputed {tag}") h1 = hashlib.sha256() h1.update(tag) digest1 = h1.digest() h2 = hashlib.sha256() h2.update(macvalue) digest2 = h2.digest() # Constant time comparison of hashes. Probably overkill here because of the randomization introduced by HMAC.. result = 0 for x, y in zip(digest1, digest2): result |= x ^ y #print(f"Reuslt {result}") if result != 0: raise ValueError("Incorrect MAC") else: return plaintextunicrypto-0.0.10/unicrypto/backends/mbedtls/DES.py000066400000000000000000000024711437177004600220660ustar00rootroot00000000000000 from mbedtls import cipher as mbedcipher from unicrypto.symmetric import symmetricBASE, cipherMODE, expand_DES_key class DES(symmetricBASE): def __init__(self, key, mode = cipherMODE.ECB, IV = None): symmetricBASE.__init__(self, key, mode, IV) def setup_cipher(self): if len(self.key) == 7: self.key = expand_DES_key(self.key) if self.mode == cipherMODE.ECB: self._cipher = mbedcipher.DES.new(self.key, mbedcipher.MODE_ECB, b'') elif self.mode == cipherMODE.CBC: self._cipher = mbedcipher.DES.new(self.key, mbedcipher.MODE_CBC, self.IV) else: raise Exception('Unknown cipher mode!') def __encrypt_inner(self, data): res = self._cipher.encrypt(data) return res def encrypt(self, data): res = b'' if len(data) > self._cipher.block_size: for dc in [data[i:i + self._cipher.block_size] for i in range(0, len(data), self._cipher.block_size)]: res += self.__encrypt_inner(dc) else: res = self.__encrypt_inner(data) return res def __decrypt_inner(self, data): res = self._cipher.decrypt(data) return res def decrypt(self, data): res = b'' if len(data) > self._cipher.block_size: for dc in [data[i:i + self._cipher.block_size] for i in range(0, len(data), self._cipher.block_size)]: res += self.__decrypt_inner(dc) else: res = self.__decrypt_inner(data) return resunicrypto-0.0.10/unicrypto/backends/mbedtls/RC4.py000066400000000000000000000010361437177004600220370ustar00rootroot00000000000000 from mbedtls import cipher as mbedcipher from unicrypto.symmetric import symmetricBASE, cipherMODE class RC4(symmetricBASE): def __init__(self, key): symmetricBASE.__init__(self, key) def setup_cipher(self): if len(self.key) == 16: self._cipher = mbedcipher.ARC4.new(self.key, mbedcipher.MODE_ECB, b'') else: from unicrypto.backends.pure.RC4 import RC4 as _pureRC4 self._cipher = _pureRC4(self.key) def encrypt(self, data): return self._cipher.encrypt(data) def decrypt(self, data): return self._cipher.decrypt(data)unicrypto-0.0.10/unicrypto/backends/mbedtls/TDES.py000066400000000000000000000012201437177004600222010ustar00rootroot00000000000000 from mbedtls import cipher as mbedcipher from unicrypto.symmetric import symmetricBASE, cipherMODE class TDES(symmetricBASE): def __init__(self, key, mode = cipherMODE.ECB, IV = None): symmetricBASE.__init__(self, key, mode, IV) def setup_cipher(self): if self.mode == cipherMODE.ECB: self._cipher = mbedcipher.DES3.new(self.key, mbedcipher.MODE_ECB, b'') elif self.mode == cipherMODE.CBC: self._cipher = mbedcipher.DES3.new(self.key, mbedcipher.MODE_CBC, self.IV) else: raise Exception('Unknown cipher mode!') def encrypt(self, data): return self._cipher.encrypt(data) def decrypt(self, data): return self._cipher.decrypt(data)unicrypto-0.0.10/unicrypto/backends/mbedtls/__init__.py000066400000000000000000000000431437177004600232030ustar00rootroot00000000000000from . import AES, DES, RC4, TDES unicrypto-0.0.10/unicrypto/backends/pure/000077500000000000000000000000001437177004600204165ustar00rootroot00000000000000unicrypto-0.0.10/unicrypto/backends/pure/AES.py000066400000000000000000000153251437177004600214060ustar00rootroot00000000000000import io import struct from unicrypto.symmetric import symmetricBASE, cipherMODE from unicrypto.backends.pure.external.AES import AESModeOfOperationCBC,\ AESModeOfOperationECB, AESModeOfOperationCTR, AESModeOfOperationCFB,\ AESModeOfOperationOFB, encrypt_stream, decrypt_stream, PADDING_NONE,\ Counter, Encrypter from unicrypto import hashlib class AES(symmetricBASE): def __init__(self, key, mode = cipherMODE.ECB, IV = None, segment_size = 8): self._ccm_cipher_ctr = None self._ccm_cipher_cbc = None symmetricBASE.__init__(self, key, mode, IV, segment_size=segment_size) def setup_cipher(self): if self.mode == cipherMODE.ECB: self._cipher = AESModeOfOperationECB(self.key) elif self.mode == cipherMODE.CBC: self._cipher = AESModeOfOperationCBC(self.key, iv = self.IV) elif self.mode == cipherMODE.CTR: self._cipher = AESModeOfOperationCTR(self.key, counter = Counter(int.from_bytes(self.IV, byteorder='big', signed=False))) elif self.mode == cipherMODE.CFB: self._cipher = AESModeOfOperationCFB(self.key, iv = self.IV, segment_size = self.segment_size//8) elif self.mode == cipherMODE.OFB: self._cipher = AESModeOfOperationOFB(self.key, iv = self.IV) elif self.mode == cipherMODE.CCM: if self.segment_size not in (4, 6, 8, 10, 12, 14, 16): raise ValueError("Parameter 'mac_len' must be even and in the range 4..16 (not %d)" % self.segment_size) if not (self.IV and 7 <= len(self.IV) <= 13): raise ValueError("Length of parameter 'nonce' must be in the range 7..13 bytes") q = 15 - len(self.IV) t_nonce = struct.pack("B", q - 1) + self.IV t_noncepad = b'\x00'*(16 - (len(t_nonce) % 16)) # 16 is the blocksize t_nonce += t_noncepad ctr_start = Counter(int.from_bytes(t_nonce, byteorder='big', signed=False)) self._ccm_cipher_ctr = AESModeOfOperationCTR(self.key, ctr_start) self._ccm_cipher_cbc = Encrypter(AESModeOfOperationCBC(self.key, iv=b'\x00'*16), padding = PADDING_NONE) # 16 is the blocksize elif self.mode == cipherMODE.GCM: from unicrypto.backends.pure.external.AES.AESGCM import AES_GCM self._cipher = AES_GCM(self.key) else: raise Exception('Unknown cipher mode!') def encrypt(self, data, aad = None): if self.mode == cipherMODE.CCM: return self.__ccm_encrypt(data, aad) if self.mode == cipherMODE.GCM: return self._cipher.encrypt(self.IV, data, aad) if self.mode != cipherMODE.CFB: in_buff = io.BytesIO(data) out_buff = io.BytesIO() encrypt_stream(self._cipher, in_buff, out_buff, padding = PADDING_NONE) out_buff.seek(0) return out_buff.read() else: return self._cipher.encrypt(data) def decrypt(self, data, aad = None, mac = None): if self.mode == cipherMODE.CCM: return self.__ccm_decrypt(data, aad, mac) if self.mode == cipherMODE.GCM: return self._cipher.decrypt(self.IV, data, mac, aad) if self.mode != cipherMODE.CFB: in_buff = io.BytesIO(data) out_buff = io.BytesIO() decrypt_stream(self._cipher, in_buff, out_buff, padding = PADDING_NONE) out_buff.seek(0) return out_buff.read() else: return self._cipher.decrypt(data) def __ccm_encrypt(self, plaintext, aad): q = 15 - len(self.IV) blockSize = 16 # For AES... s0 = self._ccm_cipher_ctr.encrypt(b'\x00'*16) # For mac #print(f"My s0 {s0}") c = self._ccm_cipher_ctr.encrypt(plaintext) # Mac pLen = len(plaintext) aadLen = len(aad) flags = (64 * (aadLen > 0) + 8 * ((self.segment_size - 2) // 2) + (q - 1)) b0 = struct.pack("B", flags) + self.IV + pLen.to_bytes(q, 'big') assocLenEncoded = b'' if aadLen > 0: if aadLen < (2 ** 16 - 2 ** 8): encSize = 2 elif aadLen < (2 ** 32): assocLenEncoded = b'\xFF\xFE' encSize = 4 else: assocLenEncoded = b'\xFF\xFF' encSize = 8 assocLenEncoded += aadLen.to_bytes(encSize, 'big') aadPadded = assocLenEncoded + aad #print(f"aad Format before pad: {len(aadPadded)}" ) aadPad = b'' if len(aadPadded) % blockSize != 0: #print("need to padd aad") aadPad = b'\x00'*(blockSize - (len(aadPadded) % blockSize)) aadPadded += aadPad ptxtPadded = plaintext #ptxt padding ptxtPad = b'' if (pLen % blockSize) != 0: #print("Should pad ptxt") ptxtPad = b'\x00'*(blockSize - (pLen % blockSize)) ptxtPadded += ptxtPad macData = b0 + aadPadded + ptxtPadded #print(f"MAC input {macData}") t = self._ccm_cipher_cbc.feed(macData) t += self._ccm_cipher_cbc.feed() t = t[-16:] tag = bytes([a ^ b for (a,b) in zip(t,s0)])[:self.segment_size] return (c, tag) def __ccm_decrypt(self, ciphertext, aad, macvalue): #print('aad: %s' % aad) #print('mac: %s' % macvalue) # Decrytion: in CTR Encrypt == Decrypt # Decryption q = 15 - len(self.IV) s0 = self._ccm_cipher_ctr.encrypt(b'\x00'*16) # For mac #print(f"My s0 {s0}") plaintext = self._ccm_cipher_ctr.encrypt(ciphertext) #print(f"recoverd plaintex {plaintext}") # Mac pLen = len(plaintext) aadLen = len(aad) flags = (64 * (aadLen > 0) + 8 * ((self.segment_size - 2) // 2) + (q - 1)) b0 = struct.pack("B", flags) + self.IV + pLen.to_bytes(q, 'big') assocLenEncoded = b'' if aadLen > 0: if aadLen < (2 ** 16 - 2 ** 8): encSize = 2 elif aadLen < (2 ** 32): assocLenEncoded = b'\xFF\xFE' encSize = 4 else: assocLenEncoded = b'\xFF\xFF' encSize = 8 assocLenEncoded += aadLen.to_bytes(encSize, 'big') aadPadded = assocLenEncoded + aad #print(f"aad Format before pad: {len(aadPadded)}" ) aadPad = b'' if len(aadPadded) % 16 != 0: #print("need to padd aad") aadPad = b'\x00'*(16 - (len(aadPadded) % 16)) aadPadded += aadPad ptxtPadded = plaintext #ptxt padding ptxtPad = b'' if pLen % 16 != 0: #print("Should pad ptxt") ptxtPad = b'\x00'*(16 - (pLen % 16)) ptxtPadded += ptxtPad macData = b0 + aadPadded + ptxtPadded #t = mac.encrypt(macData)[-16:] t = self._ccm_cipher_cbc.feed(macData) t += self._ccm_cipher_cbc.feed() t = t[-16:] tag = bytes([a ^ b for (a,b) in zip(t,s0)])[:self.segment_size] #return plaintext ## Attempt to secure comparison... Idea: hash expected and received macs and compare the result in constant time... ## Ideally should be done with HMAC with a RANDOM KEY! Doesn't cost much on a performance level. ## For now we use shake_128(SHA3 without a key) #print(f"received mac {macvalue} \nComputed {tag}") h1 = hashlib.sha256() h1.update(tag) digest1 = h1.digest() h2 = hashlib.sha256() h2.update(macvalue) digest2 = h2.digest() # Constant time comparison of hashes. Probably overkill here because of the randomization introduced by HMAC.. result = 0 for x, y in zip(digest1, digest2): result |= x ^ y #print(f"Reuslt {result}") if result != 0: raise ValueError("Incorrect MAC") else: return plaintext unicrypto-0.0.10/unicrypto/backends/pure/DES.py000066400000000000000000000012771437177004600214120ustar00rootroot00000000000000 import unicrypto.backends.pure.external.DES.DES as _pyDES from unicrypto.symmetric import symmetricBASE, cipherMODE, expand_DES_key class DES(symmetricBASE): def __init__(self, key, mode = cipherMODE.ECB, IV = None): symmetricBASE.__init__(self, key, mode, IV) def setup_cipher(self): if len(self.key) == 7: self.key = expand_DES_key(self.key) if self.mode == cipherMODE.ECB: mode = _pyDES.ECB elif self.mode == cipherMODE.CBC: mode = _pyDES.CBC else: raise Exception('Unknown cipher mode!') self._cipher = _pyDES.des(self.key, mode, self.IV) def encrypt(self, data): return self._cipher.encrypt(data) def decrypt(self, data): return self._cipher.decrypt(data) unicrypto-0.0.10/unicrypto/backends/pure/MD4.py000066400000000000000000000111331437177004600213530ustar00rootroot00000000000000#!/usr/bin/env python3 # -*- coding: utf-8 -*- # # Copyright © 2019 James Seo (github.com/kangtastic). # # This file is released under the WTFPL, version 2 (wtfpl.net). # # md4.py: An implementation of the MD4 hash algorithm in pure Python 3. # # Description: Zounds! Yet another rendition of pseudocode from RFC1320! # Bonus points for the algorithm literally being from 1992. # # Usage: Why would anybody use this? This is self-rolled crypto, and # self-rolled *obsolete* crypto at that. DO NOT USE if you need # something "performant" or "secure". :P # # Anyway, from the command line: # # $ ./md4.py [messages] # # where [messages] are some strings to be hashed. # # In Python, use similarly to hashlib (not that it even has MD4): # # from .md4 import MD4 # # digest = MD4("BEES").hexdigest() # # print(digest) # "501af1ef4b68495b5b7e37b15b4cda68" # # # Sample console output: # # Testing the MD4 class. # # Message: b'' # Expected: 31d6cfe0d16ae931b73c59d7e0c089c0 # Actual: 31d6cfe0d16ae931b73c59d7e0c089c0 # # Message: b'The quick brown fox jumps over the lazy dog' # Expected: 1bee69a46ba811185c194762abaeae90 # Actual: 1bee69a46ba811185c194762abaeae90 # # Message: b'BEES' # Expected: 501af1ef4b68495b5b7e37b15b4cda68 # Actual: 501af1ef4b68495b5b7e37b15b4cda68 # import struct class MD4: """An implementation of the MD4 hash algorithm.""" width = 32 mask = 0xFFFFFFFF # Unlike, say, SHA-1, MD4 uses little-endian. Fascinating! h = [0x67452301, 0xEFCDAB89, 0x98BADCFE, 0x10325476] def __init__(self, msg=None): """:param ByteString msg: The message to be hashed.""" if msg is None: msg = b"" self.msg = msg # Pre-processing: Total length is a multiple of 512 bits. ml = len(msg) * 8 msg += b"\x80" msg += b"\x00" * (-(len(msg) + 8) % 64) msg += struct.pack("> (MD4.width - n) return lbits | rbits def main(): # Import is intentionally delayed. import sys if len(sys.argv) > 1: messages = [msg.encode() for msg in sys.argv[1:]] for message in messages: print(MD4(message).hexdigest()) else: messages = [b"", b"The quick brown fox jumps over the lazy dog", b"BEES"] known_hashes = [ "31d6cfe0d16ae931b73c59d7e0c089c0", "1bee69a46ba811185c194762abaeae90", "501af1ef4b68495b5b7e37b15b4cda68", ] print("Testing the MD4 class.") print() for message, expected in zip(messages, known_hashes): print("Message: ", message) print("Expected:", expected) print("Actual: ", MD4(message).hexdigest()) print() if __name__ == "__main__": try: main() except KeyboardInterrupt: pass unicrypto-0.0.10/unicrypto/backends/pure/RC4.py000066400000000000000000000006311437177004600213600ustar00rootroot00000000000000 from unicrypto.backends.pure.external.RC4.RC4 import RC4 as _pureRC4 from unicrypto.symmetric import symmetricBASE, cipherMODE class RC4(symmetricBASE): def __init__(self, key): symmetricBASE.__init__(self, key) def setup_cipher(self): self._cipher = _pureRC4(self.key) def encrypt(self, data): return self._cipher.encrypt(data) def decrypt(self, data): return self._cipher.decrypt(data) unicrypto-0.0.10/unicrypto/backends/pure/TDES.py000066400000000000000000000015721437177004600215340ustar00rootroot00000000000000import unicrypto.backends.pure.external.DES.DES as _pyDES from unicrypto.symmetric import symmetricBASE, cipherMODE, expand_DES_key class TDES(symmetricBASE): def __init__(self, key, mode = cipherMODE.ECB, IV = None, pad = None, padMode = None): symmetricBASE.__init__(self, key, mode, IV) if not isinstance(key, bytes): raise Exception('Key needs to be bytes!') self.mode = mode self.IV = IV self.pad = pad self.padMode = padMode def setup_cipher(self): if self.mode == cipherMODE.ECB: mode = _pyDES.ECB self._cipher = _pyDES.triple_des(self.key, mode) elif self.mode == cipherMODE.CBC: mode = _pyDES.CBC self._cipher = _pyDES.triple_des(self.key, mode, self.IV, pad = None) else: raise Exception('Unknown cipher mode!') def encrypt(self, data): return self._cipher.encrypt(data) def decrypt(self, data): return self._cipher.decrypt(data) unicrypto-0.0.10/unicrypto/backends/pure/__init__.py000066400000000000000000000000431437177004600225240ustar00rootroot00000000000000from . import AES, DES, RC4, TDES unicrypto-0.0.10/unicrypto/backends/pure/external/000077500000000000000000000000001437177004600222405ustar00rootroot00000000000000unicrypto-0.0.10/unicrypto/backends/pure/external/AES/000077500000000000000000000000001437177004600226505ustar00rootroot00000000000000unicrypto-0.0.10/unicrypto/backends/pure/external/AES/AES.py000066400000000000000000001657251437177004600236520ustar00rootroot00000000000000 #https://github.com/ricmoo/pyaes/blob/master/pyaes/aes.py # The MIT License (MIT) # # Copyright (c) 2014 Richard Moore # # Permission is hereby granted, free of charge, to any person obtaining a copy # of this software and associated documentation files (the "Software"), to deal # in the Software without restriction, including without limitation the rights # to use, copy, modify, merge, publish, distribute, sublicense, and/or sell # copies of the Software, and to permit persons to whom the Software is # furnished to do so, subject to the following conditions: # # The above copyright notice and this permission notice shall be included in # all copies or substantial portions of the Software. # # THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR # IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY, # FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE # AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER # LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, # OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN # THE SOFTWARE. # This is a pure-Python implementation of the AES algorithm and AES common # modes of operation. # See: https://en.wikipedia.org/wiki/Advanced_Encryption_Standard # Honestly, the best description of the modes of operations are the wonderful # diagrams on Wikipedia. They explain in moments what my words could never # achieve. Hence the inline documentation here is sparer than I'd prefer. # See: https://en.wikipedia.org/wiki/Block_cipher_mode_of_operation # Also useful, PyCrypto, a crypto library implemented in C with Python bindings: # https://www.dlitz.net/software/pycrypto/ # Supported key sizes: # 128-bit # 192-bit # 256-bit # Supported modes of operation: # ECB - Electronic Codebook # CBC - Cipher-Block Chaining # CFB - Cipher Feedback # OFB - Output Feedback # CTR - Counter # See the README.md for API details and general information. import copy import struct __all__ = ["AES", "AESModeOfOperationCTR", "AESModeOfOperationCBC", "AESModeOfOperationCFB", "AESModeOfOperationECB", "AESModeOfOperationOFB", "AESModesOfOperation", "Counter"] def _compact_word(word): return (word[0] << 24) | (word[1] << 16) | (word[2] << 8) | word[3] def _string_to_bytes(text): return list(ord(c) for c in text) def _bytes_to_string(binary): return "".join(chr(b) for b in binary) def _concat_list(a, b): return a + b # Python 3 compatibility try: xrange except Exception: xrange = range # Python 3 supports bytes, which is already an array of integers def _string_to_bytes(text): if isinstance(text, bytes): return text return [ord(c) for c in text] # In Python 3, we return bytes def _bytes_to_string(binary): return bytes(binary) # Python 3 cannot concatenate a list onto a bytes, so we bytes-ify it first def _concat_list(a, b): return a + bytes(b) # Based *largely* on the Rijndael implementation # See: http://csrc.nist.gov/publications/fips/fips197/fips-197.pdf class AES(object): '''Encapsulates the AES block cipher. You generally should not need this. Use the AESModeOfOperation classes below instead.''' # Number of rounds by keysize number_of_rounds = {16: 10, 24: 12, 32: 14} # Round constant words rcon = [ 0x01, 0x02, 0x04, 0x08, 0x10, 0x20, 0x40, 0x80, 0x1b, 0x36, 0x6c, 0xd8, 0xab, 0x4d, 0x9a, 0x2f, 0x5e, 0xbc, 0x63, 0xc6, 0x97, 0x35, 0x6a, 0xd4, 0xb3, 0x7d, 0xfa, 0xef, 0xc5, 0x91 ] # S-box and Inverse S-box (S is for Substitution) S = [ 0x63, 0x7c, 0x77, 0x7b, 0xf2, 0x6b, 0x6f, 0xc5, 0x30, 0x01, 0x67, 0x2b, 0xfe, 0xd7, 0xab, 0x76, 0xca, 0x82, 0xc9, 0x7d, 0xfa, 0x59, 0x47, 0xf0, 0xad, 0xd4, 0xa2, 0xaf, 0x9c, 0xa4, 0x72, 0xc0, 0xb7, 0xfd, 0x93, 0x26, 0x36, 0x3f, 0xf7, 0xcc, 0x34, 0xa5, 0xe5, 0xf1, 0x71, 0xd8, 0x31, 0x15, 0x04, 0xc7, 0x23, 0xc3, 0x18, 0x96, 0x05, 0x9a, 0x07, 0x12, 0x80, 0xe2, 0xeb, 0x27, 0xb2, 0x75, 0x09, 0x83, 0x2c, 0x1a, 0x1b, 0x6e, 0x5a, 0xa0, 0x52, 0x3b, 0xd6, 0xb3, 0x29, 0xe3, 0x2f, 0x84, 0x53, 0xd1, 0x00, 0xed, 0x20, 0xfc, 0xb1, 0x5b, 0x6a, 0xcb, 0xbe, 0x39, 0x4a, 0x4c, 0x58, 0xcf, 0xd0, 0xef, 0xaa, 0xfb, 0x43, 0x4d, 0x33, 0x85, 0x45, 0xf9, 0x02, 0x7f, 0x50, 0x3c, 0x9f, 0xa8, 0x51, 0xa3, 0x40, 0x8f, 0x92, 0x9d, 0x38, 0xf5, 0xbc, 0xb6, 0xda, 0x21, 0x10, 0xff, 0xf3, 0xd2, 0xcd, 0x0c, 0x13, 0xec, 0x5f, 0x97, 0x44, 0x17, 0xc4, 0xa7, 0x7e, 0x3d, 0x64, 0x5d, 0x19, 0x73, 0x60, 0x81, 0x4f, 0xdc, 0x22, 0x2a, 0x90, 0x88, 0x46, 0xee, 0xb8, 0x14, 0xde, 0x5e, 0x0b, 0xdb, 0xe0, 0x32, 0x3a, 0x0a, 0x49, 0x06, 0x24, 0x5c, 0xc2, 0xd3, 0xac, 0x62, 0x91, 0x95, 0xe4, 0x79, 0xe7, 0xc8, 0x37, 0x6d, 0x8d, 0xd5, 0x4e, 0xa9, 0x6c, 0x56, 0xf4, 0xea, 0x65, 0x7a, 0xae, 0x08, 0xba, 0x78, 0x25, 0x2e, 0x1c, 0xa6, 0xb4, 0xc6, 0xe8, 0xdd, 0x74, 0x1f, 0x4b, 0xbd, 0x8b, 0x8a, 0x70, 0x3e, 0xb5, 0x66, 0x48, 0x03, 0xf6, 0x0e, 0x61, 0x35, 0x57, 0xb9, 0x86, 0xc1, 0x1d, 0x9e, 0xe1, 0xf8, 0x98, 0x11, 0x69, 0xd9, 0x8e, 0x94, 0x9b, 0x1e, 0x87, 0xe9, 0xce, 0x55, 0x28, 0xdf, 0x8c, 0xa1, 0x89, 0x0d, 0xbf, 0xe6, 0x42, 0x68, 0x41, 0x99, 0x2d, 0x0f, 0xb0, 0x54, 0xbb, 0x16 ] Si =[ 0x52, 0x09, 0x6a, 0xd5, 0x30, 0x36, 0xa5, 0x38, 0xbf, 0x40, 0xa3, 0x9e, 0x81, 0xf3, 0xd7, 0xfb, 0x7c, 0xe3, 0x39, 0x82, 0x9b, 0x2f, 0xff, 0x87, 0x34, 0x8e, 0x43, 0x44, 0xc4, 0xde, 0xe9, 0xcb, 0x54, 0x7b, 0x94, 0x32, 0xa6, 0xc2, 0x23, 0x3d, 0xee, 0x4c, 0x95, 0x0b, 0x42, 0xfa, 0xc3, 0x4e, 0x08, 0x2e, 0xa1, 0x66, 0x28, 0xd9, 0x24, 0xb2, 0x76, 0x5b, 0xa2, 0x49, 0x6d, 0x8b, 0xd1, 0x25, 0x72, 0xf8, 0xf6, 0x64, 0x86, 0x68, 0x98, 0x16, 0xd4, 0xa4, 0x5c, 0xcc, 0x5d, 0x65, 0xb6, 0x92, 0x6c, 0x70, 0x48, 0x50, 0xfd, 0xed, 0xb9, 0xda, 0x5e, 0x15, 0x46, 0x57, 0xa7, 0x8d, 0x9d, 0x84, 0x90, 0xd8, 0xab, 0x00, 0x8c, 0xbc, 0xd3, 0x0a, 0xf7, 0xe4, 0x58, 0x05, 0xb8, 0xb3, 0x45, 0x06, 0xd0, 0x2c, 0x1e, 0x8f, 0xca, 0x3f, 0x0f, 0x02, 0xc1, 0xaf, 0xbd, 0x03, 0x01, 0x13, 0x8a, 0x6b, 0x3a, 0x91, 0x11, 0x41, 0x4f, 0x67, 0xdc, 0xea, 0x97, 0xf2, 0xcf, 0xce, 0xf0, 0xb4, 0xe6, 0x73, 0x96, 0xac, 0x74, 0x22, 0xe7, 0xad, 0x35, 0x85, 0xe2, 0xf9, 0x37, 0xe8, 0x1c, 0x75, 0xdf, 0x6e, 0x47, 0xf1, 0x1a, 0x71, 0x1d, 0x29, 0xc5, 0x89, 0x6f, 0xb7, 0x62, 0x0e, 0xaa, 0x18, 0xbe, 0x1b, 0xfc, 0x56, 0x3e, 0x4b, 0xc6, 0xd2, 0x79, 0x20, 0x9a, 0xdb, 0xc0, 0xfe, 0x78, 0xcd, 0x5a, 0xf4, 0x1f, 0xdd, 0xa8, 0x33, 0x88, 0x07, 0xc7, 0x31, 0xb1, 0x12, 0x10, 0x59, 0x27, 0x80, 0xec, 0x5f, 0x60, 0x51, 0x7f, 0xa9, 0x19, 0xb5, 0x4a, 0x0d, 0x2d, 0xe5, 0x7a, 0x9f, 0x93, 0xc9, 0x9c, 0xef, 0xa0, 0xe0, 0x3b, 0x4d, 0xae, 0x2a, 0xf5, 0xb0, 0xc8, 0xeb, 0xbb, 0x3c, 0x83, 0x53, 0x99, 0x61, 0x17, 0x2b, 0x04, 0x7e, 0xba, 0x77, 0xd6, 0x26, 0xe1, 0x69, 0x14, 0x63, 0x55, 0x21, 0x0c, 0x7d ] # Transformations for encryption T1 = [ 0xc66363a5, 0xf87c7c84, 0xee777799, 0xf67b7b8d, 0xfff2f20d, 0xd66b6bbd, 0xde6f6fb1, 0x91c5c554, 0x60303050, 0x02010103, 0xce6767a9, 0x562b2b7d, 0xe7fefe19, 0xb5d7d762, 0x4dababe6, 0xec76769a, 0x8fcaca45, 0x1f82829d, 0x89c9c940, 0xfa7d7d87, 0xeffafa15, 0xb25959eb, 0x8e4747c9, 0xfbf0f00b, 0x41adadec, 0xb3d4d467, 0x5fa2a2fd, 0x45afafea, 0x239c9cbf, 0x53a4a4f7, 0xe4727296, 0x9bc0c05b, 0x75b7b7c2, 0xe1fdfd1c, 0x3d9393ae, 0x4c26266a, 0x6c36365a, 0x7e3f3f41, 0xf5f7f702, 0x83cccc4f, 0x6834345c, 0x51a5a5f4, 0xd1e5e534, 0xf9f1f108, 0xe2717193, 0xabd8d873, 0x62313153, 0x2a15153f, 0x0804040c, 0x95c7c752, 0x46232365, 0x9dc3c35e, 0x30181828, 0x379696a1, 0x0a05050f, 0x2f9a9ab5, 0x0e070709, 0x24121236, 0x1b80809b, 0xdfe2e23d, 0xcdebeb26, 0x4e272769, 0x7fb2b2cd, 0xea75759f, 0x1209091b, 0x1d83839e, 0x582c2c74, 0x341a1a2e, 0x361b1b2d, 0xdc6e6eb2, 0xb45a5aee, 0x5ba0a0fb, 0xa45252f6, 0x763b3b4d, 0xb7d6d661, 0x7db3b3ce, 0x5229297b, 0xdde3e33e, 0x5e2f2f71, 0x13848497, 0xa65353f5, 0xb9d1d168, 0x00000000, 0xc1eded2c, 0x40202060, 0xe3fcfc1f, 0x79b1b1c8, 0xb65b5bed, 0xd46a6abe, 0x8dcbcb46, 0x67bebed9, 0x7239394b, 0x944a4ade, 0x984c4cd4, 0xb05858e8, 0x85cfcf4a, 0xbbd0d06b, 0xc5efef2a, 0x4faaaae5, 0xedfbfb16, 0x864343c5, 0x9a4d4dd7, 0x66333355, 0x11858594, 0x8a4545cf, 0xe9f9f910, 0x04020206, 0xfe7f7f81, 0xa05050f0, 0x783c3c44, 0x259f9fba, 0x4ba8a8e3, 0xa25151f3, 0x5da3a3fe, 0x804040c0, 0x058f8f8a, 0x3f9292ad, 0x219d9dbc, 0x70383848, 0xf1f5f504, 0x63bcbcdf, 0x77b6b6c1, 0xafdada75, 0x42212163, 0x20101030, 0xe5ffff1a, 0xfdf3f30e, 0xbfd2d26d, 0x81cdcd4c, 0x180c0c14, 0x26131335, 0xc3ecec2f, 0xbe5f5fe1, 0x359797a2, 0x884444cc, 0x2e171739, 0x93c4c457, 0x55a7a7f2, 0xfc7e7e82, 0x7a3d3d47, 0xc86464ac, 0xba5d5de7, 0x3219192b, 0xe6737395, 0xc06060a0, 0x19818198, 0x9e4f4fd1, 0xa3dcdc7f, 0x44222266, 0x542a2a7e, 0x3b9090ab, 0x0b888883, 0x8c4646ca, 0xc7eeee29, 0x6bb8b8d3, 0x2814143c, 0xa7dede79, 0xbc5e5ee2, 0x160b0b1d, 0xaddbdb76, 0xdbe0e03b, 0x64323256, 0x743a3a4e, 0x140a0a1e, 0x924949db, 0x0c06060a, 0x4824246c, 0xb85c5ce4, 0x9fc2c25d, 0xbdd3d36e, 0x43acacef, 0xc46262a6, 0x399191a8, 0x319595a4, 0xd3e4e437, 0xf279798b, 0xd5e7e732, 0x8bc8c843, 0x6e373759, 0xda6d6db7, 0x018d8d8c, 0xb1d5d564, 0x9c4e4ed2, 0x49a9a9e0, 0xd86c6cb4, 0xac5656fa, 0xf3f4f407, 0xcfeaea25, 0xca6565af, 0xf47a7a8e, 0x47aeaee9, 0x10080818, 0x6fbabad5, 0xf0787888, 0x4a25256f, 0x5c2e2e72, 0x381c1c24, 0x57a6a6f1, 0x73b4b4c7, 0x97c6c651, 0xcbe8e823, 0xa1dddd7c, 0xe874749c, 0x3e1f1f21, 0x964b4bdd, 0x61bdbddc, 0x0d8b8b86, 0x0f8a8a85, 0xe0707090, 0x7c3e3e42, 0x71b5b5c4, 0xcc6666aa, 0x904848d8, 0x06030305, 0xf7f6f601, 0x1c0e0e12, 0xc26161a3, 0x6a35355f, 0xae5757f9, 0x69b9b9d0, 0x17868691, 0x99c1c158, 0x3a1d1d27, 0x279e9eb9, 0xd9e1e138, 0xebf8f813, 0x2b9898b3, 0x22111133, 0xd26969bb, 0xa9d9d970, 0x078e8e89, 0x339494a7, 0x2d9b9bb6, 0x3c1e1e22, 0x15878792, 0xc9e9e920, 0x87cece49, 0xaa5555ff, 0x50282878, 0xa5dfdf7a, 0x038c8c8f, 0x59a1a1f8, 0x09898980, 0x1a0d0d17, 0x65bfbfda, 0xd7e6e631, 0x844242c6, 0xd06868b8, 0x824141c3, 0x299999b0, 0x5a2d2d77, 0x1e0f0f11, 0x7bb0b0cb, 0xa85454fc, 0x6dbbbbd6, 0x2c16163a ] T2 = [ 0xa5c66363, 0x84f87c7c, 0x99ee7777, 0x8df67b7b, 0x0dfff2f2, 0xbdd66b6b, 0xb1de6f6f, 0x5491c5c5, 0x50603030, 0x03020101, 0xa9ce6767, 0x7d562b2b, 0x19e7fefe, 0x62b5d7d7, 0xe64dabab, 0x9aec7676, 0x458fcaca, 0x9d1f8282, 0x4089c9c9, 0x87fa7d7d, 0x15effafa, 0xebb25959, 0xc98e4747, 0x0bfbf0f0, 0xec41adad, 0x67b3d4d4, 0xfd5fa2a2, 0xea45afaf, 0xbf239c9c, 0xf753a4a4, 0x96e47272, 0x5b9bc0c0, 0xc275b7b7, 0x1ce1fdfd, 0xae3d9393, 0x6a4c2626, 0x5a6c3636, 0x417e3f3f, 0x02f5f7f7, 0x4f83cccc, 0x5c683434, 0xf451a5a5, 0x34d1e5e5, 0x08f9f1f1, 0x93e27171, 0x73abd8d8, 0x53623131, 0x3f2a1515, 0x0c080404, 0x5295c7c7, 0x65462323, 0x5e9dc3c3, 0x28301818, 0xa1379696, 0x0f0a0505, 0xb52f9a9a, 0x090e0707, 0x36241212, 0x9b1b8080, 0x3ddfe2e2, 0x26cdebeb, 0x694e2727, 0xcd7fb2b2, 0x9fea7575, 0x1b120909, 0x9e1d8383, 0x74582c2c, 0x2e341a1a, 0x2d361b1b, 0xb2dc6e6e, 0xeeb45a5a, 0xfb5ba0a0, 0xf6a45252, 0x4d763b3b, 0x61b7d6d6, 0xce7db3b3, 0x7b522929, 0x3edde3e3, 0x715e2f2f, 0x97138484, 0xf5a65353, 0x68b9d1d1, 0x00000000, 0x2cc1eded, 0x60402020, 0x1fe3fcfc, 0xc879b1b1, 0xedb65b5b, 0xbed46a6a, 0x468dcbcb, 0xd967bebe, 0x4b723939, 0xde944a4a, 0xd4984c4c, 0xe8b05858, 0x4a85cfcf, 0x6bbbd0d0, 0x2ac5efef, 0xe54faaaa, 0x16edfbfb, 0xc5864343, 0xd79a4d4d, 0x55663333, 0x94118585, 0xcf8a4545, 0x10e9f9f9, 0x06040202, 0x81fe7f7f, 0xf0a05050, 0x44783c3c, 0xba259f9f, 0xe34ba8a8, 0xf3a25151, 0xfe5da3a3, 0xc0804040, 0x8a058f8f, 0xad3f9292, 0xbc219d9d, 0x48703838, 0x04f1f5f5, 0xdf63bcbc, 0xc177b6b6, 0x75afdada, 0x63422121, 0x30201010, 0x1ae5ffff, 0x0efdf3f3, 0x6dbfd2d2, 0x4c81cdcd, 0x14180c0c, 0x35261313, 0x2fc3ecec, 0xe1be5f5f, 0xa2359797, 0xcc884444, 0x392e1717, 0x5793c4c4, 0xf255a7a7, 0x82fc7e7e, 0x477a3d3d, 0xacc86464, 0xe7ba5d5d, 0x2b321919, 0x95e67373, 0xa0c06060, 0x98198181, 0xd19e4f4f, 0x7fa3dcdc, 0x66442222, 0x7e542a2a, 0xab3b9090, 0x830b8888, 0xca8c4646, 0x29c7eeee, 0xd36bb8b8, 0x3c281414, 0x79a7dede, 0xe2bc5e5e, 0x1d160b0b, 0x76addbdb, 0x3bdbe0e0, 0x56643232, 0x4e743a3a, 0x1e140a0a, 0xdb924949, 0x0a0c0606, 0x6c482424, 0xe4b85c5c, 0x5d9fc2c2, 0x6ebdd3d3, 0xef43acac, 0xa6c46262, 0xa8399191, 0xa4319595, 0x37d3e4e4, 0x8bf27979, 0x32d5e7e7, 0x438bc8c8, 0x596e3737, 0xb7da6d6d, 0x8c018d8d, 0x64b1d5d5, 0xd29c4e4e, 0xe049a9a9, 0xb4d86c6c, 0xfaac5656, 0x07f3f4f4, 0x25cfeaea, 0xafca6565, 0x8ef47a7a, 0xe947aeae, 0x18100808, 0xd56fbaba, 0x88f07878, 0x6f4a2525, 0x725c2e2e, 0x24381c1c, 0xf157a6a6, 0xc773b4b4, 0x5197c6c6, 0x23cbe8e8, 0x7ca1dddd, 0x9ce87474, 0x213e1f1f, 0xdd964b4b, 0xdc61bdbd, 0x860d8b8b, 0x850f8a8a, 0x90e07070, 0x427c3e3e, 0xc471b5b5, 0xaacc6666, 0xd8904848, 0x05060303, 0x01f7f6f6, 0x121c0e0e, 0xa3c26161, 0x5f6a3535, 0xf9ae5757, 0xd069b9b9, 0x91178686, 0x5899c1c1, 0x273a1d1d, 0xb9279e9e, 0x38d9e1e1, 0x13ebf8f8, 0xb32b9898, 0x33221111, 0xbbd26969, 0x70a9d9d9, 0x89078e8e, 0xa7339494, 0xb62d9b9b, 0x223c1e1e, 0x92158787, 0x20c9e9e9, 0x4987cece, 0xffaa5555, 0x78502828, 0x7aa5dfdf, 0x8f038c8c, 0xf859a1a1, 0x80098989, 0x171a0d0d, 0xda65bfbf, 0x31d7e6e6, 0xc6844242, 0xb8d06868, 0xc3824141, 0xb0299999, 0x775a2d2d, 0x111e0f0f, 0xcb7bb0b0, 0xfca85454, 0xd66dbbbb, 0x3a2c1616 ] T3 = [ 0x63a5c663, 0x7c84f87c, 0x7799ee77, 0x7b8df67b, 0xf20dfff2, 0x6bbdd66b, 0x6fb1de6f, 0xc55491c5, 0x30506030, 0x01030201, 0x67a9ce67, 0x2b7d562b, 0xfe19e7fe, 0xd762b5d7, 0xabe64dab, 0x769aec76, 0xca458fca, 0x829d1f82, 0xc94089c9, 0x7d87fa7d, 0xfa15effa, 0x59ebb259, 0x47c98e47, 0xf00bfbf0, 0xadec41ad, 0xd467b3d4, 0xa2fd5fa2, 0xafea45af, 0x9cbf239c, 0xa4f753a4, 0x7296e472, 0xc05b9bc0, 0xb7c275b7, 0xfd1ce1fd, 0x93ae3d93, 0x266a4c26, 0x365a6c36, 0x3f417e3f, 0xf702f5f7, 0xcc4f83cc, 0x345c6834, 0xa5f451a5, 0xe534d1e5, 0xf108f9f1, 0x7193e271, 0xd873abd8, 0x31536231, 0x153f2a15, 0x040c0804, 0xc75295c7, 0x23654623, 0xc35e9dc3, 0x18283018, 0x96a13796, 0x050f0a05, 0x9ab52f9a, 0x07090e07, 0x12362412, 0x809b1b80, 0xe23ddfe2, 0xeb26cdeb, 0x27694e27, 0xb2cd7fb2, 0x759fea75, 0x091b1209, 0x839e1d83, 0x2c74582c, 0x1a2e341a, 0x1b2d361b, 0x6eb2dc6e, 0x5aeeb45a, 0xa0fb5ba0, 0x52f6a452, 0x3b4d763b, 0xd661b7d6, 0xb3ce7db3, 0x297b5229, 0xe33edde3, 0x2f715e2f, 0x84971384, 0x53f5a653, 0xd168b9d1, 0x00000000, 0xed2cc1ed, 0x20604020, 0xfc1fe3fc, 0xb1c879b1, 0x5bedb65b, 0x6abed46a, 0xcb468dcb, 0xbed967be, 0x394b7239, 0x4ade944a, 0x4cd4984c, 0x58e8b058, 0xcf4a85cf, 0xd06bbbd0, 0xef2ac5ef, 0xaae54faa, 0xfb16edfb, 0x43c58643, 0x4dd79a4d, 0x33556633, 0x85941185, 0x45cf8a45, 0xf910e9f9, 0x02060402, 0x7f81fe7f, 0x50f0a050, 0x3c44783c, 0x9fba259f, 0xa8e34ba8, 0x51f3a251, 0xa3fe5da3, 0x40c08040, 0x8f8a058f, 0x92ad3f92, 0x9dbc219d, 0x38487038, 0xf504f1f5, 0xbcdf63bc, 0xb6c177b6, 0xda75afda, 0x21634221, 0x10302010, 0xff1ae5ff, 0xf30efdf3, 0xd26dbfd2, 0xcd4c81cd, 0x0c14180c, 0x13352613, 0xec2fc3ec, 0x5fe1be5f, 0x97a23597, 0x44cc8844, 0x17392e17, 0xc45793c4, 0xa7f255a7, 0x7e82fc7e, 0x3d477a3d, 0x64acc864, 0x5de7ba5d, 0x192b3219, 0x7395e673, 0x60a0c060, 0x81981981, 0x4fd19e4f, 0xdc7fa3dc, 0x22664422, 0x2a7e542a, 0x90ab3b90, 0x88830b88, 0x46ca8c46, 0xee29c7ee, 0xb8d36bb8, 0x143c2814, 0xde79a7de, 0x5ee2bc5e, 0x0b1d160b, 0xdb76addb, 0xe03bdbe0, 0x32566432, 0x3a4e743a, 0x0a1e140a, 0x49db9249, 0x060a0c06, 0x246c4824, 0x5ce4b85c, 0xc25d9fc2, 0xd36ebdd3, 0xacef43ac, 0x62a6c462, 0x91a83991, 0x95a43195, 0xe437d3e4, 0x798bf279, 0xe732d5e7, 0xc8438bc8, 0x37596e37, 0x6db7da6d, 0x8d8c018d, 0xd564b1d5, 0x4ed29c4e, 0xa9e049a9, 0x6cb4d86c, 0x56faac56, 0xf407f3f4, 0xea25cfea, 0x65afca65, 0x7a8ef47a, 0xaee947ae, 0x08181008, 0xbad56fba, 0x7888f078, 0x256f4a25, 0x2e725c2e, 0x1c24381c, 0xa6f157a6, 0xb4c773b4, 0xc65197c6, 0xe823cbe8, 0xdd7ca1dd, 0x749ce874, 0x1f213e1f, 0x4bdd964b, 0xbddc61bd, 0x8b860d8b, 0x8a850f8a, 0x7090e070, 0x3e427c3e, 0xb5c471b5, 0x66aacc66, 0x48d89048, 0x03050603, 0xf601f7f6, 0x0e121c0e, 0x61a3c261, 0x355f6a35, 0x57f9ae57, 0xb9d069b9, 0x86911786, 0xc15899c1, 0x1d273a1d, 0x9eb9279e, 0xe138d9e1, 0xf813ebf8, 0x98b32b98, 0x11332211, 0x69bbd269, 0xd970a9d9, 0x8e89078e, 0x94a73394, 0x9bb62d9b, 0x1e223c1e, 0x87921587, 0xe920c9e9, 0xce4987ce, 0x55ffaa55, 0x28785028, 0xdf7aa5df, 0x8c8f038c, 0xa1f859a1, 0x89800989, 0x0d171a0d, 0xbfda65bf, 0xe631d7e6, 0x42c68442, 0x68b8d068, 0x41c38241, 0x99b02999, 0x2d775a2d, 0x0f111e0f, 0xb0cb7bb0, 0x54fca854, 0xbbd66dbb, 0x163a2c16 ] T4 = [ 0x6363a5c6, 0x7c7c84f8, 0x777799ee, 0x7b7b8df6, 0xf2f20dff, 0x6b6bbdd6, 0x6f6fb1de, 0xc5c55491, 0x30305060, 0x01010302, 0x6767a9ce, 0x2b2b7d56, 0xfefe19e7, 0xd7d762b5, 0xababe64d, 0x76769aec, 0xcaca458f, 0x82829d1f, 0xc9c94089, 0x7d7d87fa, 0xfafa15ef, 0x5959ebb2, 0x4747c98e, 0xf0f00bfb, 0xadadec41, 0xd4d467b3, 0xa2a2fd5f, 0xafafea45, 0x9c9cbf23, 0xa4a4f753, 0x727296e4, 0xc0c05b9b, 0xb7b7c275, 0xfdfd1ce1, 0x9393ae3d, 0x26266a4c, 0x36365a6c, 0x3f3f417e, 0xf7f702f5, 0xcccc4f83, 0x34345c68, 0xa5a5f451, 0xe5e534d1, 0xf1f108f9, 0x717193e2, 0xd8d873ab, 0x31315362, 0x15153f2a, 0x04040c08, 0xc7c75295, 0x23236546, 0xc3c35e9d, 0x18182830, 0x9696a137, 0x05050f0a, 0x9a9ab52f, 0x0707090e, 0x12123624, 0x80809b1b, 0xe2e23ddf, 0xebeb26cd, 0x2727694e, 0xb2b2cd7f, 0x75759fea, 0x09091b12, 0x83839e1d, 0x2c2c7458, 0x1a1a2e34, 0x1b1b2d36, 0x6e6eb2dc, 0x5a5aeeb4, 0xa0a0fb5b, 0x5252f6a4, 0x3b3b4d76, 0xd6d661b7, 0xb3b3ce7d, 0x29297b52, 0xe3e33edd, 0x2f2f715e, 0x84849713, 0x5353f5a6, 0xd1d168b9, 0x00000000, 0xeded2cc1, 0x20206040, 0xfcfc1fe3, 0xb1b1c879, 0x5b5bedb6, 0x6a6abed4, 0xcbcb468d, 0xbebed967, 0x39394b72, 0x4a4ade94, 0x4c4cd498, 0x5858e8b0, 0xcfcf4a85, 0xd0d06bbb, 0xefef2ac5, 0xaaaae54f, 0xfbfb16ed, 0x4343c586, 0x4d4dd79a, 0x33335566, 0x85859411, 0x4545cf8a, 0xf9f910e9, 0x02020604, 0x7f7f81fe, 0x5050f0a0, 0x3c3c4478, 0x9f9fba25, 0xa8a8e34b, 0x5151f3a2, 0xa3a3fe5d, 0x4040c080, 0x8f8f8a05, 0x9292ad3f, 0x9d9dbc21, 0x38384870, 0xf5f504f1, 0xbcbcdf63, 0xb6b6c177, 0xdada75af, 0x21216342, 0x10103020, 0xffff1ae5, 0xf3f30efd, 0xd2d26dbf, 0xcdcd4c81, 0x0c0c1418, 0x13133526, 0xecec2fc3, 0x5f5fe1be, 0x9797a235, 0x4444cc88, 0x1717392e, 0xc4c45793, 0xa7a7f255, 0x7e7e82fc, 0x3d3d477a, 0x6464acc8, 0x5d5de7ba, 0x19192b32, 0x737395e6, 0x6060a0c0, 0x81819819, 0x4f4fd19e, 0xdcdc7fa3, 0x22226644, 0x2a2a7e54, 0x9090ab3b, 0x8888830b, 0x4646ca8c, 0xeeee29c7, 0xb8b8d36b, 0x14143c28, 0xdede79a7, 0x5e5ee2bc, 0x0b0b1d16, 0xdbdb76ad, 0xe0e03bdb, 0x32325664, 0x3a3a4e74, 0x0a0a1e14, 0x4949db92, 0x06060a0c, 0x24246c48, 0x5c5ce4b8, 0xc2c25d9f, 0xd3d36ebd, 0xacacef43, 0x6262a6c4, 0x9191a839, 0x9595a431, 0xe4e437d3, 0x79798bf2, 0xe7e732d5, 0xc8c8438b, 0x3737596e, 0x6d6db7da, 0x8d8d8c01, 0xd5d564b1, 0x4e4ed29c, 0xa9a9e049, 0x6c6cb4d8, 0x5656faac, 0xf4f407f3, 0xeaea25cf, 0x6565afca, 0x7a7a8ef4, 0xaeaee947, 0x08081810, 0xbabad56f, 0x787888f0, 0x25256f4a, 0x2e2e725c, 0x1c1c2438, 0xa6a6f157, 0xb4b4c773, 0xc6c65197, 0xe8e823cb, 0xdddd7ca1, 0x74749ce8, 0x1f1f213e, 0x4b4bdd96, 0xbdbddc61, 0x8b8b860d, 0x8a8a850f, 0x707090e0, 0x3e3e427c, 0xb5b5c471, 0x6666aacc, 0x4848d890, 0x03030506, 0xf6f601f7, 0x0e0e121c, 0x6161a3c2, 0x35355f6a, 0x5757f9ae, 0xb9b9d069, 0x86869117, 0xc1c15899, 0x1d1d273a, 0x9e9eb927, 0xe1e138d9, 0xf8f813eb, 0x9898b32b, 0x11113322, 0x6969bbd2, 0xd9d970a9, 0x8e8e8907, 0x9494a733, 0x9b9bb62d, 0x1e1e223c, 0x87879215, 0xe9e920c9, 0xcece4987, 0x5555ffaa, 0x28287850, 0xdfdf7aa5, 0x8c8c8f03, 0xa1a1f859, 0x89898009, 0x0d0d171a, 0xbfbfda65, 0xe6e631d7, 0x4242c684, 0x6868b8d0, 0x4141c382, 0x9999b029, 0x2d2d775a, 0x0f0f111e, 0xb0b0cb7b, 0x5454fca8, 0xbbbbd66d, 0x16163a2c ] # Transformations for decryption T5 = [ 0x51f4a750, 0x7e416553, 0x1a17a4c3, 0x3a275e96, 0x3bab6bcb, 0x1f9d45f1, 0xacfa58ab, 0x4be30393, 0x2030fa55, 0xad766df6, 0x88cc7691, 0xf5024c25, 0x4fe5d7fc, 0xc52acbd7, 0x26354480, 0xb562a38f, 0xdeb15a49, 0x25ba1b67, 0x45ea0e98, 0x5dfec0e1, 0xc32f7502, 0x814cf012, 0x8d4697a3, 0x6bd3f9c6, 0x038f5fe7, 0x15929c95, 0xbf6d7aeb, 0x955259da, 0xd4be832d, 0x587421d3, 0x49e06929, 0x8ec9c844, 0x75c2896a, 0xf48e7978, 0x99583e6b, 0x27b971dd, 0xbee14fb6, 0xf088ad17, 0xc920ac66, 0x7dce3ab4, 0x63df4a18, 0xe51a3182, 0x97513360, 0x62537f45, 0xb16477e0, 0xbb6bae84, 0xfe81a01c, 0xf9082b94, 0x70486858, 0x8f45fd19, 0x94de6c87, 0x527bf8b7, 0xab73d323, 0x724b02e2, 0xe31f8f57, 0x6655ab2a, 0xb2eb2807, 0x2fb5c203, 0x86c57b9a, 0xd33708a5, 0x302887f2, 0x23bfa5b2, 0x02036aba, 0xed16825c, 0x8acf1c2b, 0xa779b492, 0xf307f2f0, 0x4e69e2a1, 0x65daf4cd, 0x0605bed5, 0xd134621f, 0xc4a6fe8a, 0x342e539d, 0xa2f355a0, 0x058ae132, 0xa4f6eb75, 0x0b83ec39, 0x4060efaa, 0x5e719f06, 0xbd6e1051, 0x3e218af9, 0x96dd063d, 0xdd3e05ae, 0x4de6bd46, 0x91548db5, 0x71c45d05, 0x0406d46f, 0x605015ff, 0x1998fb24, 0xd6bde997, 0x894043cc, 0x67d99e77, 0xb0e842bd, 0x07898b88, 0xe7195b38, 0x79c8eedb, 0xa17c0a47, 0x7c420fe9, 0xf8841ec9, 0x00000000, 0x09808683, 0x322bed48, 0x1e1170ac, 0x6c5a724e, 0xfd0efffb, 0x0f853856, 0x3daed51e, 0x362d3927, 0x0a0fd964, 0x685ca621, 0x9b5b54d1, 0x24362e3a, 0x0c0a67b1, 0x9357e70f, 0xb4ee96d2, 0x1b9b919e, 0x80c0c54f, 0x61dc20a2, 0x5a774b69, 0x1c121a16, 0xe293ba0a, 0xc0a02ae5, 0x3c22e043, 0x121b171d, 0x0e090d0b, 0xf28bc7ad, 0x2db6a8b9, 0x141ea9c8, 0x57f11985, 0xaf75074c, 0xee99ddbb, 0xa37f60fd, 0xf701269f, 0x5c72f5bc, 0x44663bc5, 0x5bfb7e34, 0x8b432976, 0xcb23c6dc, 0xb6edfc68, 0xb8e4f163, 0xd731dcca, 0x42638510, 0x13972240, 0x84c61120, 0x854a247d, 0xd2bb3df8, 0xaef93211, 0xc729a16d, 0x1d9e2f4b, 0xdcb230f3, 0x0d8652ec, 0x77c1e3d0, 0x2bb3166c, 0xa970b999, 0x119448fa, 0x47e96422, 0xa8fc8cc4, 0xa0f03f1a, 0x567d2cd8, 0x223390ef, 0x87494ec7, 0xd938d1c1, 0x8ccaa2fe, 0x98d40b36, 0xa6f581cf, 0xa57ade28, 0xdab78e26, 0x3fadbfa4, 0x2c3a9de4, 0x5078920d, 0x6a5fcc9b, 0x547e4662, 0xf68d13c2, 0x90d8b8e8, 0x2e39f75e, 0x82c3aff5, 0x9f5d80be, 0x69d0937c, 0x6fd52da9, 0xcf2512b3, 0xc8ac993b, 0x10187da7, 0xe89c636e, 0xdb3bbb7b, 0xcd267809, 0x6e5918f4, 0xec9ab701, 0x834f9aa8, 0xe6956e65, 0xaaffe67e, 0x21bccf08, 0xef15e8e6, 0xbae79bd9, 0x4a6f36ce, 0xea9f09d4, 0x29b07cd6, 0x31a4b2af, 0x2a3f2331, 0xc6a59430, 0x35a266c0, 0x744ebc37, 0xfc82caa6, 0xe090d0b0, 0x33a7d815, 0xf104984a, 0x41ecdaf7, 0x7fcd500e, 0x1791f62f, 0x764dd68d, 0x43efb04d, 0xccaa4d54, 0xe49604df, 0x9ed1b5e3, 0x4c6a881b, 0xc12c1fb8, 0x4665517f, 0x9d5eea04, 0x018c355d, 0xfa877473, 0xfb0b412e, 0xb3671d5a, 0x92dbd252, 0xe9105633, 0x6dd64713, 0x9ad7618c, 0x37a10c7a, 0x59f8148e, 0xeb133c89, 0xcea927ee, 0xb761c935, 0xe11ce5ed, 0x7a47b13c, 0x9cd2df59, 0x55f2733f, 0x1814ce79, 0x73c737bf, 0x53f7cdea, 0x5ffdaa5b, 0xdf3d6f14, 0x7844db86, 0xcaaff381, 0xb968c43e, 0x3824342c, 0xc2a3405f, 0x161dc372, 0xbce2250c, 0x283c498b, 0xff0d9541, 0x39a80171, 0x080cb3de, 0xd8b4e49c, 0x6456c190, 0x7bcb8461, 0xd532b670, 0x486c5c74, 0xd0b85742 ] T6 = [ 0x5051f4a7, 0x537e4165, 0xc31a17a4, 0x963a275e, 0xcb3bab6b, 0xf11f9d45, 0xabacfa58, 0x934be303, 0x552030fa, 0xf6ad766d, 0x9188cc76, 0x25f5024c, 0xfc4fe5d7, 0xd7c52acb, 0x80263544, 0x8fb562a3, 0x49deb15a, 0x6725ba1b, 0x9845ea0e, 0xe15dfec0, 0x02c32f75, 0x12814cf0, 0xa38d4697, 0xc66bd3f9, 0xe7038f5f, 0x9515929c, 0xebbf6d7a, 0xda955259, 0x2dd4be83, 0xd3587421, 0x2949e069, 0x448ec9c8, 0x6a75c289, 0x78f48e79, 0x6b99583e, 0xdd27b971, 0xb6bee14f, 0x17f088ad, 0x66c920ac, 0xb47dce3a, 0x1863df4a, 0x82e51a31, 0x60975133, 0x4562537f, 0xe0b16477, 0x84bb6bae, 0x1cfe81a0, 0x94f9082b, 0x58704868, 0x198f45fd, 0x8794de6c, 0xb7527bf8, 0x23ab73d3, 0xe2724b02, 0x57e31f8f, 0x2a6655ab, 0x07b2eb28, 0x032fb5c2, 0x9a86c57b, 0xa5d33708, 0xf2302887, 0xb223bfa5, 0xba02036a, 0x5ced1682, 0x2b8acf1c, 0x92a779b4, 0xf0f307f2, 0xa14e69e2, 0xcd65daf4, 0xd50605be, 0x1fd13462, 0x8ac4a6fe, 0x9d342e53, 0xa0a2f355, 0x32058ae1, 0x75a4f6eb, 0x390b83ec, 0xaa4060ef, 0x065e719f, 0x51bd6e10, 0xf93e218a, 0x3d96dd06, 0xaedd3e05, 0x464de6bd, 0xb591548d, 0x0571c45d, 0x6f0406d4, 0xff605015, 0x241998fb, 0x97d6bde9, 0xcc894043, 0x7767d99e, 0xbdb0e842, 0x8807898b, 0x38e7195b, 0xdb79c8ee, 0x47a17c0a, 0xe97c420f, 0xc9f8841e, 0x00000000, 0x83098086, 0x48322bed, 0xac1e1170, 0x4e6c5a72, 0xfbfd0eff, 0x560f8538, 0x1e3daed5, 0x27362d39, 0x640a0fd9, 0x21685ca6, 0xd19b5b54, 0x3a24362e, 0xb10c0a67, 0x0f9357e7, 0xd2b4ee96, 0x9e1b9b91, 0x4f80c0c5, 0xa261dc20, 0x695a774b, 0x161c121a, 0x0ae293ba, 0xe5c0a02a, 0x433c22e0, 0x1d121b17, 0x0b0e090d, 0xadf28bc7, 0xb92db6a8, 0xc8141ea9, 0x8557f119, 0x4caf7507, 0xbbee99dd, 0xfda37f60, 0x9ff70126, 0xbc5c72f5, 0xc544663b, 0x345bfb7e, 0x768b4329, 0xdccb23c6, 0x68b6edfc, 0x63b8e4f1, 0xcad731dc, 0x10426385, 0x40139722, 0x2084c611, 0x7d854a24, 0xf8d2bb3d, 0x11aef932, 0x6dc729a1, 0x4b1d9e2f, 0xf3dcb230, 0xec0d8652, 0xd077c1e3, 0x6c2bb316, 0x99a970b9, 0xfa119448, 0x2247e964, 0xc4a8fc8c, 0x1aa0f03f, 0xd8567d2c, 0xef223390, 0xc787494e, 0xc1d938d1, 0xfe8ccaa2, 0x3698d40b, 0xcfa6f581, 0x28a57ade, 0x26dab78e, 0xa43fadbf, 0xe42c3a9d, 0x0d507892, 0x9b6a5fcc, 0x62547e46, 0xc2f68d13, 0xe890d8b8, 0x5e2e39f7, 0xf582c3af, 0xbe9f5d80, 0x7c69d093, 0xa96fd52d, 0xb3cf2512, 0x3bc8ac99, 0xa710187d, 0x6ee89c63, 0x7bdb3bbb, 0x09cd2678, 0xf46e5918, 0x01ec9ab7, 0xa8834f9a, 0x65e6956e, 0x7eaaffe6, 0x0821bccf, 0xe6ef15e8, 0xd9bae79b, 0xce4a6f36, 0xd4ea9f09, 0xd629b07c, 0xaf31a4b2, 0x312a3f23, 0x30c6a594, 0xc035a266, 0x37744ebc, 0xa6fc82ca, 0xb0e090d0, 0x1533a7d8, 0x4af10498, 0xf741ecda, 0x0e7fcd50, 0x2f1791f6, 0x8d764dd6, 0x4d43efb0, 0x54ccaa4d, 0xdfe49604, 0xe39ed1b5, 0x1b4c6a88, 0xb8c12c1f, 0x7f466551, 0x049d5eea, 0x5d018c35, 0x73fa8774, 0x2efb0b41, 0x5ab3671d, 0x5292dbd2, 0x33e91056, 0x136dd647, 0x8c9ad761, 0x7a37a10c, 0x8e59f814, 0x89eb133c, 0xeecea927, 0x35b761c9, 0xede11ce5, 0x3c7a47b1, 0x599cd2df, 0x3f55f273, 0x791814ce, 0xbf73c737, 0xea53f7cd, 0x5b5ffdaa, 0x14df3d6f, 0x867844db, 0x81caaff3, 0x3eb968c4, 0x2c382434, 0x5fc2a340, 0x72161dc3, 0x0cbce225, 0x8b283c49, 0x41ff0d95, 0x7139a801, 0xde080cb3, 0x9cd8b4e4, 0x906456c1, 0x617bcb84, 0x70d532b6, 0x74486c5c, 0x42d0b857 ] T7 = [ 0xa75051f4, 0x65537e41, 0xa4c31a17, 0x5e963a27, 0x6bcb3bab, 0x45f11f9d, 0x58abacfa, 0x03934be3, 0xfa552030, 0x6df6ad76, 0x769188cc, 0x4c25f502, 0xd7fc4fe5, 0xcbd7c52a, 0x44802635, 0xa38fb562, 0x5a49deb1, 0x1b6725ba, 0x0e9845ea, 0xc0e15dfe, 0x7502c32f, 0xf012814c, 0x97a38d46, 0xf9c66bd3, 0x5fe7038f, 0x9c951592, 0x7aebbf6d, 0x59da9552, 0x832dd4be, 0x21d35874, 0x692949e0, 0xc8448ec9, 0x896a75c2, 0x7978f48e, 0x3e6b9958, 0x71dd27b9, 0x4fb6bee1, 0xad17f088, 0xac66c920, 0x3ab47dce, 0x4a1863df, 0x3182e51a, 0x33609751, 0x7f456253, 0x77e0b164, 0xae84bb6b, 0xa01cfe81, 0x2b94f908, 0x68587048, 0xfd198f45, 0x6c8794de, 0xf8b7527b, 0xd323ab73, 0x02e2724b, 0x8f57e31f, 0xab2a6655, 0x2807b2eb, 0xc2032fb5, 0x7b9a86c5, 0x08a5d337, 0x87f23028, 0xa5b223bf, 0x6aba0203, 0x825ced16, 0x1c2b8acf, 0xb492a779, 0xf2f0f307, 0xe2a14e69, 0xf4cd65da, 0xbed50605, 0x621fd134, 0xfe8ac4a6, 0x539d342e, 0x55a0a2f3, 0xe132058a, 0xeb75a4f6, 0xec390b83, 0xefaa4060, 0x9f065e71, 0x1051bd6e, 0x8af93e21, 0x063d96dd, 0x05aedd3e, 0xbd464de6, 0x8db59154, 0x5d0571c4, 0xd46f0406, 0x15ff6050, 0xfb241998, 0xe997d6bd, 0x43cc8940, 0x9e7767d9, 0x42bdb0e8, 0x8b880789, 0x5b38e719, 0xeedb79c8, 0x0a47a17c, 0x0fe97c42, 0x1ec9f884, 0x00000000, 0x86830980, 0xed48322b, 0x70ac1e11, 0x724e6c5a, 0xfffbfd0e, 0x38560f85, 0xd51e3dae, 0x3927362d, 0xd9640a0f, 0xa621685c, 0x54d19b5b, 0x2e3a2436, 0x67b10c0a, 0xe70f9357, 0x96d2b4ee, 0x919e1b9b, 0xc54f80c0, 0x20a261dc, 0x4b695a77, 0x1a161c12, 0xba0ae293, 0x2ae5c0a0, 0xe0433c22, 0x171d121b, 0x0d0b0e09, 0xc7adf28b, 0xa8b92db6, 0xa9c8141e, 0x198557f1, 0x074caf75, 0xddbbee99, 0x60fda37f, 0x269ff701, 0xf5bc5c72, 0x3bc54466, 0x7e345bfb, 0x29768b43, 0xc6dccb23, 0xfc68b6ed, 0xf163b8e4, 0xdccad731, 0x85104263, 0x22401397, 0x112084c6, 0x247d854a, 0x3df8d2bb, 0x3211aef9, 0xa16dc729, 0x2f4b1d9e, 0x30f3dcb2, 0x52ec0d86, 0xe3d077c1, 0x166c2bb3, 0xb999a970, 0x48fa1194, 0x642247e9, 0x8cc4a8fc, 0x3f1aa0f0, 0x2cd8567d, 0x90ef2233, 0x4ec78749, 0xd1c1d938, 0xa2fe8cca, 0x0b3698d4, 0x81cfa6f5, 0xde28a57a, 0x8e26dab7, 0xbfa43fad, 0x9de42c3a, 0x920d5078, 0xcc9b6a5f, 0x4662547e, 0x13c2f68d, 0xb8e890d8, 0xf75e2e39, 0xaff582c3, 0x80be9f5d, 0x937c69d0, 0x2da96fd5, 0x12b3cf25, 0x993bc8ac, 0x7da71018, 0x636ee89c, 0xbb7bdb3b, 0x7809cd26, 0x18f46e59, 0xb701ec9a, 0x9aa8834f, 0x6e65e695, 0xe67eaaff, 0xcf0821bc, 0xe8e6ef15, 0x9bd9bae7, 0x36ce4a6f, 0x09d4ea9f, 0x7cd629b0, 0xb2af31a4, 0x23312a3f, 0x9430c6a5, 0x66c035a2, 0xbc37744e, 0xcaa6fc82, 0xd0b0e090, 0xd81533a7, 0x984af104, 0xdaf741ec, 0x500e7fcd, 0xf62f1791, 0xd68d764d, 0xb04d43ef, 0x4d54ccaa, 0x04dfe496, 0xb5e39ed1, 0x881b4c6a, 0x1fb8c12c, 0x517f4665, 0xea049d5e, 0x355d018c, 0x7473fa87, 0x412efb0b, 0x1d5ab367, 0xd25292db, 0x5633e910, 0x47136dd6, 0x618c9ad7, 0x0c7a37a1, 0x148e59f8, 0x3c89eb13, 0x27eecea9, 0xc935b761, 0xe5ede11c, 0xb13c7a47, 0xdf599cd2, 0x733f55f2, 0xce791814, 0x37bf73c7, 0xcdea53f7, 0xaa5b5ffd, 0x6f14df3d, 0xdb867844, 0xf381caaf, 0xc43eb968, 0x342c3824, 0x405fc2a3, 0xc372161d, 0x250cbce2, 0x498b283c, 0x9541ff0d, 0x017139a8, 0xb3de080c, 0xe49cd8b4, 0xc1906456, 0x84617bcb, 0xb670d532, 0x5c74486c, 0x5742d0b8 ] T8 = [ 0xf4a75051, 0x4165537e, 0x17a4c31a, 0x275e963a, 0xab6bcb3b, 0x9d45f11f, 0xfa58abac, 0xe303934b, 0x30fa5520, 0x766df6ad, 0xcc769188, 0x024c25f5, 0xe5d7fc4f, 0x2acbd7c5, 0x35448026, 0x62a38fb5, 0xb15a49de, 0xba1b6725, 0xea0e9845, 0xfec0e15d, 0x2f7502c3, 0x4cf01281, 0x4697a38d, 0xd3f9c66b, 0x8f5fe703, 0x929c9515, 0x6d7aebbf, 0x5259da95, 0xbe832dd4, 0x7421d358, 0xe0692949, 0xc9c8448e, 0xc2896a75, 0x8e7978f4, 0x583e6b99, 0xb971dd27, 0xe14fb6be, 0x88ad17f0, 0x20ac66c9, 0xce3ab47d, 0xdf4a1863, 0x1a3182e5, 0x51336097, 0x537f4562, 0x6477e0b1, 0x6bae84bb, 0x81a01cfe, 0x082b94f9, 0x48685870, 0x45fd198f, 0xde6c8794, 0x7bf8b752, 0x73d323ab, 0x4b02e272, 0x1f8f57e3, 0x55ab2a66, 0xeb2807b2, 0xb5c2032f, 0xc57b9a86, 0x3708a5d3, 0x2887f230, 0xbfa5b223, 0x036aba02, 0x16825ced, 0xcf1c2b8a, 0x79b492a7, 0x07f2f0f3, 0x69e2a14e, 0xdaf4cd65, 0x05bed506, 0x34621fd1, 0xa6fe8ac4, 0x2e539d34, 0xf355a0a2, 0x8ae13205, 0xf6eb75a4, 0x83ec390b, 0x60efaa40, 0x719f065e, 0x6e1051bd, 0x218af93e, 0xdd063d96, 0x3e05aedd, 0xe6bd464d, 0x548db591, 0xc45d0571, 0x06d46f04, 0x5015ff60, 0x98fb2419, 0xbde997d6, 0x4043cc89, 0xd99e7767, 0xe842bdb0, 0x898b8807, 0x195b38e7, 0xc8eedb79, 0x7c0a47a1, 0x420fe97c, 0x841ec9f8, 0x00000000, 0x80868309, 0x2bed4832, 0x1170ac1e, 0x5a724e6c, 0x0efffbfd, 0x8538560f, 0xaed51e3d, 0x2d392736, 0x0fd9640a, 0x5ca62168, 0x5b54d19b, 0x362e3a24, 0x0a67b10c, 0x57e70f93, 0xee96d2b4, 0x9b919e1b, 0xc0c54f80, 0xdc20a261, 0x774b695a, 0x121a161c, 0x93ba0ae2, 0xa02ae5c0, 0x22e0433c, 0x1b171d12, 0x090d0b0e, 0x8bc7adf2, 0xb6a8b92d, 0x1ea9c814, 0xf1198557, 0x75074caf, 0x99ddbbee, 0x7f60fda3, 0x01269ff7, 0x72f5bc5c, 0x663bc544, 0xfb7e345b, 0x4329768b, 0x23c6dccb, 0xedfc68b6, 0xe4f163b8, 0x31dccad7, 0x63851042, 0x97224013, 0xc6112084, 0x4a247d85, 0xbb3df8d2, 0xf93211ae, 0x29a16dc7, 0x9e2f4b1d, 0xb230f3dc, 0x8652ec0d, 0xc1e3d077, 0xb3166c2b, 0x70b999a9, 0x9448fa11, 0xe9642247, 0xfc8cc4a8, 0xf03f1aa0, 0x7d2cd856, 0x3390ef22, 0x494ec787, 0x38d1c1d9, 0xcaa2fe8c, 0xd40b3698, 0xf581cfa6, 0x7ade28a5, 0xb78e26da, 0xadbfa43f, 0x3a9de42c, 0x78920d50, 0x5fcc9b6a, 0x7e466254, 0x8d13c2f6, 0xd8b8e890, 0x39f75e2e, 0xc3aff582, 0x5d80be9f, 0xd0937c69, 0xd52da96f, 0x2512b3cf, 0xac993bc8, 0x187da710, 0x9c636ee8, 0x3bbb7bdb, 0x267809cd, 0x5918f46e, 0x9ab701ec, 0x4f9aa883, 0x956e65e6, 0xffe67eaa, 0xbccf0821, 0x15e8e6ef, 0xe79bd9ba, 0x6f36ce4a, 0x9f09d4ea, 0xb07cd629, 0xa4b2af31, 0x3f23312a, 0xa59430c6, 0xa266c035, 0x4ebc3774, 0x82caa6fc, 0x90d0b0e0, 0xa7d81533, 0x04984af1, 0xecdaf741, 0xcd500e7f, 0x91f62f17, 0x4dd68d76, 0xefb04d43, 0xaa4d54cc, 0x9604dfe4, 0xd1b5e39e, 0x6a881b4c, 0x2c1fb8c1, 0x65517f46, 0x5eea049d, 0x8c355d01, 0x877473fa, 0x0b412efb, 0x671d5ab3, 0xdbd25292, 0x105633e9, 0xd647136d, 0xd7618c9a, 0xa10c7a37, 0xf8148e59, 0x133c89eb, 0xa927eece, 0x61c935b7, 0x1ce5ede1, 0x47b13c7a, 0xd2df599c, 0xf2733f55, 0x14ce7918, 0xc737bf73, 0xf7cdea53, 0xfdaa5b5f, 0x3d6f14df, 0x44db8678, 0xaff381ca, 0x68c43eb9, 0x24342c38, 0xa3405fc2, 0x1dc37216, 0xe2250cbc, 0x3c498b28, 0x0d9541ff, 0xa8017139, 0x0cb3de08, 0xb4e49cd8, 0x56c19064, 0xcb84617b, 0x32b670d5, 0x6c5c7448, 0xb85742d0 ] # Transformations for decryption key expansion U1 = [ 0x00000000, 0x0e090d0b, 0x1c121a16, 0x121b171d, 0x3824342c, 0x362d3927, 0x24362e3a, 0x2a3f2331, 0x70486858, 0x7e416553, 0x6c5a724e, 0x62537f45, 0x486c5c74, 0x4665517f, 0x547e4662, 0x5a774b69, 0xe090d0b0, 0xee99ddbb, 0xfc82caa6, 0xf28bc7ad, 0xd8b4e49c, 0xd6bde997, 0xc4a6fe8a, 0xcaaff381, 0x90d8b8e8, 0x9ed1b5e3, 0x8ccaa2fe, 0x82c3aff5, 0xa8fc8cc4, 0xa6f581cf, 0xb4ee96d2, 0xbae79bd9, 0xdb3bbb7b, 0xd532b670, 0xc729a16d, 0xc920ac66, 0xe31f8f57, 0xed16825c, 0xff0d9541, 0xf104984a, 0xab73d323, 0xa57ade28, 0xb761c935, 0xb968c43e, 0x9357e70f, 0x9d5eea04, 0x8f45fd19, 0x814cf012, 0x3bab6bcb, 0x35a266c0, 0x27b971dd, 0x29b07cd6, 0x038f5fe7, 0x0d8652ec, 0x1f9d45f1, 0x119448fa, 0x4be30393, 0x45ea0e98, 0x57f11985, 0x59f8148e, 0x73c737bf, 0x7dce3ab4, 0x6fd52da9, 0x61dc20a2, 0xad766df6, 0xa37f60fd, 0xb16477e0, 0xbf6d7aeb, 0x955259da, 0x9b5b54d1, 0x894043cc, 0x87494ec7, 0xdd3e05ae, 0xd33708a5, 0xc12c1fb8, 0xcf2512b3, 0xe51a3182, 0xeb133c89, 0xf9082b94, 0xf701269f, 0x4de6bd46, 0x43efb04d, 0x51f4a750, 0x5ffdaa5b, 0x75c2896a, 0x7bcb8461, 0x69d0937c, 0x67d99e77, 0x3daed51e, 0x33a7d815, 0x21bccf08, 0x2fb5c203, 0x058ae132, 0x0b83ec39, 0x1998fb24, 0x1791f62f, 0x764dd68d, 0x7844db86, 0x6a5fcc9b, 0x6456c190, 0x4e69e2a1, 0x4060efaa, 0x527bf8b7, 0x5c72f5bc, 0x0605bed5, 0x080cb3de, 0x1a17a4c3, 0x141ea9c8, 0x3e218af9, 0x302887f2, 0x223390ef, 0x2c3a9de4, 0x96dd063d, 0x98d40b36, 0x8acf1c2b, 0x84c61120, 0xaef93211, 0xa0f03f1a, 0xb2eb2807, 0xbce2250c, 0xe6956e65, 0xe89c636e, 0xfa877473, 0xf48e7978, 0xdeb15a49, 0xd0b85742, 0xc2a3405f, 0xccaa4d54, 0x41ecdaf7, 0x4fe5d7fc, 0x5dfec0e1, 0x53f7cdea, 0x79c8eedb, 0x77c1e3d0, 0x65daf4cd, 0x6bd3f9c6, 0x31a4b2af, 0x3fadbfa4, 0x2db6a8b9, 0x23bfa5b2, 0x09808683, 0x07898b88, 0x15929c95, 0x1b9b919e, 0xa17c0a47, 0xaf75074c, 0xbd6e1051, 0xb3671d5a, 0x99583e6b, 0x97513360, 0x854a247d, 0x8b432976, 0xd134621f, 0xdf3d6f14, 0xcd267809, 0xc32f7502, 0xe9105633, 0xe7195b38, 0xf5024c25, 0xfb0b412e, 0x9ad7618c, 0x94de6c87, 0x86c57b9a, 0x88cc7691, 0xa2f355a0, 0xacfa58ab, 0xbee14fb6, 0xb0e842bd, 0xea9f09d4, 0xe49604df, 0xf68d13c2, 0xf8841ec9, 0xd2bb3df8, 0xdcb230f3, 0xcea927ee, 0xc0a02ae5, 0x7a47b13c, 0x744ebc37, 0x6655ab2a, 0x685ca621, 0x42638510, 0x4c6a881b, 0x5e719f06, 0x5078920d, 0x0a0fd964, 0x0406d46f, 0x161dc372, 0x1814ce79, 0x322bed48, 0x3c22e043, 0x2e39f75e, 0x2030fa55, 0xec9ab701, 0xe293ba0a, 0xf088ad17, 0xfe81a01c, 0xd4be832d, 0xdab78e26, 0xc8ac993b, 0xc6a59430, 0x9cd2df59, 0x92dbd252, 0x80c0c54f, 0x8ec9c844, 0xa4f6eb75, 0xaaffe67e, 0xb8e4f163, 0xb6edfc68, 0x0c0a67b1, 0x02036aba, 0x10187da7, 0x1e1170ac, 0x342e539d, 0x3a275e96, 0x283c498b, 0x26354480, 0x7c420fe9, 0x724b02e2, 0x605015ff, 0x6e5918f4, 0x44663bc5, 0x4a6f36ce, 0x587421d3, 0x567d2cd8, 0x37a10c7a, 0x39a80171, 0x2bb3166c, 0x25ba1b67, 0x0f853856, 0x018c355d, 0x13972240, 0x1d9e2f4b, 0x47e96422, 0x49e06929, 0x5bfb7e34, 0x55f2733f, 0x7fcd500e, 0x71c45d05, 0x63df4a18, 0x6dd64713, 0xd731dcca, 0xd938d1c1, 0xcb23c6dc, 0xc52acbd7, 0xef15e8e6, 0xe11ce5ed, 0xf307f2f0, 0xfd0efffb, 0xa779b492, 0xa970b999, 0xbb6bae84, 0xb562a38f, 0x9f5d80be, 0x91548db5, 0x834f9aa8, 0x8d4697a3 ] U2 = [ 0x00000000, 0x0b0e090d, 0x161c121a, 0x1d121b17, 0x2c382434, 0x27362d39, 0x3a24362e, 0x312a3f23, 0x58704868, 0x537e4165, 0x4e6c5a72, 0x4562537f, 0x74486c5c, 0x7f466551, 0x62547e46, 0x695a774b, 0xb0e090d0, 0xbbee99dd, 0xa6fc82ca, 0xadf28bc7, 0x9cd8b4e4, 0x97d6bde9, 0x8ac4a6fe, 0x81caaff3, 0xe890d8b8, 0xe39ed1b5, 0xfe8ccaa2, 0xf582c3af, 0xc4a8fc8c, 0xcfa6f581, 0xd2b4ee96, 0xd9bae79b, 0x7bdb3bbb, 0x70d532b6, 0x6dc729a1, 0x66c920ac, 0x57e31f8f, 0x5ced1682, 0x41ff0d95, 0x4af10498, 0x23ab73d3, 0x28a57ade, 0x35b761c9, 0x3eb968c4, 0x0f9357e7, 0x049d5eea, 0x198f45fd, 0x12814cf0, 0xcb3bab6b, 0xc035a266, 0xdd27b971, 0xd629b07c, 0xe7038f5f, 0xec0d8652, 0xf11f9d45, 0xfa119448, 0x934be303, 0x9845ea0e, 0x8557f119, 0x8e59f814, 0xbf73c737, 0xb47dce3a, 0xa96fd52d, 0xa261dc20, 0xf6ad766d, 0xfda37f60, 0xe0b16477, 0xebbf6d7a, 0xda955259, 0xd19b5b54, 0xcc894043, 0xc787494e, 0xaedd3e05, 0xa5d33708, 0xb8c12c1f, 0xb3cf2512, 0x82e51a31, 0x89eb133c, 0x94f9082b, 0x9ff70126, 0x464de6bd, 0x4d43efb0, 0x5051f4a7, 0x5b5ffdaa, 0x6a75c289, 0x617bcb84, 0x7c69d093, 0x7767d99e, 0x1e3daed5, 0x1533a7d8, 0x0821bccf, 0x032fb5c2, 0x32058ae1, 0x390b83ec, 0x241998fb, 0x2f1791f6, 0x8d764dd6, 0x867844db, 0x9b6a5fcc, 0x906456c1, 0xa14e69e2, 0xaa4060ef, 0xb7527bf8, 0xbc5c72f5, 0xd50605be, 0xde080cb3, 0xc31a17a4, 0xc8141ea9, 0xf93e218a, 0xf2302887, 0xef223390, 0xe42c3a9d, 0x3d96dd06, 0x3698d40b, 0x2b8acf1c, 0x2084c611, 0x11aef932, 0x1aa0f03f, 0x07b2eb28, 0x0cbce225, 0x65e6956e, 0x6ee89c63, 0x73fa8774, 0x78f48e79, 0x49deb15a, 0x42d0b857, 0x5fc2a340, 0x54ccaa4d, 0xf741ecda, 0xfc4fe5d7, 0xe15dfec0, 0xea53f7cd, 0xdb79c8ee, 0xd077c1e3, 0xcd65daf4, 0xc66bd3f9, 0xaf31a4b2, 0xa43fadbf, 0xb92db6a8, 0xb223bfa5, 0x83098086, 0x8807898b, 0x9515929c, 0x9e1b9b91, 0x47a17c0a, 0x4caf7507, 0x51bd6e10, 0x5ab3671d, 0x6b99583e, 0x60975133, 0x7d854a24, 0x768b4329, 0x1fd13462, 0x14df3d6f, 0x09cd2678, 0x02c32f75, 0x33e91056, 0x38e7195b, 0x25f5024c, 0x2efb0b41, 0x8c9ad761, 0x8794de6c, 0x9a86c57b, 0x9188cc76, 0xa0a2f355, 0xabacfa58, 0xb6bee14f, 0xbdb0e842, 0xd4ea9f09, 0xdfe49604, 0xc2f68d13, 0xc9f8841e, 0xf8d2bb3d, 0xf3dcb230, 0xeecea927, 0xe5c0a02a, 0x3c7a47b1, 0x37744ebc, 0x2a6655ab, 0x21685ca6, 0x10426385, 0x1b4c6a88, 0x065e719f, 0x0d507892, 0x640a0fd9, 0x6f0406d4, 0x72161dc3, 0x791814ce, 0x48322bed, 0x433c22e0, 0x5e2e39f7, 0x552030fa, 0x01ec9ab7, 0x0ae293ba, 0x17f088ad, 0x1cfe81a0, 0x2dd4be83, 0x26dab78e, 0x3bc8ac99, 0x30c6a594, 0x599cd2df, 0x5292dbd2, 0x4f80c0c5, 0x448ec9c8, 0x75a4f6eb, 0x7eaaffe6, 0x63b8e4f1, 0x68b6edfc, 0xb10c0a67, 0xba02036a, 0xa710187d, 0xac1e1170, 0x9d342e53, 0x963a275e, 0x8b283c49, 0x80263544, 0xe97c420f, 0xe2724b02, 0xff605015, 0xf46e5918, 0xc544663b, 0xce4a6f36, 0xd3587421, 0xd8567d2c, 0x7a37a10c, 0x7139a801, 0x6c2bb316, 0x6725ba1b, 0x560f8538, 0x5d018c35, 0x40139722, 0x4b1d9e2f, 0x2247e964, 0x2949e069, 0x345bfb7e, 0x3f55f273, 0x0e7fcd50, 0x0571c45d, 0x1863df4a, 0x136dd647, 0xcad731dc, 0xc1d938d1, 0xdccb23c6, 0xd7c52acb, 0xe6ef15e8, 0xede11ce5, 0xf0f307f2, 0xfbfd0eff, 0x92a779b4, 0x99a970b9, 0x84bb6bae, 0x8fb562a3, 0xbe9f5d80, 0xb591548d, 0xa8834f9a, 0xa38d4697 ] U3 = [ 0x00000000, 0x0d0b0e09, 0x1a161c12, 0x171d121b, 0x342c3824, 0x3927362d, 0x2e3a2436, 0x23312a3f, 0x68587048, 0x65537e41, 0x724e6c5a, 0x7f456253, 0x5c74486c, 0x517f4665, 0x4662547e, 0x4b695a77, 0xd0b0e090, 0xddbbee99, 0xcaa6fc82, 0xc7adf28b, 0xe49cd8b4, 0xe997d6bd, 0xfe8ac4a6, 0xf381caaf, 0xb8e890d8, 0xb5e39ed1, 0xa2fe8cca, 0xaff582c3, 0x8cc4a8fc, 0x81cfa6f5, 0x96d2b4ee, 0x9bd9bae7, 0xbb7bdb3b, 0xb670d532, 0xa16dc729, 0xac66c920, 0x8f57e31f, 0x825ced16, 0x9541ff0d, 0x984af104, 0xd323ab73, 0xde28a57a, 0xc935b761, 0xc43eb968, 0xe70f9357, 0xea049d5e, 0xfd198f45, 0xf012814c, 0x6bcb3bab, 0x66c035a2, 0x71dd27b9, 0x7cd629b0, 0x5fe7038f, 0x52ec0d86, 0x45f11f9d, 0x48fa1194, 0x03934be3, 0x0e9845ea, 0x198557f1, 0x148e59f8, 0x37bf73c7, 0x3ab47dce, 0x2da96fd5, 0x20a261dc, 0x6df6ad76, 0x60fda37f, 0x77e0b164, 0x7aebbf6d, 0x59da9552, 0x54d19b5b, 0x43cc8940, 0x4ec78749, 0x05aedd3e, 0x08a5d337, 0x1fb8c12c, 0x12b3cf25, 0x3182e51a, 0x3c89eb13, 0x2b94f908, 0x269ff701, 0xbd464de6, 0xb04d43ef, 0xa75051f4, 0xaa5b5ffd, 0x896a75c2, 0x84617bcb, 0x937c69d0, 0x9e7767d9, 0xd51e3dae, 0xd81533a7, 0xcf0821bc, 0xc2032fb5, 0xe132058a, 0xec390b83, 0xfb241998, 0xf62f1791, 0xd68d764d, 0xdb867844, 0xcc9b6a5f, 0xc1906456, 0xe2a14e69, 0xefaa4060, 0xf8b7527b, 0xf5bc5c72, 0xbed50605, 0xb3de080c, 0xa4c31a17, 0xa9c8141e, 0x8af93e21, 0x87f23028, 0x90ef2233, 0x9de42c3a, 0x063d96dd, 0x0b3698d4, 0x1c2b8acf, 0x112084c6, 0x3211aef9, 0x3f1aa0f0, 0x2807b2eb, 0x250cbce2, 0x6e65e695, 0x636ee89c, 0x7473fa87, 0x7978f48e, 0x5a49deb1, 0x5742d0b8, 0x405fc2a3, 0x4d54ccaa, 0xdaf741ec, 0xd7fc4fe5, 0xc0e15dfe, 0xcdea53f7, 0xeedb79c8, 0xe3d077c1, 0xf4cd65da, 0xf9c66bd3, 0xb2af31a4, 0xbfa43fad, 0xa8b92db6, 0xa5b223bf, 0x86830980, 0x8b880789, 0x9c951592, 0x919e1b9b, 0x0a47a17c, 0x074caf75, 0x1051bd6e, 0x1d5ab367, 0x3e6b9958, 0x33609751, 0x247d854a, 0x29768b43, 0x621fd134, 0x6f14df3d, 0x7809cd26, 0x7502c32f, 0x5633e910, 0x5b38e719, 0x4c25f502, 0x412efb0b, 0x618c9ad7, 0x6c8794de, 0x7b9a86c5, 0x769188cc, 0x55a0a2f3, 0x58abacfa, 0x4fb6bee1, 0x42bdb0e8, 0x09d4ea9f, 0x04dfe496, 0x13c2f68d, 0x1ec9f884, 0x3df8d2bb, 0x30f3dcb2, 0x27eecea9, 0x2ae5c0a0, 0xb13c7a47, 0xbc37744e, 0xab2a6655, 0xa621685c, 0x85104263, 0x881b4c6a, 0x9f065e71, 0x920d5078, 0xd9640a0f, 0xd46f0406, 0xc372161d, 0xce791814, 0xed48322b, 0xe0433c22, 0xf75e2e39, 0xfa552030, 0xb701ec9a, 0xba0ae293, 0xad17f088, 0xa01cfe81, 0x832dd4be, 0x8e26dab7, 0x993bc8ac, 0x9430c6a5, 0xdf599cd2, 0xd25292db, 0xc54f80c0, 0xc8448ec9, 0xeb75a4f6, 0xe67eaaff, 0xf163b8e4, 0xfc68b6ed, 0x67b10c0a, 0x6aba0203, 0x7da71018, 0x70ac1e11, 0x539d342e, 0x5e963a27, 0x498b283c, 0x44802635, 0x0fe97c42, 0x02e2724b, 0x15ff6050, 0x18f46e59, 0x3bc54466, 0x36ce4a6f, 0x21d35874, 0x2cd8567d, 0x0c7a37a1, 0x017139a8, 0x166c2bb3, 0x1b6725ba, 0x38560f85, 0x355d018c, 0x22401397, 0x2f4b1d9e, 0x642247e9, 0x692949e0, 0x7e345bfb, 0x733f55f2, 0x500e7fcd, 0x5d0571c4, 0x4a1863df, 0x47136dd6, 0xdccad731, 0xd1c1d938, 0xc6dccb23, 0xcbd7c52a, 0xe8e6ef15, 0xe5ede11c, 0xf2f0f307, 0xfffbfd0e, 0xb492a779, 0xb999a970, 0xae84bb6b, 0xa38fb562, 0x80be9f5d, 0x8db59154, 0x9aa8834f, 0x97a38d46 ] U4 = [ 0x00000000, 0x090d0b0e, 0x121a161c, 0x1b171d12, 0x24342c38, 0x2d392736, 0x362e3a24, 0x3f23312a, 0x48685870, 0x4165537e, 0x5a724e6c, 0x537f4562, 0x6c5c7448, 0x65517f46, 0x7e466254, 0x774b695a, 0x90d0b0e0, 0x99ddbbee, 0x82caa6fc, 0x8bc7adf2, 0xb4e49cd8, 0xbde997d6, 0xa6fe8ac4, 0xaff381ca, 0xd8b8e890, 0xd1b5e39e, 0xcaa2fe8c, 0xc3aff582, 0xfc8cc4a8, 0xf581cfa6, 0xee96d2b4, 0xe79bd9ba, 0x3bbb7bdb, 0x32b670d5, 0x29a16dc7, 0x20ac66c9, 0x1f8f57e3, 0x16825ced, 0x0d9541ff, 0x04984af1, 0x73d323ab, 0x7ade28a5, 0x61c935b7, 0x68c43eb9, 0x57e70f93, 0x5eea049d, 0x45fd198f, 0x4cf01281, 0xab6bcb3b, 0xa266c035, 0xb971dd27, 0xb07cd629, 0x8f5fe703, 0x8652ec0d, 0x9d45f11f, 0x9448fa11, 0xe303934b, 0xea0e9845, 0xf1198557, 0xf8148e59, 0xc737bf73, 0xce3ab47d, 0xd52da96f, 0xdc20a261, 0x766df6ad, 0x7f60fda3, 0x6477e0b1, 0x6d7aebbf, 0x5259da95, 0x5b54d19b, 0x4043cc89, 0x494ec787, 0x3e05aedd, 0x3708a5d3, 0x2c1fb8c1, 0x2512b3cf, 0x1a3182e5, 0x133c89eb, 0x082b94f9, 0x01269ff7, 0xe6bd464d, 0xefb04d43, 0xf4a75051, 0xfdaa5b5f, 0xc2896a75, 0xcb84617b, 0xd0937c69, 0xd99e7767, 0xaed51e3d, 0xa7d81533, 0xbccf0821, 0xb5c2032f, 0x8ae13205, 0x83ec390b, 0x98fb2419, 0x91f62f17, 0x4dd68d76, 0x44db8678, 0x5fcc9b6a, 0x56c19064, 0x69e2a14e, 0x60efaa40, 0x7bf8b752, 0x72f5bc5c, 0x05bed506, 0x0cb3de08, 0x17a4c31a, 0x1ea9c814, 0x218af93e, 0x2887f230, 0x3390ef22, 0x3a9de42c, 0xdd063d96, 0xd40b3698, 0xcf1c2b8a, 0xc6112084, 0xf93211ae, 0xf03f1aa0, 0xeb2807b2, 0xe2250cbc, 0x956e65e6, 0x9c636ee8, 0x877473fa, 0x8e7978f4, 0xb15a49de, 0xb85742d0, 0xa3405fc2, 0xaa4d54cc, 0xecdaf741, 0xe5d7fc4f, 0xfec0e15d, 0xf7cdea53, 0xc8eedb79, 0xc1e3d077, 0xdaf4cd65, 0xd3f9c66b, 0xa4b2af31, 0xadbfa43f, 0xb6a8b92d, 0xbfa5b223, 0x80868309, 0x898b8807, 0x929c9515, 0x9b919e1b, 0x7c0a47a1, 0x75074caf, 0x6e1051bd, 0x671d5ab3, 0x583e6b99, 0x51336097, 0x4a247d85, 0x4329768b, 0x34621fd1, 0x3d6f14df, 0x267809cd, 0x2f7502c3, 0x105633e9, 0x195b38e7, 0x024c25f5, 0x0b412efb, 0xd7618c9a, 0xde6c8794, 0xc57b9a86, 0xcc769188, 0xf355a0a2, 0xfa58abac, 0xe14fb6be, 0xe842bdb0, 0x9f09d4ea, 0x9604dfe4, 0x8d13c2f6, 0x841ec9f8, 0xbb3df8d2, 0xb230f3dc, 0xa927eece, 0xa02ae5c0, 0x47b13c7a, 0x4ebc3774, 0x55ab2a66, 0x5ca62168, 0x63851042, 0x6a881b4c, 0x719f065e, 0x78920d50, 0x0fd9640a, 0x06d46f04, 0x1dc37216, 0x14ce7918, 0x2bed4832, 0x22e0433c, 0x39f75e2e, 0x30fa5520, 0x9ab701ec, 0x93ba0ae2, 0x88ad17f0, 0x81a01cfe, 0xbe832dd4, 0xb78e26da, 0xac993bc8, 0xa59430c6, 0xd2df599c, 0xdbd25292, 0xc0c54f80, 0xc9c8448e, 0xf6eb75a4, 0xffe67eaa, 0xe4f163b8, 0xedfc68b6, 0x0a67b10c, 0x036aba02, 0x187da710, 0x1170ac1e, 0x2e539d34, 0x275e963a, 0x3c498b28, 0x35448026, 0x420fe97c, 0x4b02e272, 0x5015ff60, 0x5918f46e, 0x663bc544, 0x6f36ce4a, 0x7421d358, 0x7d2cd856, 0xa10c7a37, 0xa8017139, 0xb3166c2b, 0xba1b6725, 0x8538560f, 0x8c355d01, 0x97224013, 0x9e2f4b1d, 0xe9642247, 0xe0692949, 0xfb7e345b, 0xf2733f55, 0xcd500e7f, 0xc45d0571, 0xdf4a1863, 0xd647136d, 0x31dccad7, 0x38d1c1d9, 0x23c6dccb, 0x2acbd7c5, 0x15e8e6ef, 0x1ce5ede1, 0x07f2f0f3, 0x0efffbfd, 0x79b492a7, 0x70b999a9, 0x6bae84bb, 0x62a38fb5, 0x5d80be9f, 0x548db591, 0x4f9aa883, 0x4697a38d ] def __init__(self, key): if len(key) not in (16, 24, 32): raise ValueError('Invalid key size') rounds = self.number_of_rounds[len(key)] # Encryption round keys self._Ke = [[0] * 4 for i in xrange(rounds + 1)] # Decryption round keys self._Kd = [[0] * 4 for i in xrange(rounds + 1)] round_key_count = (rounds + 1) * 4 KC = len(key) // 4 # Convert the key into ints tk = [ struct.unpack('>i', key[i:i + 4])[0] for i in xrange(0, len(key), 4) ] # Copy values into round key arrays for i in xrange(0, KC): self._Ke[i // 4][i % 4] = tk[i] self._Kd[rounds - (i // 4)][i % 4] = tk[i] # Key expansion (fips-197 section 5.2) rconpointer = 0 t = KC while t < round_key_count: tt = tk[KC - 1] tk[0] ^= ((self.S[(tt >> 16) & 0xFF] << 24) ^ (self.S[(tt >> 8) & 0xFF] << 16) ^ (self.S[ tt & 0xFF] << 8) ^ self.S[(tt >> 24) & 0xFF] ^ (self.rcon[rconpointer] << 24)) rconpointer += 1 if KC != 8: for i in xrange(1, KC): tk[i] ^= tk[i - 1] # Key expansion for 256-bit keys is "slightly different" (fips-197) else: for i in xrange(1, KC // 2): tk[i] ^= tk[i - 1] tt = tk[KC // 2 - 1] tk[KC // 2] ^= (self.S[ tt & 0xFF] ^ (self.S[(tt >> 8) & 0xFF] << 8) ^ (self.S[(tt >> 16) & 0xFF] << 16) ^ (self.S[(tt >> 24) & 0xFF] << 24)) for i in xrange(KC // 2 + 1, KC): tk[i] ^= tk[i - 1] # Copy values into round key arrays j = 0 while j < KC and t < round_key_count: self._Ke[t // 4][t % 4] = tk[j] self._Kd[rounds - (t // 4)][t % 4] = tk[j] j += 1 t += 1 # Inverse-Cipher-ify the decryption round key (fips-197 section 5.3) for r in xrange(1, rounds): for j in xrange(0, 4): tt = self._Kd[r][j] self._Kd[r][j] = (self.U1[(tt >> 24) & 0xFF] ^ self.U2[(tt >> 16) & 0xFF] ^ self.U3[(tt >> 8) & 0xFF] ^ self.U4[ tt & 0xFF]) def encrypt(self, plaintext): 'Encrypt a block of plain text using the AES block cipher.' if len(plaintext) != 16: raise ValueError('wrong block length') rounds = len(self._Ke) - 1 (s1, s2, s3) = [1, 2, 3] a = [0, 0, 0, 0] # Convert plaintext to (ints ^ key) t = [(_compact_word(plaintext[4 * i:4 * i + 4]) ^ self._Ke[0][i]) for i in xrange(0, 4)] # Apply round transforms for r in xrange(1, rounds): for i in xrange(0, 4): a[i] = (self.T1[(t[ i ] >> 24) & 0xFF] ^ self.T2[(t[(i + s1) % 4] >> 16) & 0xFF] ^ self.T3[(t[(i + s2) % 4] >> 8) & 0xFF] ^ self.T4[ t[(i + s3) % 4] & 0xFF] ^ self._Ke[r][i]) t = copy.copy(a) # The last round is special result = [ ] for i in xrange(0, 4): tt = self._Ke[rounds][i] result.append((self.S[(t[ i ] >> 24) & 0xFF] ^ (tt >> 24)) & 0xFF) result.append((self.S[(t[(i + s1) % 4] >> 16) & 0xFF] ^ (tt >> 16)) & 0xFF) result.append((self.S[(t[(i + s2) % 4] >> 8) & 0xFF] ^ (tt >> 8)) & 0xFF) result.append((self.S[ t[(i + s3) % 4] & 0xFF] ^ tt ) & 0xFF) return result def decrypt(self, ciphertext): 'Decrypt a block of cipher text using the AES block cipher.' if len(ciphertext) != 16: raise ValueError('wrong block length') rounds = len(self._Kd) - 1 (s1, s2, s3) = [3, 2, 1] a = [0, 0, 0, 0] # Convert ciphertext to (ints ^ key) t = [(_compact_word(ciphertext[4 * i:4 * i + 4]) ^ self._Kd[0][i]) for i in xrange(0, 4)] # Apply round transforms for r in xrange(1, rounds): for i in xrange(0, 4): a[i] = (self.T5[(t[ i ] >> 24) & 0xFF] ^ self.T6[(t[(i + s1) % 4] >> 16) & 0xFF] ^ self.T7[(t[(i + s2) % 4] >> 8) & 0xFF] ^ self.T8[ t[(i + s3) % 4] & 0xFF] ^ self._Kd[r][i]) t = copy.copy(a) # The last round is special result = [ ] for i in xrange(0, 4): tt = self._Kd[rounds][i] result.append((self.Si[(t[ i ] >> 24) & 0xFF] ^ (tt >> 24)) & 0xFF) result.append((self.Si[(t[(i + s1) % 4] >> 16) & 0xFF] ^ (tt >> 16)) & 0xFF) result.append((self.Si[(t[(i + s2) % 4] >> 8) & 0xFF] ^ (tt >> 8)) & 0xFF) result.append((self.Si[ t[(i + s3) % 4] & 0xFF] ^ tt ) & 0xFF) return result class Counter(object): '''A counter object for the Counter (CTR) mode of operation. To create a custom counter, you can usually just override the increment method.''' def __init__(self, initial_value = 1): # Convert the value into an array of bytes long self._counter = [ ((initial_value >> i) % 256) for i in xrange(128 - 8, -1, -8) ] value = property(lambda s: s._counter) def increment(self): '''Increment the counter (overflow rolls back to 0).''' for i in xrange(len(self._counter) - 1, -1, -1): self._counter[i] += 1 if self._counter[i] < 256: break # Carry the one self._counter[i] = 0 # Overflow else: self._counter = [ 0 ] * len(self._counter) class AESBlockModeOfOperation(object): '''Super-class for AES modes of operation that require blocks.''' def __init__(self, key): self._aes = AES(key) def decrypt(self, ciphertext): raise Exception('not implemented') def encrypt(self, plaintext): raise Exception('not implemented') class AESStreamModeOfOperation(AESBlockModeOfOperation): '''Super-class for AES modes of operation that are stream-ciphers.''' class AESSegmentModeOfOperation(AESStreamModeOfOperation): '''Super-class for AES modes of operation that segment data.''' segment_bytes = 16 class AESModeOfOperationECB(AESBlockModeOfOperation): '''AES Electronic Codebook Mode of Operation. o Block-cipher, so data must be padded to 16 byte boundaries Security Notes: o This mode is not recommended o Any two identical blocks produce identical encrypted values, exposing data patterns. (See the image of Tux on wikipedia) Also see: o https://en.wikipedia.org/wiki/Block_cipher_mode_of_operation#Electronic_codebook_.28ECB.29 o See NIST SP800-38A (http://csrc.nist.gov/publications/nistpubs/800-38a/sp800-38a.pdf); section 6.1''' name = "Electronic Codebook (ECB)" def encrypt(self, plaintext): if len(plaintext) != 16: raise ValueError('plaintext block must be 16 bytes') plaintext = _string_to_bytes(plaintext) return _bytes_to_string(self._aes.encrypt(plaintext)) def decrypt(self, ciphertext): if len(ciphertext) != 16: raise ValueError('ciphertext block must be 16 bytes') ciphertext = _string_to_bytes(ciphertext) return _bytes_to_string(self._aes.decrypt(ciphertext)) class AESModeOfOperationCBC(AESBlockModeOfOperation): '''AES Cipher-Block Chaining Mode of Operation. o The Initialization Vector (IV) o Block-cipher, so data must be padded to 16 byte boundaries o An incorrect initialization vector will only cause the first block to be corrupt; all other blocks will be intact o A corrupt bit in the cipher text will cause a block to be corrupted, and the next block to be inverted, but all other blocks will be intact. Security Notes: o This method (and CTR) ARE recommended. Also see: o https://en.wikipedia.org/wiki/Block_cipher_mode_of_operation#Cipher-block_chaining_.28CBC.29 o See NIST SP800-38A (http://csrc.nist.gov/publications/nistpubs/800-38a/sp800-38a.pdf); section 6.2''' name = "Cipher-Block Chaining (CBC)" def __init__(self, key, iv = None): if iv is None: self._last_cipherblock = [ 0 ] * 16 elif len(iv) != 16: raise ValueError('initialization vector must be 16 bytes') else: self._last_cipherblock = _string_to_bytes(iv) AESBlockModeOfOperation.__init__(self, key) def encrypt(self, plaintext): if len(plaintext) != 16: raise ValueError('plaintext block must be 16 bytes') plaintext = _string_to_bytes(plaintext) precipherblock = [ (p ^ l) for (p, l) in zip(plaintext, self._last_cipherblock) ] self._last_cipherblock = self._aes.encrypt(precipherblock) return _bytes_to_string(self._last_cipherblock) def decrypt(self, ciphertext): if len(ciphertext) != 16: raise ValueError('ciphertext block must be 16 bytes') cipherblock = _string_to_bytes(ciphertext) plaintext = [ (p ^ l) for (p, l) in zip(self._aes.decrypt(cipherblock), self._last_cipherblock) ] self._last_cipherblock = cipherblock return _bytes_to_string(plaintext) class AESModeOfOperationCFB(AESSegmentModeOfOperation): '''AES Cipher Feedback Mode of Operation. o A stream-cipher, so input does not need to be padded to blocks, but does need to be padded to segment_size Also see: o https://en.wikipedia.org/wiki/Block_cipher_mode_of_operation#Cipher_feedback_.28CFB.29 o See NIST SP800-38A (http://csrc.nist.gov/publications/nistpubs/800-38a/sp800-38a.pdf); section 6.3''' name = "Cipher Feedback (CFB)" def __init__(self, key, iv, segment_size = 1): if segment_size == 0: segment_size = 1 if iv is None: self._shift_register = [ 0 ] * 16 elif len(iv) != 16: raise ValueError('initialization vector must be 16 bytes') else: self._shift_register = _string_to_bytes(iv) self._segment_bytes = segment_size AESBlockModeOfOperation.__init__(self, key) segment_bytes = property(lambda s: s._segment_bytes) def encrypt(self, plaintext): #if len(plaintext) % self._segment_bytes != 0: # raise ValueError('plaintext block must be a multiple of segment_size') plaintext = _string_to_bytes(plaintext) # Break block into segments encrypted = [ ] for i in xrange(0, len(plaintext), self._segment_bytes): plaintext_segment = plaintext[i: i + self._segment_bytes] xor_segment = self._aes.encrypt(self._shift_register)[:len(plaintext_segment)] cipher_segment = [ (p ^ x) for (p, x) in zip(plaintext_segment, xor_segment) ] # Shift the top bits out and the ciphertext in self._shift_register = _concat_list(self._shift_register[len(cipher_segment):], cipher_segment) encrypted.extend(cipher_segment) return _bytes_to_string(encrypted) def decrypt(self, ciphertext): #if len(ciphertext) % self._segment_bytes != 0: # raise ValueError('ciphertext block must be a multiple of segment_size') ciphertext = _string_to_bytes(ciphertext) # Break block into segments decrypted = [ ] for i in xrange(0, len(ciphertext), self._segment_bytes): cipher_segment = ciphertext[i: i + self._segment_bytes] xor_segment = self._aes.encrypt(self._shift_register)[:len(cipher_segment)] plaintext_segment = [ (p ^ x) for (p, x) in zip(cipher_segment, xor_segment) ] # Shift the top bits out and the ciphertext in self._shift_register = _concat_list(self._shift_register[len(cipher_segment):], cipher_segment) decrypted.extend(plaintext_segment) return _bytes_to_string(decrypted) class AESModeOfOperationOFB(AESStreamModeOfOperation): '''AES Output Feedback Mode of Operation. o A stream-cipher, so input does not need to be padded to blocks, allowing arbitrary length data. o A bit twiddled in the cipher text, twiddles the same bit in the same bit in the plain text, which can be useful for error correction techniques. Also see: o https://en.wikipedia.org/wiki/Block_cipher_mode_of_operation#Output_feedback_.28OFB.29 o See NIST SP800-38A (http://csrc.nist.gov/publications/nistpubs/800-38a/sp800-38a.pdf); section 6.4''' name = "Output Feedback (OFB)" def __init__(self, key, iv = None): if iv is None: self._last_precipherblock = [ 0 ] * 16 elif len(iv) != 16: raise ValueError('initialization vector must be 16 bytes') else: self._last_precipherblock = _string_to_bytes(iv) self._remaining_block = [ ] AESBlockModeOfOperation.__init__(self, key) def encrypt(self, plaintext): encrypted = [ ] for p in _string_to_bytes(plaintext): if len(self._remaining_block) == 0: self._remaining_block = self._aes.encrypt(self._last_precipherblock) self._last_precipherblock = [ ] precipherbyte = self._remaining_block.pop(0) self._last_precipherblock.append(precipherbyte) cipherbyte = p ^ precipherbyte encrypted.append(cipherbyte) return _bytes_to_string(encrypted) def decrypt(self, ciphertext): # AES-OFB is symetric return self.encrypt(ciphertext) class AESModeOfOperationCTR(AESStreamModeOfOperation): '''AES Counter Mode of Operation. o A stream-cipher, so input does not need to be padded to blocks, allowing arbitrary length data. o The counter must be the same size as the key size (ie. len(key)) o Each block independant of the other, so a corrupt byte will not damage future blocks. o Each block has a uniue counter value associated with it, which contributes to the encrypted value, so no data patterns are leaked. o Also known as: Counter Mode (CM), Integer Counter Mode (ICM) and Segmented Integer Counter (SIC Security Notes: o This method (and CBC) ARE recommended. o Each message block is associated with a counter value which must be unique for ALL messages with the same key. Otherwise security may be compromised. Also see: o https://en.wikipedia.org/wiki/Block_cipher_mode_of_operation#Counter_.28CTR.29 o See NIST SP800-38A (http://csrc.nist.gov/publications/nistpubs/800-38a/sp800-38a.pdf); section 6.5 and Appendix B for managing the initial counter''' name = "Counter (CTR)" def __init__(self, key, counter = None): AESBlockModeOfOperation.__init__(self, key) if counter is None: counter = Counter() self._counter = counter self._remaining_counter = [ ] def encrypt(self, plaintext): while len(self._remaining_counter) < len(plaintext): self._remaining_counter += self._aes.encrypt(self._counter.value) self._counter.increment() plaintext = _string_to_bytes(plaintext) encrypted = [ (p ^ c) for (p, c) in zip(plaintext, self._remaining_counter) ] self._remaining_counter = self._remaining_counter[len(encrypted):] return _bytes_to_string(encrypted) def decrypt(self, crypttext): # AES-CTR is symetric return self.encrypt(crypttext) # Simple lookup table for each mode AESModesOfOperation = dict( ctr = AESModeOfOperationCTR, cbc = AESModeOfOperationCBC, cfb = AESModeOfOperationCFB, ecb = AESModeOfOperationECB, ofb = AESModeOfOperationOFB, ) unicrypto-0.0.10/unicrypto/backends/pure/external/AES/AESCCM.py000066400000000000000000000122711437177004600241600ustar00rootroot00000000000000#from Cryptodome.Cipher import AES import struct from hashlib import sha256 from .AES import AESModeOfOperationCTR, AESModeOfOperationCBC, Counter from .blockfeeder import Decrypter, Encrypter, PADDING_NONE def aesCCMEncrypt(plaintext, aad, key, nonce, macLen = 16): blockSize = 16 # For AES... if macLen not in (4, 6, 8, 10, 12, 14, 16): raise ValueError("Parameter 'mac_len' must be even and in the range 4..16 (not %d)" % macLen) if not (nonce and 7 <= len(nonce) <= 13): raise ValueError("Length of parameter 'nonce' must be in the range 7..13 bytes") # Encryption q = 15 - len(nonce) #cipher = AES.new(key=key, mode=AES.MODE_CTR, nonce=struct.pack("B", q - 1) + nonce) t_nonce = struct.pack("B", q - 1) + nonce t_noncepad = b'\x00'*(blockSize - (len(t_nonce) % blockSize)) t_nonce += t_noncepad #print(t_nonce.hex()) ctr_start = Counter(int.from_bytes(t_nonce, byteorder='big', signed=False)) cipher = AESModeOfOperationCTR(key, ctr_start) s0 = cipher.encrypt(b'\x00'*16) # For mac #print(f"My s0 {s0}") c = cipher.encrypt(plaintext) # Mac pLen = len(plaintext) aadLen = len(aad) #mac = AES.new(key=key, mode=AES.MODE_CBC, iv=b'\x00'*blockSize) mac = Encrypter(AESModeOfOperationCBC(key, iv=b'\x00'*blockSize), padding = PADDING_NONE) flags = (64 * (aadLen > 0) + 8 * ((macLen - 2) // 2) + (q - 1)) b0 = struct.pack("B", flags) + nonce + pLen.to_bytes(q, 'big') assocLenEncoded = b'' if aadLen > 0: if aadLen < (2 ** 16 - 2 ** 8): encSize = 2 elif aadLen < (2 ** 32): assocLenEncoded = b'\xFF\xFE' encSize = 4 else: assocLenEncoded = b'\xFF\xFF' encSize = 8 assocLenEncoded += aadLen.to_bytes(encSize, 'big') aadPadded = assocLenEncoded + aad #print(f"aad Format before pad: {len(aadPadded)}" ) aadPad = b'' if len(aadPadded) % blockSize != 0: #print("need to padd aad") aadPad = b'\x00'*(blockSize - (len(aadPadded) % blockSize)) aadPadded += aadPad ptxtPadded = plaintext #ptxt padding ptxtPad = b'' if (pLen % blockSize) != 0: #print("Should pad ptxt") ptxtPad = b'\x00'*(blockSize - (pLen % blockSize)) ptxtPadded += ptxtPad macData = b0 + aadPadded + ptxtPadded #print(f"MAC input {macData}") t = mac.feed(macData) t += mac.feed() t = t[-16:] tag = bytes([a ^ b for (a,b) in zip(t,s0)])[:macLen] return (c, tag) def aesCCMDecrypt(ciphertext, aad, key, nonce, macValue): # Decrytion: in CTR Encrypt == Decrypt blockSize = 16 # For AES... macLen = len(macValue) if macLen not in (4, 6, 8, 10, 12, 14, 16): raise ValueError("Parameter 'mac_len' must be even and in the range 4..16 (not %d)" % macLen) if not (nonce and 7 <= len(nonce) <= 13): raise ValueError("Length of parameter 'nonce' must be in the range 7..13 bytes") # Decryption q = 15 - len(nonce) #cipher = AES.new(key=key, mode=AES.MODE_CTR, nonce=struct.pack("B", q - 1) + nonce) t_nonce = struct.pack("B", q - 1) + nonce t_noncepad = b'\x00'*(blockSize - (len(t_nonce) % blockSize)) t_nonce += t_noncepad #print(t_nonce.hex()) ctr_start = Counter(int.from_bytes(t_nonce, byteorder='big', signed=False)) cipher = AESModeOfOperationCTR(key, ctr_start) s0 = cipher.encrypt(b'\x00'*16) # For mac #print(f"My s0 {s0}") plaintext = cipher.encrypt(ciphertext) #print(f"recoverd plaintex {plaintext}") # Mac pLen = len(plaintext) aadLen = len(aad) #mac = AES.new(key=key, mode=AES.MODE_CBC, iv=b'\x00'*blockSize) mac = Encrypter(AESModeOfOperationCBC(key, iv=b'\x00'*blockSize), padding = PADDING_NONE) flags = (64 * (aadLen > 0) + 8 * ((macLen - 2) // 2) + (q - 1)) b0 = struct.pack("B", flags) + nonce + pLen.to_bytes(q, 'big') assocLenEncoded = b'' if aadLen > 0: if aadLen < (2 ** 16 - 2 ** 8): encSize = 2 elif aadLen < (2 ** 32): assocLenEncoded = b'\xFF\xFE' encSize = 4 else: assocLenEncoded = b'\xFF\xFF' encSize = 8 assocLenEncoded += aadLen.to_bytes(encSize, 'big') aadPadded = assocLenEncoded + aad #print(f"aad Format before pad: {len(aadPadded)}" ) aadPad = b'' if len(aadPadded) % blockSize != 0: #print("need to padd aad") aadPad = b'\x00'*(blockSize - (len(aadPadded) % blockSize)) aadPadded += aadPad ptxtPadded = plaintext #ptxt padding ptxtPad = b'' if pLen % blockSize != 0: #print("Should pad ptxt") ptxtPad = b'\x00'*(blockSize - (pLen % blockSize)) ptxtPadded += ptxtPad macData = b0 + aadPadded + ptxtPadded #t = mac.encrypt(macData)[-16:] t = mac.feed(macData) t += mac.feed() t = t[-16:] tag = bytes([a ^ b for (a,b) in zip(t,s0)])[:macLen] return plaintext ## Attempt to secure comparison... Idea: hash expected and received macs and compare the result in constant time... ## Ideally should be done with HMAC with a RANDOM KEY! Doesn't cost much on a performance level. ## For now we use shake_128(SHA3 without a key) print(f"received mac {macValue} \nComputed {tag}") h1 = sha256() h1.update(tag) digest1 = h1.digest() h2 = sha256() h2.update(macValue) digest2 = h2.digest() # Constant time comparison of hashes. Probably overkill here because of the randomization introduced by HMAC.. result = 0 for x, y in zip(digest1, digest2): result |= x ^ y #print(f"Reuslt {result}") if result != 0: raise ValueError("Incorrect MAC") else: return plaintext unicrypto-0.0.10/unicrypto/backends/pure/external/AES/AESGCM.py000066400000000000000000000147401437177004600241670ustar00rootroot00000000000000#!/usr/bin/env python """ Copyright (C) 2013 Bo Zhu http://about.bozhu.me Permission is hereby granted, free of charge, to any person obtaining a copy of this software and associated documentation files (the "Software"), to deal in the Software without restriction, including without limitation the rights to use, copy, modify, merge, publish, distribute, sublicense, and/or sell copies of the Software, and to permit persons to whom the Software is furnished to do so, subject to the following conditions: The above copyright notice and this permission notice shall be included in all copies or substantial portions of the Software. THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY, FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE SOFTWARE. SkelSec Note: the original code has been modified to work using questionable crypto libraries by myself who is not a cryptographer. I'd say "use it with suspicion" but in truth: just do not use this at all outside of this library. """ from unicrypto.backends.pure.external.AES import AESModeOfOperationCTR, AESModeOfOperationECB, Counter def int_to_bytes(x: int, blocksize = 0) -> bytes: if blocksize == 0: return x.to_bytes((x.bit_length() + 7) // 8, 'big') else: return x.to_bytes(blocksize, 'big') # GF(2^128) defined by 1 + a + a^2 + a^7 + a^128 # Please note the MSB is x0 and LSB is x127 def gf_2_128_mul(x, y): assert x < (1 << 128) assert y < (1 << 128) res = 0 for i in range(127, -1, -1): res ^= x * ((y >> i) & 1) # branchless x = (x >> 1) ^ ((x & 1) * 0xE1000000000000000000000000000000) assert res < 1 << 128 return res class InvalidInputException(Exception): def __init__(self, msg): self.msg = msg def __str__(self): return str(self.msg) class InvalidTagException(Exception): def __str__(self): return 'The authenticaiton tag is invalid.' # Galois/Counter Mode with AES-128 and 96-bit IV class AES_GCM: def __init__(self, master_key): self.change_key(master_key) def change_key(self, master_key): #if len(master_key) != 16: # raise InvalidInputException('Master key should be 128-bit') self.__master_key = master_key self.__aes_ecb = AESModeOfOperationECB(self.__master_key) self.__auth_key = self.__aes_ecb.encrypt(b'\x00' * 16) self.__auth_key_int = int.from_bytes(self.__auth_key, byteorder='big', signed=False) # precompute the table for multiplication in finite field table = [] # for 8-bit for i in range(16): row = [] for j in range(256): row.append(gf_2_128_mul(self.__auth_key_int, j << (8 * i))) table.append(tuple(row)) self.__pre_table = tuple(table) self.prev_init_value = None # reset def __times_auth_key(self, val): res = 0 for i in range(16): res ^= self.__pre_table[i][val & 0xFF] val >>= 8 return res def __ghash(self, aad, txt): len_aad = len(aad) len_txt = len(txt) # padding if 0 == len_aad % 16: data = aad else: data = aad + b'\x00' * (16 - len_aad % 16) if 0 == len_txt % 16: data += txt else: data += txt + b'\x00' * (16 - len_txt % 16) tag = 0 assert len(data) % 16 == 0 for i in range(len(data) // 16): tag ^= int.from_bytes(data[i * 16: (i + 1) * 16], byteorder='big', signed=False) tag = self.__times_auth_key(tag) tag ^= ((8 * len_aad) << 64) | (8 * len_txt) tag = self.__times_auth_key(tag) return tag def encrypt(self, init_value, plaintext, auth_data=b''): #if len(init_value) != 12: # raise InvalidInputException('IV should be 96-bit') # a naive checking for IV reuse len_plaintext = len(plaintext) if len_plaintext > 0: if len(init_value) == 12: ctrval_init = init_value + b'\x00\x00\x00\x02' # ends with 2!!! ctrval = int.from_bytes(ctrval_init, byteorder='big', signed=False) iv_int = int.from_bytes(init_value, byteorder='big', signed=False) iv_int = (iv_int << 32) | 1 iv_int = iv_int.to_bytes(16, byteorder='big', signed=False) else: ctrval = self.__ghash(b'', init_value) iv_int = ctrval.to_bytes(16, byteorder='big', signed=False) ctrval += 1 counter = Counter(initial_value=ctrval) aes_ctr = AESModeOfOperationCTR(self.__master_key, counter=counter) if 0 != len_plaintext % 16: padded_plaintext = plaintext + \ b'\x00' * (16 - len_plaintext % 16) else: padded_plaintext = plaintext ciphertext = aes_ctr.encrypt(padded_plaintext)[:len_plaintext] else: ciphertext = b'' iv_int = int.from_bytes(init_value, byteorder='big', signed=False) iv_int = (iv_int << 32) | 1 iv_int = iv_int.to_bytes(16, byteorder='big', signed=False) auth_tag = self.__ghash(auth_data, ciphertext) iv_int_enc = self.__aes_ecb.encrypt(iv_int) iv_int_enc = int.from_bytes(iv_int_enc, byteorder='big', signed=False) auth_tag ^= iv_int_enc assert auth_tag < (1 << 128) return ciphertext, auth_tag.to_bytes(16, byteorder='big', signed=False) def decrypt(self, init_value, ciphertext, auth_tag, auth_data=b''): if len(auth_tag) != 16: raise InvalidInputException('Tag should be 128-bit') if len(init_value) == 12: iv_int = int.from_bytes(init_value, byteorder='big', signed=False) iv_int = (iv_int << 32) | 1 iv_int = iv_int.to_bytes(16, byteorder='big', signed=False) ctrval_init = init_value + b'\x00\x00\x00\x02' # ends with 2!!! ctrval = int.from_bytes(ctrval_init, byteorder='big', signed=False) else: ctrval = self.__ghash(b'', init_value) iv_int = int_to_bytes(ctrval, 16) ctrval += 1 iv_int_enc = self.__aes_ecb.encrypt(iv_int) iv_int_enc = int.from_bytes(iv_int_enc, byteorder='big', signed=False) auth_tag_verify = self.__ghash(auth_data, ciphertext) ^ iv_int_enc auth_tag_verify = auth_tag_verify.to_bytes(16, byteorder='big', signed=False) if auth_tag != auth_tag_verify: raise InvalidTagException len_ciphertext = len(ciphertext) if len_ciphertext > 0: counter = Counter(initial_value=ctrval) aes_ctr = AESModeOfOperationCTR(self.__master_key, counter=counter) if 0 != len_ciphertext % 16: padded_ciphertext = ciphertext + \ b'\x00' * (16 - len_ciphertext % 16) else: padded_ciphertext = ciphertext plaintext = aes_ctr.decrypt(padded_ciphertext)[:len_ciphertext] else: plaintext = b'' return plaintextunicrypto-0.0.10/unicrypto/backends/pure/external/AES/__init__.py000066400000000000000000000041601437177004600247620ustar00rootroot00000000000000#https://raw.githubusercontent.com/ricmoo/pyaes/master/pyaes/__init__.py # The MIT License (MIT) # # Copyright (c) 2014 Richard Moore # # Permission is hereby granted, free of charge, to any person obtaining a copy # of this software and associated documentation files (the "Software"), to deal # in the Software without restriction, including without limitation the rights # to use, copy, modify, merge, publish, distribute, sublicense, and/or sell # copies of the Software, and to permit persons to whom the Software is # furnished to do so, subject to the following conditions: # # The above copyright notice and this permission notice shall be included in # all copies or substantial portions of the Software. # # THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR # IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY, # FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE # AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER # LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, # OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN # THE SOFTWARE. # This is a pure-Python implementation of the AES algorithm and AES common # modes of operation. # See: https://en.wikipedia.org/wiki/Advanced_Encryption_Standard # See: https://en.wikipedia.org/wiki/Block_cipher_mode_of_operation # Supported key sizes: # 128-bit # 192-bit # 256-bit # Supported modes of operation: # ECB - Electronic Codebook # CBC - Cipher-Block Chaining # CFB - Cipher Feedback # OFB - Output Feedback # CTR - Counter # See the README.md for API details and general information. # Also useful, PyCrypto, a crypto library implemented in C with Python bindings: # https://www.dlitz.net/software/pycrypto/ VERSION = [1, 3, 0] from .AES import AES, AESModeOfOperationCTR, AESModeOfOperationCBC, AESModeOfOperationCFB, AESModeOfOperationECB, AESModeOfOperationOFB, AESModesOfOperation, Counter from .blockfeeder import decrypt_stream, Decrypter, encrypt_stream, Encrypter from .blockfeeder import PADDING_NONE, PADDING_DEFAULT unicrypto-0.0.10/unicrypto/backends/pure/external/AES/blockfeeder.py000066400000000000000000000177761437177004600255110ustar00rootroot00000000000000 #https://github.com/ricmoo/pyaes/blob/master/pyaes/blockfeeder.py # The MIT License (MIT) # # Copyright (c) 2014 Richard Moore # # Permission is hereby granted, free of charge, to any person obtaining a copy # of this software and associated documentation files (the "Software"), to deal # in the Software without restriction, including without limitation the rights # to use, copy, modify, merge, publish, distribute, sublicense, and/or sell # copies of the Software, and to permit persons to whom the Software is # furnished to do so, subject to the following conditions: # # The above copyright notice and this permission notice shall be included in # all copies or substantial portions of the Software. # # THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR # IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY, # FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE # AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER # LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, # OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN # THE SOFTWARE. from .AES import AESBlockModeOfOperation, AESSegmentModeOfOperation, AESStreamModeOfOperation from .util import append_PKCS7_padding, strip_PKCS7_padding, to_bufferable # First we inject three functions to each of the modes of operations # # _can_consume(size) # - Given a size, determine how many bytes could be consumed in # a single call to either the decrypt or encrypt method # # _final_encrypt(data, padding = PADDING_DEFAULT) # - call and return encrypt on this (last) chunk of data, # padding as necessary; this will always be at least 16 # bytes unless the total incoming input was less than 16 # bytes # # _final_decrypt(data, padding = PADDING_DEFAULT) # - same as _final_encrypt except for decrypt, for # stripping off padding # PADDING_NONE = 'none' PADDING_DEFAULT = 'default' # @TODO: Ciphertext stealing and explicit PKCS#7 # PADDING_CIPHERTEXT_STEALING # PADDING_PKCS7 # ECB and CBC are block-only ciphers def _block_can_consume(self, size): if size >= 16: return 16 return 0 # After padding, we may have more than one block def _block_final_encrypt(self, data, padding = PADDING_DEFAULT): if padding == PADDING_DEFAULT: data = append_PKCS7_padding(data) elif padding == PADDING_NONE: if len(data) != 16: raise Exception('invalid data length for final block') else: raise Exception('invalid padding option') if len(data) == 32: return self.encrypt(data[:16]) + self.encrypt(data[16:]) return self.encrypt(data) def _block_final_decrypt(self, data, padding = PADDING_DEFAULT): if padding == PADDING_DEFAULT: return strip_PKCS7_padding(self.decrypt(data)) if padding == PADDING_NONE: if len(data) != 16: raise Exception('invalid data length for final block') return self.decrypt(data) raise Exception('invalid padding option') AESBlockModeOfOperation._can_consume = _block_can_consume AESBlockModeOfOperation._final_encrypt = _block_final_encrypt AESBlockModeOfOperation._final_decrypt = _block_final_decrypt # CFB is a segment cipher def _segment_can_consume(self, size): return self.segment_bytes * int(size // self.segment_bytes) # CFB can handle a non-segment-sized block at the end using the remaining cipherblock def _segment_final_encrypt(self, data, padding = PADDING_DEFAULT): if padding != PADDING_DEFAULT: raise Exception('invalid padding option') faux_padding = (chr(0) * (self.segment_bytes - (len(data) % self.segment_bytes))) padded = data + to_bufferable(faux_padding) return self.encrypt(padded)[:len(data)] # CFB can handle a non-segment-sized block at the end using the remaining cipherblock def _segment_final_decrypt(self, data, padding = PADDING_DEFAULT): if padding != PADDING_DEFAULT: raise Exception('invalid padding option') faux_padding = (chr(0) * (self.segment_bytes - (len(data) % self.segment_bytes))) padded = data + to_bufferable(faux_padding) return self.decrypt(padded)[:len(data)] AESSegmentModeOfOperation._can_consume = _segment_can_consume AESSegmentModeOfOperation._final_encrypt = _segment_final_encrypt AESSegmentModeOfOperation._final_decrypt = _segment_final_decrypt # OFB and CTR are stream ciphers def _stream_can_consume(self, size): return size def _stream_final_encrypt(self, data, padding = PADDING_DEFAULT): if padding not in [PADDING_NONE, PADDING_DEFAULT]: raise Exception('invalid padding option') return self.encrypt(data) def _stream_final_decrypt(self, data, padding = PADDING_DEFAULT): if padding not in [PADDING_NONE, PADDING_DEFAULT]: raise Exception('invalid padding option') return self.decrypt(data) AESStreamModeOfOperation._can_consume = _stream_can_consume AESStreamModeOfOperation._final_encrypt = _stream_final_encrypt AESStreamModeOfOperation._final_decrypt = _stream_final_decrypt class BlockFeeder(object): '''The super-class for objects to handle chunking a stream of bytes into the appropriate block size for the underlying mode of operation and applying (or stripping) padding, as necessary.''' def __init__(self, mode, feed, final, padding = PADDING_DEFAULT): self._mode = mode self._feed = feed self._final = final self._buffer = to_bufferable("") self._padding = padding def feed(self, data = None): '''Provide bytes to encrypt (or decrypt), returning any bytes possible from this or any previous calls to feed. Call with None or an empty string to flush the mode of operation and return any final bytes; no further calls to feed may be made.''' if self._buffer is None: raise ValueError('already finished feeder') # Finalize; process the spare bytes we were keeping if data is None: result = self._final(self._buffer, self._padding) self._buffer = None return result self._buffer += to_bufferable(data) # We keep 16 bytes around so we can determine padding result = to_bufferable('') while len(self._buffer) > 16: can_consume = self._mode._can_consume(len(self._buffer) - 16) if can_consume == 0: break result += self._feed(self._buffer[:can_consume]) self._buffer = self._buffer[can_consume:] return result class Encrypter(BlockFeeder): 'Accepts bytes of plaintext and returns encrypted ciphertext.' def __init__(self, mode, padding = PADDING_DEFAULT): BlockFeeder.__init__(self, mode, mode.encrypt, mode._final_encrypt, padding) class Decrypter(BlockFeeder): 'Accepts bytes of ciphertext and returns decrypted plaintext.' def __init__(self, mode, padding = PADDING_DEFAULT): BlockFeeder.__init__(self, mode, mode.decrypt, mode._final_decrypt, padding) # 8kb blocks BLOCK_SIZE = (1 << 13) def _feed_stream(feeder, in_stream, out_stream, block_size = BLOCK_SIZE): 'Uses feeder to read and convert from in_stream and write to out_stream.' while True: chunk = in_stream.read(block_size) if not chunk: break converted = feeder.feed(chunk) out_stream.write(converted) converted = feeder.feed() out_stream.write(converted) def encrypt_stream(mode, in_stream, out_stream, block_size = BLOCK_SIZE, padding = PADDING_DEFAULT): 'Encrypts a stream of bytes from in_stream to out_stream using mode.' encrypter = Encrypter(mode, padding = padding) _feed_stream(encrypter, in_stream, out_stream, block_size) def decrypt_stream(mode, in_stream, out_stream, block_size = BLOCK_SIZE, padding = PADDING_DEFAULT): 'Decrypts a stream of bytes from in_stream to out_stream using mode.' decrypter = Decrypter(mode, padding = padding) _feed_stream(decrypter, in_stream, out_stream, block_size) unicrypto-0.0.10/unicrypto/backends/pure/external/AES/ccm.py000066400000000000000000000040241437177004600237640ustar00rootroot00000000000000from Cryptodome.Cipher import AES import struct # https://tools.ietf.org/html/rfc3610 def aesCCMEncrypt(plaintext, aad, key, nonce, macLen): blockSize = 16 # For AES... if macLen not in (4, 6, 8, 10, 12, 14, 16): raise ValueError("Parameter 'mac_len' must be even and in the range 4..16 (not %d)" % macLen) if not (nonce and 7 <= len(nonce) <= 13): raise ValueError("Length of parameter 'nonce' must be in the range 7..13 bytes") # Encryption q = 15 - len(nonce) cipher = AES.new(key=key, mode=AES.MODE_CTR, nonce=struct.pack("B", q - 1) + nonce) s0 = cipher.encrypt(b'\x00'*16) # For mac c = cipher.encrypt(plaintext) # Mac pLen = len(plaintext) aadLen = len(aad) mac = AES.new(key=key, mode=AES.MODE_CBC, iv=b'\x00'*blockSize) flags = (64 * (aadLen > 0) + 8 * ((macLen - 2) // 2) + (q - 1)) b0 = struct.pack("B", flags) + nonce + pLen.to_bytes(q, 'big') assocLenEncoded = b'' if aadLen > 0: if aadLen < (2 ** 16 - 2 ** 8): encsize = 2 elif aadLen < (2 ** 32): assocLenEncoded = b'\xFF\xFE' encsize = 4 else: assocLenEncoded = b'\xFF\xFF' encsize = 8 assocLenEncoded += aadLen.to_bytes(encsize, 'big') print(f"Length of block 0: {len(b0)}" ) aadPadded = assocLenEncoded + aad aadPadded += b'\x00'*(blockSize - (len(aadPadded) % blockSize)) ptxtPadded = plaintext + b'\x00'*(blockSize - (pLen % blockSize)) macData = b0 + aadPadded + ptxtPadded print(f"Length of MAC input {len(macData)}") t = mac.encrypt(macData)[-16:] tag = bytes([a ^ b for (a,b) in zip(t,s0)]) return (c, tag) if __name__ == '__main__': import os EncryptionKey = b'\xff'*16 nonce = os.urandom(11) hdr = b'\xFF'* 40 msg_data = b'\xAA' * 1024 cipher = AES.new(EncryptionKey, AES.MODE_CCM, nonce) cipher.update(hdr) enc_data = cipher.encrypt(msg_data) sig = cipher.digest() print(enc_data.hex()) print(sig.hex()) c, t = aesCCMEncrypt(msg_data, hdr, EncryptionKey, nonce, 16) print('other') print(c.hex()) print(t.hex()) if c == enc_data: print('Encryption OK!') else: print('Encryption fail') unicrypto-0.0.10/unicrypto/backends/pure/external/AES/gcc_bak_orig.py000066400000000000000000000122711437177004600256160ustar00rootroot00000000000000#from Cryptodome.Cipher import AES import struct from hashlib import sha256 from .AES import AESModeOfOperationCTR, AESModeOfOperationCBC, Counter from .blockfeeder import Decrypter, Encrypter, PADDING_NONE def aesCCMEncrypt(plaintext, aad, key, nonce, macLen = 16): blockSize = 16 # For AES... if macLen not in (4, 6, 8, 10, 12, 14, 16): raise ValueError("Parameter 'mac_len' must be even and in the range 4..16 (not %d)" % macLen) if not (nonce and 7 <= len(nonce) <= 13): raise ValueError("Length of parameter 'nonce' must be in the range 7..13 bytes") # Encryption q = 15 - len(nonce) #cipher = AES.new(key=key, mode=AES.MODE_CTR, nonce=struct.pack("B", q - 1) + nonce) t_nonce = struct.pack("B", q - 1) + nonce t_noncepad = b'\x00'*(blockSize - (len(t_nonce) % blockSize)) t_nonce += t_noncepad #print(t_nonce.hex()) ctr_start = Counter(int.from_bytes(t_nonce, byteorder='big', signed=False)) cipher = AESModeOfOperationCTR(key, ctr_start) s0 = cipher.encrypt(b'\x00'*16) # For mac #print(f"My s0 {s0}") c = cipher.encrypt(plaintext) # Mac pLen = len(plaintext) aadLen = len(aad) #mac = AES.new(key=key, mode=AES.MODE_CBC, iv=b'\x00'*blockSize) mac = Encrypter(AESModeOfOperationCBC(key, iv=b'\x00'*blockSize), padding = PADDING_NONE) flags = (64 * (aadLen > 0) + 8 * ((macLen - 2) // 2) + (q - 1)) b0 = struct.pack("B", flags) + nonce + pLen.to_bytes(q, 'big') assocLenEncoded = b'' if aadLen > 0: if aadLen < (2 ** 16 - 2 ** 8): encSize = 2 elif aadLen < (2 ** 32): assocLenEncoded = b'\xFF\xFE' encSize = 4 else: assocLenEncoded = b'\xFF\xFF' encSize = 8 assocLenEncoded += aadLen.to_bytes(encSize, 'big') aadPadded = assocLenEncoded + aad #print(f"aad Format before pad: {len(aadPadded)}" ) aadPad = b'' if len(aadPadded) % blockSize != 0: #print("need to padd aad") aadPad = b'\x00'*(blockSize - (len(aadPadded) % blockSize)) aadPadded += aadPad ptxtPadded = plaintext #ptxt padding ptxtPad = b'' if (pLen % blockSize) != 0: #print("Should pad ptxt") ptxtPad = b'\x00'*(blockSize - (pLen % blockSize)) ptxtPadded += ptxtPad macData = b0 + aadPadded + ptxtPadded #print(f"MAC input {macData}") t = mac.feed(macData) t += mac.feed() t = t[-16:] tag = bytes([a ^ b for (a,b) in zip(t,s0)])[:macLen] return (c, tag) def aesCCMDecrypt(ciphertext, aad, key, nonce, macValue): # Decrytion: in CTR Encrypt == Decrypt blockSize = 16 # For AES... macLen = len(macValue) if macLen not in (4, 6, 8, 10, 12, 14, 16): raise ValueError("Parameter 'mac_len' must be even and in the range 4..16 (not %d)" % macLen) if not (nonce and 7 <= len(nonce) <= 13): raise ValueError("Length of parameter 'nonce' must be in the range 7..13 bytes") # Decryption q = 15 - len(nonce) #cipher = AES.new(key=key, mode=AES.MODE_CTR, nonce=struct.pack("B", q - 1) + nonce) t_nonce = struct.pack("B", q - 1) + nonce t_noncepad = b'\x00'*(blockSize - (len(t_nonce) % blockSize)) t_nonce += t_noncepad #print(t_nonce.hex()) ctr_start = Counter(int.from_bytes(t_nonce, byteorder='big', signed=False)) cipher = AESModeOfOperationCTR(key, ctr_start) s0 = cipher.encrypt(b'\x00'*16) # For mac #print(f"My s0 {s0}") plaintext = cipher.encrypt(ciphertext) #print(f"recoverd plaintex {plaintext}") # Mac pLen = len(plaintext) aadLen = len(aad) #mac = AES.new(key=key, mode=AES.MODE_CBC, iv=b'\x00'*blockSize) mac = Encrypter(AESModeOfOperationCBC(key, iv=b'\x00'*blockSize), padding = PADDING_NONE) flags = (64 * (aadLen > 0) + 8 * ((macLen - 2) // 2) + (q - 1)) b0 = struct.pack("B", flags) + nonce + pLen.to_bytes(q, 'big') assocLenEncoded = b'' if aadLen > 0: if aadLen < (2 ** 16 - 2 ** 8): encSize = 2 elif aadLen < (2 ** 32): assocLenEncoded = b'\xFF\xFE' encSize = 4 else: assocLenEncoded = b'\xFF\xFF' encSize = 8 assocLenEncoded += aadLen.to_bytes(encSize, 'big') aadPadded = assocLenEncoded + aad #print(f"aad Format before pad: {len(aadPadded)}" ) aadPad = b'' if len(aadPadded) % blockSize != 0: #print("need to padd aad") aadPad = b'\x00'*(blockSize - (len(aadPadded) % blockSize)) aadPadded += aadPad ptxtPadded = plaintext #ptxt padding ptxtPad = b'' if pLen % blockSize != 0: #print("Should pad ptxt") ptxtPad = b'\x00'*(blockSize - (pLen % blockSize)) ptxtPadded += ptxtPad macData = b0 + aadPadded + ptxtPadded #t = mac.encrypt(macData)[-16:] t = mac.feed(macData) t += mac.feed() t = t[-16:] tag = bytes([a ^ b for (a,b) in zip(t,s0)])[:macLen] return plaintext ## Attempt to secure comparison... Idea: hash expected and received macs and compare the result in constant time... ## Ideally should be done with HMAC with a RANDOM KEY! Doesn't cost much on a performance level. ## For now we use shake_128(SHA3 without a key) print(f"received mac {macValue} \nComputed {tag}") h1 = sha256() h1.update(tag) digest1 = h1.digest() h2 = sha256() h2.update(macValue) digest2 = h2.digest() # Constant time comparison of hashes. Probably overkill here because of the randomization introduced by HMAC.. result = 0 for x, y in zip(digest1, digest2): result |= x ^ y #print(f"Reuslt {result}") if result != 0: raise ValueError("Incorrect MAC") else: return plaintext unicrypto-0.0.10/unicrypto/backends/pure/external/AES/util.py000066400000000000000000000040761437177004600242060ustar00rootroot00000000000000 #https://github.com/ricmoo/pyaes/blob/master/pyaes/util.py # The MIT License (MIT) # # Copyright (c) 2014 Richard Moore # # Permission is hereby granted, free of charge, to any person obtaining a copy # of this software and associated documentation files (the "Software"), to deal # in the Software without restriction, including without limitation the rights # to use, copy, modify, merge, publish, distribute, sublicense, and/or sell # copies of the Software, and to permit persons to whom the Software is # furnished to do so, subject to the following conditions: # # The above copyright notice and this permission notice shall be included in # all copies or substantial portions of the Software. # # THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR # IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY, # FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE # AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER # LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, # OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN # THE SOFTWARE. # Why to_bufferable? # Python 3 is very different from Python 2.x when it comes to strings of text # and strings of bytes; in Python 3, strings of bytes do not exist, instead to # represent arbitrary binary data, we must use the "bytes" object. This method # ensures the object behaves as we need it to. def to_bufferable(binary): return binary def _get_byte(c): return ord(c) try: xrange except: def to_bufferable(binary): if isinstance(binary, bytes): return binary return bytes(ord(b) for b in binary) def _get_byte(c): return c def append_PKCS7_padding(data): pad = 16 - (len(data) % 16) return data + to_bufferable(chr(pad) * pad) def strip_PKCS7_padding(data): if len(data) % 16 != 0: raise ValueError("invalid length") pad = _get_byte(data[-1]) if pad > 16: raise ValueError("invalid padding byte") return data[:-pad] unicrypto-0.0.10/unicrypto/backends/pure/external/DES/000077500000000000000000000000001437177004600226535ustar00rootroot00000000000000unicrypto-0.0.10/unicrypto/backends/pure/external/DES/DES.py000066400000000000000000000655351437177004600236560ustar00rootroot00000000000000############################################################################# # Documentation # ############################################################################# # Author: Todd Whiteman # Date: 28th April, 2010 # Version: 2.0.1 # License: MIT # Homepage: http://twhiteman.netfirms.com/des.html # # This is a pure python implementation of the DES encryption algorithm. # It's pure python to avoid portability issues, since most DES # implementations are programmed in C (for performance reasons). # # Triple DES class is also implemented, utilizing the DES base. Triple DES # is either DES-EDE3 with a 24 byte key, or DES-EDE2 with a 16 byte key. # # See the README.txt that should come with this python module for the # implementation methods used. # # Thanks to: # * David Broadwell for ideas, comments and suggestions. # * Mario Wolff for pointing out and debugging some triple des CBC errors. # * Santiago Palladino for providing the PKCS5 padding technique. # * Shaya for correcting the PAD_PKCS5 triple des CBC errors. # """A pure python implementation of the DES and TRIPLE DES encryption algorithms. Class initialization -------------------- pyDes.des(key, [mode], [IV], [pad], [padmode]) pyDes.triple_des(key, [mode], [IV], [pad], [padmode]) key -> Bytes containing the encryption key. 8 bytes for DES, 16 or 24 bytes for Triple DES mode -> Optional argument for encryption type, can be either pyDes.ECB (Electronic Code Book) or pyDes.CBC (Cypher Block Chaining) IV -> Optional Initial Value bytes, must be supplied if using CBC mode. Length must be 8 bytes. pad -> Optional argument, set the pad character (PAD_NORMAL) to use during all encrypt/decrypt operations done with this instance. padmode -> Optional argument, set the padding mode (PAD_NORMAL or PAD_PKCS5) to use during all encrypt/decrypt operations done with this instance. I recommend to use PAD_PKCS5 padding, as then you never need to worry about any padding issues, as the padding can be removed unambiguously upon decrypting data that was encrypted using PAD_PKCS5 padmode. Common methods -------------- encrypt(data, [pad], [padmode]) decrypt(data, [pad], [padmode]) data -> Bytes to be encrypted/decrypted pad -> Optional argument. Only when using padmode of PAD_NORMAL. For encryption, adds this characters to the end of the data block when data is not a multiple of 8 bytes. For decryption, will remove the trailing characters that match this pad character from the last 8 bytes of the unencrypted data block. padmode -> Optional argument, set the padding mode, must be one of PAD_NORMAL or PAD_PKCS5). Defaults to PAD_NORMAL. Example ------- from pyDes import * data = "Please encrypt my data" k = des("DESCRYPT", CBC, "\0\0\0\0\0\0\0\0", pad=None, padmode=PAD_PKCS5) # For Python3, you'll need to use bytes, i.e.: # data = b"Please encrypt my data" # k = des(b"DESCRYPT", CBC, b"\0\0\0\0\0\0\0\0", pad=None, padmode=PAD_PKCS5) d = k.encrypt(data) print "Encrypted: %r" % d print "Decrypted: %r" % k.decrypt(d) assert k.decrypt(d, padmode=PAD_PKCS5) == data See the module source (pyDes.py) for more examples of use. You can also run the pyDes.py file without and arguments to see a simple test. Note: This code was not written for high-end systems needing a fast implementation, but rather a handy portable solution with small usage. """ import sys # _pythonMajorVersion is used to handle Python2 and Python3 differences. _pythonMajorVersion = sys.version_info[0] # Modes of crypting / cyphering ECB = 0 CBC = 1 # Modes of padding PAD_NORMAL = 1 PAD_PKCS5 = 2 # PAD_PKCS5: is a method that will unambiguously remove all padding # characters after decryption, when originally encrypted with # this padding mode. # For a good description of the PKCS5 padding technique, see: # http://www.faqs.org/rfcs/rfc1423.html # The base class shared by des and triple des. class _baseDes(object): def __init__(self, mode=ECB, IV=None, pad=None, padmode=PAD_NORMAL): if IV: IV = self._guardAgainstUnicode(IV) if pad: pad = self._guardAgainstUnicode(pad) self.block_size = 8 # Sanity checking of arguments. if pad and padmode == PAD_PKCS5: raise ValueError("Cannot use a pad character with PAD_PKCS5") if IV and len(IV) != self.block_size: raise ValueError("Invalid Initial Value (IV), must be a multiple of " + str(self.block_size) + " bytes") # Set the passed in variables self._mode = mode self._iv = IV self._padding = pad self._padmode = padmode def getKey(self): """getKey() -> bytes""" return self.__key def setKey(self, key): """Will set the crypting key for this object.""" key = self._guardAgainstUnicode(key) self.__key = key def getMode(self): """getMode() -> pyDes.ECB or pyDes.CBC""" return self._mode def setMode(self, mode): """Sets the type of crypting mode, pyDes.ECB or pyDes.CBC""" self._mode = mode def getPadding(self): """getPadding() -> bytes of length 1. Padding character.""" return self._padding def setPadding(self, pad): """setPadding() -> bytes of length 1. Padding character.""" if pad is not None: pad = self._guardAgainstUnicode(pad) self._padding = pad def getPadMode(self): """getPadMode() -> pyDes.PAD_NORMAL or pyDes.PAD_PKCS5""" return self._padmode def setPadMode(self, mode): """Sets the type of padding mode, pyDes.PAD_NORMAL or pyDes.PAD_PKCS5""" self._padmode = mode def getIV(self): """getIV() -> bytes""" return self._iv def setIV(self, IV): """Will set the Initial Value, used in conjunction with CBC mode""" if not IV or len(IV) != self.block_size: raise ValueError("Invalid Initial Value (IV), must be a multiple of " + str(self.block_size) + " bytes") IV = self._guardAgainstUnicode(IV) self._iv = IV def _padData(self, data, pad, padmode): # Pad data depending on the mode if padmode is None: # Get the default padding mode. padmode = self.getPadMode() if pad and padmode == PAD_PKCS5: raise ValueError("Cannot use a pad character with PAD_PKCS5") if padmode == PAD_NORMAL: if len(data) % self.block_size == 0: # No padding required. return data if not pad: # Get the default padding. pad = self.getPadding() if not pad: raise ValueError("Data must be a multiple of " + str(self.block_size) + " bytes in length. Use padmode=PAD_PKCS5 or set the pad character.") data += (self.block_size - (len(data) % self.block_size)) * pad elif padmode == PAD_PKCS5: pad_len = 8 - (len(data) % self.block_size) if _pythonMajorVersion < 3: data += pad_len * chr(pad_len) else: data += bytes([pad_len] * pad_len) return data def _unpadData(self, data, pad, padmode): # Unpad data depending on the mode. if not data: return data if pad and padmode == PAD_PKCS5: raise ValueError("Cannot use a pad character with PAD_PKCS5") if padmode is None: # Get the default padding mode. padmode = self.getPadMode() if padmode == PAD_NORMAL: if not pad: # Get the default padding. pad = self.getPadding() if pad: data = data[:-self.block_size] + \ data[-self.block_size:].rstrip(pad) elif padmode == PAD_PKCS5: if _pythonMajorVersion < 3: pad_len = ord(data[-1]) else: pad_len = data[-1] data = data[:-pad_len] return data def _guardAgainstUnicode(self, data): # Only accept byte strings or ascii unicode values, otherwise # there is no way to correctly decode the data into bytes. if _pythonMajorVersion < 3: if isinstance(data, unicode): raise ValueError("pyDes can only work with bytes, not Unicode strings.") else: if isinstance(data, str): # Only accept ascii unicode values. try: return data.encode('ascii') except UnicodeEncodeError: pass raise ValueError("pyDes can only work with encoded strings, not Unicode.") return data ############################################################################# # DES # ############################################################################# class des(_baseDes): """DES encryption/decrytpion class Supports ECB (Electronic Code Book) and CBC (Cypher Block Chaining) modes. pyDes.des(key,[mode], [IV]) key -> Bytes containing the encryption key, must be exactly 8 bytes mode -> Optional argument for encryption type, can be either pyDes.ECB (Electronic Code Book), pyDes.CBC (Cypher Block Chaining) IV -> Optional Initial Value bytes, must be supplied if using CBC mode. Must be 8 bytes in length. pad -> Optional argument, set the pad character (PAD_NORMAL) to use during all encrypt/decrypt operations done with this instance. padmode -> Optional argument, set the padding mode (PAD_NORMAL or PAD_PKCS5) to use during all encrypt/decrypt operations done with this instance. """ # Permutation and translation tables for DES __pc1 = [56, 48, 40, 32, 24, 16, 8, 0, 57, 49, 41, 33, 25, 17, 9, 1, 58, 50, 42, 34, 26, 18, 10, 2, 59, 51, 43, 35, 62, 54, 46, 38, 30, 22, 14, 6, 61, 53, 45, 37, 29, 21, 13, 5, 60, 52, 44, 36, 28, 20, 12, 4, 27, 19, 11, 3 ] # number left rotations of pc1 __left_rotations = [ 1, 1, 2, 2, 2, 2, 2, 2, 1, 2, 2, 2, 2, 2, 2, 1 ] # permuted choice key (table 2) __pc2 = [ 13, 16, 10, 23, 0, 4, 2, 27, 14, 5, 20, 9, 22, 18, 11, 3, 25, 7, 15, 6, 26, 19, 12, 1, 40, 51, 30, 36, 46, 54, 29, 39, 50, 44, 32, 47, 43, 48, 38, 55, 33, 52, 45, 41, 49, 35, 28, 31 ] # initial permutation IP __ip = [57, 49, 41, 33, 25, 17, 9, 1, 59, 51, 43, 35, 27, 19, 11, 3, 61, 53, 45, 37, 29, 21, 13, 5, 63, 55, 47, 39, 31, 23, 15, 7, 56, 48, 40, 32, 24, 16, 8, 0, 58, 50, 42, 34, 26, 18, 10, 2, 60, 52, 44, 36, 28, 20, 12, 4, 62, 54, 46, 38, 30, 22, 14, 6 ] # Expansion table for turning 32 bit blocks into 48 bits __expansion_table = [ 31, 0, 1, 2, 3, 4, 3, 4, 5, 6, 7, 8, 7, 8, 9, 10, 11, 12, 11, 12, 13, 14, 15, 16, 15, 16, 17, 18, 19, 20, 19, 20, 21, 22, 23, 24, 23, 24, 25, 26, 27, 28, 27, 28, 29, 30, 31, 0 ] # The (in)famous S-boxes __sbox = [ # S1 [14, 4, 13, 1, 2, 15, 11, 8, 3, 10, 6, 12, 5, 9, 0, 7, 0, 15, 7, 4, 14, 2, 13, 1, 10, 6, 12, 11, 9, 5, 3, 8, 4, 1, 14, 8, 13, 6, 2, 11, 15, 12, 9, 7, 3, 10, 5, 0, 15, 12, 8, 2, 4, 9, 1, 7, 5, 11, 3, 14, 10, 0, 6, 13], # S2 [15, 1, 8, 14, 6, 11, 3, 4, 9, 7, 2, 13, 12, 0, 5, 10, 3, 13, 4, 7, 15, 2, 8, 14, 12, 0, 1, 10, 6, 9, 11, 5, 0, 14, 7, 11, 10, 4, 13, 1, 5, 8, 12, 6, 9, 3, 2, 15, 13, 8, 10, 1, 3, 15, 4, 2, 11, 6, 7, 12, 0, 5, 14, 9], # S3 [10, 0, 9, 14, 6, 3, 15, 5, 1, 13, 12, 7, 11, 4, 2, 8, 13, 7, 0, 9, 3, 4, 6, 10, 2, 8, 5, 14, 12, 11, 15, 1, 13, 6, 4, 9, 8, 15, 3, 0, 11, 1, 2, 12, 5, 10, 14, 7, 1, 10, 13, 0, 6, 9, 8, 7, 4, 15, 14, 3, 11, 5, 2, 12], # S4 [7, 13, 14, 3, 0, 6, 9, 10, 1, 2, 8, 5, 11, 12, 4, 15, 13, 8, 11, 5, 6, 15, 0, 3, 4, 7, 2, 12, 1, 10, 14, 9, 10, 6, 9, 0, 12, 11, 7, 13, 15, 1, 3, 14, 5, 2, 8, 4, 3, 15, 0, 6, 10, 1, 13, 8, 9, 4, 5, 11, 12, 7, 2, 14], # S5 [2, 12, 4, 1, 7, 10, 11, 6, 8, 5, 3, 15, 13, 0, 14, 9, 14, 11, 2, 12, 4, 7, 13, 1, 5, 0, 15, 10, 3, 9, 8, 6, 4, 2, 1, 11, 10, 13, 7, 8, 15, 9, 12, 5, 6, 3, 0, 14, 11, 8, 12, 7, 1, 14, 2, 13, 6, 15, 0, 9, 10, 4, 5, 3], # S6 [12, 1, 10, 15, 9, 2, 6, 8, 0, 13, 3, 4, 14, 7, 5, 11, 10, 15, 4, 2, 7, 12, 9, 5, 6, 1, 13, 14, 0, 11, 3, 8, 9, 14, 15, 5, 2, 8, 12, 3, 7, 0, 4, 10, 1, 13, 11, 6, 4, 3, 2, 12, 9, 5, 15, 10, 11, 14, 1, 7, 6, 0, 8, 13], # S7 [4, 11, 2, 14, 15, 0, 8, 13, 3, 12, 9, 7, 5, 10, 6, 1, 13, 0, 11, 7, 4, 9, 1, 10, 14, 3, 5, 12, 2, 15, 8, 6, 1, 4, 11, 13, 12, 3, 7, 14, 10, 15, 6, 8, 0, 5, 9, 2, 6, 11, 13, 8, 1, 4, 10, 7, 9, 5, 0, 15, 14, 2, 3, 12], # S8 [13, 2, 8, 4, 6, 15, 11, 1, 10, 9, 3, 14, 5, 0, 12, 7, 1, 15, 13, 8, 10, 3, 7, 4, 12, 5, 6, 11, 0, 14, 9, 2, 7, 11, 4, 1, 9, 12, 14, 2, 0, 6, 10, 13, 15, 3, 5, 8, 2, 1, 14, 7, 4, 10, 8, 13, 15, 12, 9, 0, 3, 5, 6, 11], ] # 32-bit permutation function P used on the output of the S-boxes __p = [ 15, 6, 19, 20, 28, 11, 27, 16, 0, 14, 22, 25, 4, 17, 30, 9, 1, 7, 23,13, 31, 26, 2, 8, 18, 12, 29, 5, 21, 10, 3, 24 ] # final permutation IP^-1 __fp = [ 39, 7, 47, 15, 55, 23, 63, 31, 38, 6, 46, 14, 54, 22, 62, 30, 37, 5, 45, 13, 53, 21, 61, 29, 36, 4, 44, 12, 52, 20, 60, 28, 35, 3, 43, 11, 51, 19, 59, 27, 34, 2, 42, 10, 50, 18, 58, 26, 33, 1, 41, 9, 49, 17, 57, 25, 32, 0, 40, 8, 48, 16, 56, 24 ] # Type of crypting being done ENCRYPT = 0x00 DECRYPT = 0x01 # Initialisation def __init__(self, key, mode=ECB, IV=None, pad=None, padmode=PAD_NORMAL): # Sanity checking of arguments. if len(key) != 8: raise ValueError("Invalid DES key size. Key must be exactly 8 bytes long.") _baseDes.__init__(self, mode, IV, pad, padmode) self.key_size = 8 self.L = [] self.R = [] self.Kn = [ [0] * 48 ] * 16 # 16 48-bit keys (K1 - K16) self.final = [] self.setKey(key) def setKey(self, key): """Will set the crypting key for this object. Must be 8 bytes.""" _baseDes.setKey(self, key) self.__create_sub_keys() def __String_to_BitList(self, data): """Turn the string data, into a list of bits (1, 0)'s""" if _pythonMajorVersion < 3: # Turn the strings into integers. Python 3 uses a bytes # class, which already has this behaviour. data = [ord(c) for c in data] l = len(data) * 8 result = [0] * l pos = 0 for ch in data: i = 7 while i >= 0: if ch & (1 << i) != 0: result[pos] = 1 else: result[pos] = 0 pos += 1 i -= 1 return result def __BitList_to_String(self, data): """Turn the list of bits -> data, into a string""" result = [] pos = 0 c = 0 while pos < len(data): c += data[pos] << (7 - (pos % 8)) if (pos % 8) == 7: result.append(c) c = 0 pos += 1 if _pythonMajorVersion < 3: return ''.join([ chr(c) for c in result ]) else: return bytes(result) def __permutate(self, table, block): """Permutate this block with the specified table""" return list(map(lambda x: block[x], table)) # Transform the secret key, so that it is ready for data processing # Create the 16 subkeys, K[1] - K[16] def __create_sub_keys(self): """Create the 16 subkeys K[1] to K[16] from the given key""" key = self.__permutate(des.__pc1, self.__String_to_BitList(self.getKey())) i = 0 # Split into Left and Right sections self.L = key[:28] self.R = key[28:] while i < 16: j = 0 # Perform circular left shifts while j < des.__left_rotations[i]: self.L.append(self.L[0]) del self.L[0] self.R.append(self.R[0]) del self.R[0] j += 1 # Create one of the 16 subkeys through pc2 permutation self.Kn[i] = self.__permutate(des.__pc2, self.L + self.R) i += 1 # Main part of the encryption algorithm, the number cruncher :) def __des_crypt(self, block, crypt_type): """Crypt the block of data through DES bit-manipulation""" block = self.__permutate(des.__ip, block) self.L = block[:32] self.R = block[32:] # Encryption starts from Kn[1] through to Kn[16] if crypt_type == des.ENCRYPT: iteration = 0 iteration_adjustment = 1 # Decryption starts from Kn[16] down to Kn[1] else: iteration = 15 iteration_adjustment = -1 i = 0 while i < 16: # Make a copy of R[i-1], this will later become L[i] tempR = self.R[:] # Permutate R[i - 1] to start creating R[i] self.R = self.__permutate(des.__expansion_table, self.R) # Exclusive or R[i - 1] with K[i], create B[1] to B[8] whilst here self.R = list(map(lambda x, y: x ^ y, self.R, self.Kn[iteration])) B = [self.R[:6], self.R[6:12], self.R[12:18], self.R[18:24], self.R[24:30], self.R[30:36], self.R[36:42], self.R[42:]] # Optimization: Replaced below commented code with above #j = 0 #B = [] #while j < len(self.R): # self.R[j] = self.R[j] ^ self.Kn[iteration][j] # j += 1 # if j % 6 == 0: # B.append(self.R[j-6:j]) # Permutate B[1] to B[8] using the S-Boxes j = 0 Bn = [0] * 32 pos = 0 while j < 8: # Work out the offsets m = (B[j][0] << 1) + B[j][5] n = (B[j][1] << 3) + (B[j][2] << 2) + (B[j][3] << 1) + B[j][4] # Find the permutation value v = des.__sbox[j][(m << 4) + n] # Turn value into bits, add it to result: Bn Bn[pos] = (v & 8) >> 3 Bn[pos + 1] = (v & 4) >> 2 Bn[pos + 2] = (v & 2) >> 1 Bn[pos + 3] = v & 1 pos += 4 j += 1 # Permutate the concatination of B[1] to B[8] (Bn) self.R = self.__permutate(des.__p, Bn) # Xor with L[i - 1] self.R = list(map(lambda x, y: x ^ y, self.R, self.L)) # Optimization: This now replaces the below commented code #j = 0 #while j < len(self.R): # self.R[j] = self.R[j] ^ self.L[j] # j += 1 # L[i] becomes R[i - 1] self.L = tempR i += 1 iteration += iteration_adjustment # Final permutation of R[16]L[16] self.final = self.__permutate(des.__fp, self.R + self.L) return self.final # Data to be encrypted/decrypted def crypt(self, data, crypt_type): """Crypt the data in blocks, running it through des_crypt()""" # Error check the data if not data: return '' if len(data) % self.block_size != 0: if crypt_type == des.DECRYPT: # Decryption must work on 8 byte blocks raise ValueError("Invalid data length, data must be a multiple of " + str(self.block_size) + " bytes\n.") if not self.getPadding(): raise ValueError("Invalid data length, data must be a multiple of " + str(self.block_size) + " bytes\n. Try setting the optional padding character") else: data += (self.block_size - (len(data) % self.block_size)) * self.getPadding() # print "Len of data: %f" % (len(data) / self.block_size) if self.getMode() == CBC: if self.getIV(): iv = self.__String_to_BitList(self.getIV()) else: raise ValueError("For CBC mode, you must supply the Initial Value (IV) for ciphering") # Split the data into blocks, crypting each one seperately i = 0 dict = {} result = [] #cached = 0 #lines = 0 while i < len(data): # Test code for caching encryption results #lines += 1 #if dict.has_key(data[i:i+8]): #print "Cached result for: %s" % data[i:i+8] # cached += 1 # result.append(dict[data[i:i+8]]) # i += 8 # continue block = self.__String_to_BitList(data[i:i+8]) # Xor with IV if using CBC mode if self.getMode() == CBC: if crypt_type == des.ENCRYPT: block = list(map(lambda x, y: x ^ y, block, iv)) #j = 0 #while j < len(block): # block[j] = block[j] ^ iv[j] # j += 1 processed_block = self.__des_crypt(block, crypt_type) if crypt_type == des.DECRYPT: processed_block = list(map(lambda x, y: x ^ y, processed_block, iv)) #j = 0 #while j < len(processed_block): # processed_block[j] = processed_block[j] ^ iv[j] # j += 1 iv = block else: iv = processed_block else: processed_block = self.__des_crypt(block, crypt_type) # Add the resulting crypted block to our list #d = self.__BitList_to_String(processed_block) #result.append(d) result.append(self.__BitList_to_String(processed_block)) #dict[data[i:i+8]] = d i += 8 # print "Lines: %d, cached: %d" % (lines, cached) # Return the full crypted string if _pythonMajorVersion < 3: return ''.join(result) else: return bytes.fromhex('').join(result) def encrypt(self, data, pad=None, padmode=None): """encrypt(data, [pad], [padmode]) -> bytes data : Bytes to be encrypted pad : Optional argument for encryption padding. Must only be one byte padmode : Optional argument for overriding the padding mode. The data must be a multiple of 8 bytes and will be encrypted with the already specified key. Data does not have to be a multiple of 8 bytes if the padding character is supplied, or the padmode is set to PAD_PKCS5, as bytes will then added to ensure the be padded data is a multiple of 8 bytes. """ data = self._guardAgainstUnicode(data) if pad is not None: pad = self._guardAgainstUnicode(pad) data = self._padData(data, pad, padmode) return self.crypt(data, des.ENCRYPT) def decrypt(self, data, pad=None, padmode=None): """decrypt(data, [pad], [padmode]) -> bytes data : Bytes to be decrypted pad : Optional argument for decryption padding. Must only be one byte padmode : Optional argument for overriding the padding mode. The data must be a multiple of 8 bytes and will be decrypted with the already specified key. In PAD_NORMAL mode, if the optional padding character is supplied, then the un-encrypted data will have the padding characters removed from the end of the bytes. This pad removal only occurs on the last 8 bytes of the data (last data block). In PAD_PKCS5 mode, the special padding end markers will be removed from the data after decrypting. """ data = self._guardAgainstUnicode(data) if pad is not None: pad = self._guardAgainstUnicode(pad) data = self.crypt(data, des.DECRYPT) return self._unpadData(data, pad, padmode) ############################################################################# # Triple DES # ############################################################################# class triple_des(_baseDes): """Triple DES encryption/decrytpion class This algorithm uses the DES-EDE3 (when a 24 byte key is supplied) or the DES-EDE2 (when a 16 byte key is supplied) encryption methods. Supports ECB (Electronic Code Book) and CBC (Cypher Block Chaining) modes. pyDes.des(key, [mode], [IV]) key -> Bytes containing the encryption key, must be either 16 or 24 bytes long mode -> Optional argument for encryption type, can be either pyDes.ECB (Electronic Code Book), pyDes.CBC (Cypher Block Chaining) IV -> Optional Initial Value bytes, must be supplied if using CBC mode. Must be 8 bytes in length. pad -> Optional argument, set the pad character (PAD_NORMAL) to use during all encrypt/decrypt operations done with this instance. padmode -> Optional argument, set the padding mode (PAD_NORMAL or PAD_PKCS5) to use during all encrypt/decrypt operations done with this instance. """ def __init__(self, key, mode=ECB, IV=None, pad=None, padmode=PAD_NORMAL): _baseDes.__init__(self, mode, IV, pad, padmode) self.setKey(key) def setKey(self, key): """Will set the crypting key for this object. Either 16 or 24 bytes long.""" self.key_size = 24 # Use DES-EDE3 mode if len(key) != self.key_size: if len(key) == 16: # Use DES-EDE2 mode self.key_size = 16 else: raise ValueError("Invalid triple DES key size. Key must be either 16 or 24 bytes long") if self.getMode() == CBC: if not self.getIV(): # Use the first 8 bytes of the key self._iv = key[:self.block_size] if len(self.getIV()) != self.block_size: raise ValueError("Invalid IV, must be 8 bytes in length") self.__key1 = des(key[:8], self._mode, self._iv, self._padding, self._padmode) self.__key2 = des(key[8:16], self._mode, self._iv, self._padding, self._padmode) if self.key_size == 16: self.__key3 = self.__key1 else: self.__key3 = des(key[16:], self._mode, self._iv, self._padding, self._padmode) _baseDes.setKey(self, key) # Override setter methods to work on all 3 keys. def setMode(self, mode): """Sets the type of crypting mode, pyDes.ECB or pyDes.CBC""" _baseDes.setMode(self, mode) for key in (self.__key1, self.__key2, self.__key3): key.setMode(mode) def setPadding(self, pad): """setPadding() -> bytes of length 1. Padding character.""" _baseDes.setPadding(self, pad) for key in (self.__key1, self.__key2, self.__key3): key.setPadding(pad) def setPadMode(self, mode): """Sets the type of padding mode, pyDes.PAD_NORMAL or pyDes.PAD_PKCS5""" _baseDes.setPadMode(self, mode) for key in (self.__key1, self.__key2, self.__key3): key.setPadMode(mode) def setIV(self, IV): """Will set the Initial Value, used in conjunction with CBC mode""" _baseDes.setIV(self, IV) for key in (self.__key1, self.__key2, self.__key3): key.setIV(IV) def encrypt(self, data, pad=None, padmode=None): """encrypt(data, [pad], [padmode]) -> bytes data : bytes to be encrypted pad : Optional argument for encryption padding. Must only be one byte padmode : Optional argument for overriding the padding mode. The data must be a multiple of 8 bytes and will be encrypted with the already specified key. Data does not have to be a multiple of 8 bytes if the padding character is supplied, or the padmode is set to PAD_PKCS5, as bytes will then added to ensure the be padded data is a multiple of 8 bytes. """ ENCRYPT = des.ENCRYPT DECRYPT = des.DECRYPT data = self._guardAgainstUnicode(data) if pad is not None: pad = self._guardAgainstUnicode(pad) # Pad the data accordingly. data = self._padData(data, pad, padmode) if self.getMode() == CBC: self.__key1.setIV(self.getIV()) self.__key2.setIV(self.getIV()) self.__key3.setIV(self.getIV()) i = 0 result = [] while i < len(data): block = self.__key1.crypt(data[i:i+8], ENCRYPT) block = self.__key2.crypt(block, DECRYPT) block = self.__key3.crypt(block, ENCRYPT) self.__key1.setIV(block) self.__key2.setIV(block) self.__key3.setIV(block) result.append(block) i += 8 if _pythonMajorVersion < 3: return ''.join(result) else: return bytes.fromhex('').join(result) else: data = self.__key1.crypt(data, ENCRYPT) data = self.__key2.crypt(data, DECRYPT) return self.__key3.crypt(data, ENCRYPT) def decrypt(self, data, pad=None, padmode=None): """decrypt(data, [pad], [padmode]) -> bytes data : bytes to be encrypted pad : Optional argument for decryption padding. Must only be one byte padmode : Optional argument for overriding the padding mode. The data must be a multiple of 8 bytes and will be decrypted with the already specified key. In PAD_NORMAL mode, if the optional padding character is supplied, then the un-encrypted data will have the padding characters removed from the end of the bytes. This pad removal only occurs on the last 8 bytes of the data (last data block). In PAD_PKCS5 mode, the special padding end markers will be removed from the data after decrypting, no pad character is required for PAD_PKCS5. """ ENCRYPT = des.ENCRYPT DECRYPT = des.DECRYPT data = self._guardAgainstUnicode(data) if pad is not None: pad = self._guardAgainstUnicode(pad) if self.getMode() == CBC: self.__key1.setIV(self.getIV()) self.__key2.setIV(self.getIV()) self.__key3.setIV(self.getIV()) i = 0 result = [] while i < len(data): iv = data[i:i+8] block = self.__key3.crypt(iv, DECRYPT) block = self.__key2.crypt(block, ENCRYPT) block = self.__key1.crypt(block, DECRYPT) self.__key1.setIV(iv) self.__key2.setIV(iv) self.__key3.setIV(iv) result.append(block) i += 8 if _pythonMajorVersion < 3: data = ''.join(result) else: data = bytes.fromhex('').join(result) else: data = self.__key3.crypt(data, DECRYPT) data = self.__key2.crypt(data, ENCRYPT) data = self.__key1.crypt(data, DECRYPT) return self._unpadData(data, pad, padmode) unicrypto-0.0.10/unicrypto/backends/pure/external/DES/__init__.py000066400000000000000000000000001437177004600247520ustar00rootroot00000000000000unicrypto-0.0.10/unicrypto/backends/pure/external/RC4/000077500000000000000000000000001437177004600226305ustar00rootroot00000000000000unicrypto-0.0.10/unicrypto/backends/pure/external/RC4/RC4.py000066400000000000000000000041401437177004600235710ustar00rootroot00000000000000#!/usr/bin/env python """ https://raw.githubusercontent.com/bozhu/RC4-Python/master/rc4.py Copyright (C) 2012 Bo Zhu http://about.bozhu.me Permission is hereby granted, free of charge, to any person obtaining a copy of this software and associated documentation files (the "Software"), to deal in the Software without restriction, including without limitation the rights to use, copy, modify, merge, publish, distribute, sublicense, and/or sell copies of the Software, and to permit persons to whom the Software is furnished to do so, subject to the following conditions: The above copyright notice and this permission notice shall be included in all copies or substantial portions of the Software. THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY, FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE SOFTWARE. """ class RC4(): def __init__(self, key): self.key = key self.S = self.KSA() self.keystream = self.PRGA() def KSA(self): keylength = len(self.key) S = list(range(256)) j = 0 for i in range(256): j = (j + S[i] + self.key[i % keylength]) % 256 S[i], S[j] = S[j], S[i] # swap return S def PRGA(self): i = 0 j = 0 while True: i = (i + 1) % 256 j = (j + self.S[i]) % 256 self.S[i], self.S[j] = self.S[j], self.S[i] # swap K = self.S[(self.S[i] + self.S[j]) % 256] yield K def encrypt(self, data): res = b'' for b in data: res += (b ^ next(self.keystream)).to_bytes(1, byteorder = 'big', signed = False) return res def decrypt(self, data): return self.encrypt(data)unicrypto-0.0.10/unicrypto/backends/pure/external/RC4/__init__.py000066400000000000000000000000001437177004600247270ustar00rootroot00000000000000unicrypto-0.0.10/unicrypto/backends/pure/external/__init__.py000066400000000000000000000000001437177004600243370ustar00rootroot00000000000000unicrypto-0.0.10/unicrypto/backends/pure/padding/000077500000000000000000000000001437177004600220245ustar00rootroot00000000000000unicrypto-0.0.10/unicrypto/backends/pure/padding/__init__.py000066400000000000000000000000001437177004600241230ustar00rootroot00000000000000unicrypto-0.0.10/unicrypto/backends/pure/padding/pkcs7.py000066400000000000000000000013431437177004600234260ustar00rootroot00000000000000 # Original Source: http://japrogbits.blogspot.com/2011/02/using-encrypted-data-between-python-and.html # https://gist.github.com/adoc/8550490 def unpad(bytestring, k=16): """ Remove the PKCS#7 padding from a text bytestring. """ val = bytestring[-1] if val > k: raise ValueError('Input is not padded or padding is corrupt') l = len(bytestring) - val return bytestring[:l] ## @param bytestring The text to encode. ## @param k The padding block size. # @return bytestring The padded bytestring. def pad(bytestring, k=16): """ Pad an input bytestring according to PKCS#7 """ l = len(bytestring) val = k - (l % k) return bytestring + bytearray([val] * val)unicrypto-0.0.10/unicrypto/backends/pycrypto/000077500000000000000000000000001437177004600213345ustar00rootroot00000000000000unicrypto-0.0.10/unicrypto/backends/pycrypto/AES.py000066400000000000000000000156621437177004600223300ustar00rootroot00000000000000 from Crypto.Cipher import AES as _pyCryptoAES from Crypto.Util import Counter from unicrypto.symmetric import symmetricBASE, cipherMODE import struct from unicrypto import hashlib class AES(symmetricBASE): def __init__(self, key, mode = cipherMODE.ECB, IV = None, segment_size = 8): self._ccm_cipher_ctr = None self._ccm_cipher_cbc = None symmetricBASE.__init__(self, key, mode, IV, segment_size = segment_size) def setup_cipher(self): if self.mode == cipherMODE.ECB: self._cipher = _pyCryptoAES.new(self.key, _pyCryptoAES.MODE_ECB) elif self.mode == cipherMODE.CBC: self._cipher = _pyCryptoAES.new(self.key, _pyCryptoAES.MODE_CBC, self.IV) elif self.mode == cipherMODE.CTR: self._cipher = _pyCryptoAES.new(self.key, _pyCryptoAES.MODE_CTR, self.IV, counter=Counter.new(128, initial_value=int.from_bytes(self.IV, byteorder='big', signed=False))) elif self.mode == cipherMODE.CFB: self._cipher = _pyCryptoAES.new(self.key, _pyCryptoAES.MODE_CFB, self.IV, segment_size=self.segment_size) elif self.mode == cipherMODE.OFB: self._cipher = _pyCryptoAES.new(self.key, _pyCryptoAES.MODE_OFB, self.IV) elif self.mode == cipherMODE.CCM: if self.segment_size not in (4, 6, 8, 10, 12, 14, 16): raise ValueError("Parameter 'mac_len' must be even and in the range 4..16 (not %d)" % self.segment_size) if not (self.IV and 7 <= len(self.IV) <= 13): raise ValueError("Length of parameter 'nonce' must be in the range 7..13 bytes") q = 15 - len(self.IV) t_nonce = struct.pack("B", q - 1) + self.IV t_noncepad = b'\x00'*(16 - (len(t_nonce) % 16)) # 16 is the blocksize t_nonce += t_noncepad self._ccm_cipher_ctr = _pyCryptoAES.new(self.key, _pyCryptoAES.MODE_CTR, self.IV, counter=Counter.new(128, initial_value=int.from_bytes(t_nonce, byteorder='big', signed=False))) self._ccm_cipher_cbc = _pyCryptoAES.new(self.key, _pyCryptoAES.MODE_CBC, b'\x00'*16) elif self.mode == cipherMODE.GCM: from unicrypto.backends.crypto.extra.AESGCM import AES_GCM self._cipher = AES_GCM(self.key) else: raise Exception('Unknown cipher mode!') def encrypt(self, data, aad = None): if self.mode == cipherMODE.CCM: return self.__ccm_encrypt(data, aad) if self.mode == cipherMODE.GCM: return self._cipher.encrypt(self.IV, data, aad) if (self.mode == cipherMODE.CFB or self.mode == cipherMODE.OFB) and (self._cipher.block_size - len(data) % self._cipher.block_size) % self._cipher.block_size != 0: padding_length = (self._cipher.block_size - len(data) % self._cipher.block_size) % self._cipher.block_size padded_data = data + b'\x00'*padding_length enc_data = self._cipher.encrypt(padded_data) return enc_data[:len(data)] return self._cipher.encrypt(data) def decrypt(self, data, aad = None, mac = None): if self.mode == cipherMODE.CCM: return self.__ccm_decrypt(data, aad, mac) if self.mode == cipherMODE.GCM: return self._cipher.decrypt(self.IV, data, mac, aad) if (self.mode == cipherMODE.CFB or self.mode == cipherMODE.OFB) and (self._cipher.block_size - len(data) % self._cipher.block_size) % self._cipher.block_size != 0: padding_length = (self._cipher.block_size - len(data) % self._cipher.block_size) % self._cipher.block_size padded_data = data + b'\x00'*padding_length enc_data = self._cipher.decrypt(padded_data) return enc_data[:len(data)] return self._cipher.decrypt(data) def __ccm_encrypt(self, plaintext, aad): q = 15 - len(self.IV) blockSize = 16 # For AES... s0 = self._ccm_cipher_ctr.encrypt(b'\x00'*16) # For mac #print(f"My s0 {s0}") c = self._ccm_cipher_ctr.encrypt(plaintext) # Mac pLen = len(plaintext) aadLen = len(aad) flags = (64 * (aadLen > 0) + 8 * ((self.segment_size - 2) // 2) + (q - 1)) b0 = struct.pack("B", flags) + self.IV + pLen.to_bytes(q, 'big') assocLenEncoded = b'' if aadLen > 0: if aadLen < (2 ** 16 - 2 ** 8): encSize = 2 elif aadLen < (2 ** 32): assocLenEncoded = b'\xFF\xFE' encSize = 4 else: assocLenEncoded = b'\xFF\xFF' encSize = 8 assocLenEncoded += aadLen.to_bytes(encSize, 'big') aadPadded = assocLenEncoded + aad #print(f"aad Format before pad: {len(aadPadded)}" ) aadPad = b'' if len(aadPadded) % blockSize != 0: #print("need to padd aad") aadPad = b'\x00'*(blockSize - (len(aadPadded) % blockSize)) aadPadded += aadPad ptxtPadded = plaintext #ptxt padding ptxtPad = b'' if (pLen % blockSize) != 0: #print("Should pad ptxt") ptxtPad = b'\x00'*(blockSize - (pLen % blockSize)) ptxtPadded += ptxtPad macData = b0 + aadPadded + ptxtPadded #print(f"MAC input {macData}") t = self._ccm_cipher_cbc.encrypt(macData) t = t[-16:] tag = bytes([a ^ b for (a,b) in zip(t,s0)])[:self.segment_size] return (c, tag) def __ccm_decrypt(self, ciphertext, aad, macvalue): #print('aad: %s' % aad) #print('mac: %s' % macvalue) # Decrytion: in CTR Encrypt == Decrypt # Decryption q = 15 - len(self.IV) s0 = self._ccm_cipher_ctr.encrypt(b'\x00'*16) # For mac #print(f"My s0 {s0}") plaintext = self._ccm_cipher_ctr.encrypt(ciphertext) #print(f"recoverd plaintex {plaintext}") # Mac pLen = len(plaintext) aadLen = len(aad) flags = (64 * (aadLen > 0) + 8 * ((self.segment_size - 2) // 2) + (q - 1)) b0 = struct.pack("B", flags) + self.IV + pLen.to_bytes(q, 'big') assocLenEncoded = b'' if aadLen > 0: if aadLen < (2 ** 16 - 2 ** 8): encSize = 2 elif aadLen < (2 ** 32): assocLenEncoded = b'\xFF\xFE' encSize = 4 else: assocLenEncoded = b'\xFF\xFF' encSize = 8 assocLenEncoded += aadLen.to_bytes(encSize, 'big') aadPadded = assocLenEncoded + aad #print(f"aad Format before pad: {len(aadPadded)}" ) aadPad = b'' if len(aadPadded) % 16 != 0: #print("need to padd aad") aadPad = b'\x00'*(16 - (len(aadPadded) % 16)) aadPadded += aadPad ptxtPadded = plaintext #ptxt padding ptxtPad = b'' if pLen % 16 != 0: #print("Should pad ptxt") ptxtPad = b'\x00'*(16 - (pLen % 16)) ptxtPadded += ptxtPad macData = b0 + aadPadded + ptxtPadded #t = mac.encrypt(macData)[-16:] t = self._ccm_cipher_cbc.encrypt(macData) t = t[-16:] tag = bytes([a ^ b for (a,b) in zip(t,s0)])[:self.segment_size] #return plaintext ## Attempt to secure comparison... Idea: hash expected and received macs and compare the result in constant time... ## Ideally should be done with HMAC with a RANDOM KEY! Doesn't cost much on a performance level. ## For now we use shake_128(SHA3 without a key) #print(f"received mac {macvalue} \nComputed {tag}") h1 = hashlib.sha256() h1.update(tag) digest1 = h1.digest() h2 = hashlib.sha256() h2.update(macvalue) digest2 = h2.digest() # Constant time comparison of hashes. Probably overkill here because of the randomization introduced by HMAC.. result = 0 for x, y in zip(digest1, digest2): result |= x ^ y #print(f"Reuslt {result}") if result != 0: raise ValueError("Incorrect MAC") else: return plaintext unicrypto-0.0.10/unicrypto/backends/pycrypto/DES.py000066400000000000000000000013111437177004600223150ustar00rootroot00000000000000 from Crypto.Cipher import DES as _pyCryptoDES from unicrypto.symmetric import symmetricBASE, cipherMODE, expand_DES_key class DES(symmetricBASE): def __init__(self, key, mode = cipherMODE.ECB, IV = None): symmetricBASE.__init__(self, key, mode, IV) def setup_cipher(self): if len(self.key) == 7: self.key = expand_DES_key(self.key) if self.mode == cipherMODE.ECB: self._cipher = _pyCryptoDES.new(self.key) elif self.mode == cipherMODE.CBC: self._cipher = _pyCryptoDES.new(self.key, _pyCryptoDES.MODE_CBC, self.IV) else: raise Exception('Unknown cipher mode!') def encrypt(self, data): return self._cipher.encrypt(data) def decrypt(self, data): return self._cipher.decrypt(data) unicrypto-0.0.10/unicrypto/backends/pycrypto/RC4.py000066400000000000000000000006131437177004600222760ustar00rootroot00000000000000 from Crypto.Cipher import ARC4 as _pyCryptoRC4 from unicrypto.symmetric import symmetricBASE, cipherMODE class RC4(symmetricBASE): def __init__(self, key): symmetricBASE.__init__(self, key) def setup_cipher(self): self._cipher = _pyCryptoRC4.new(self.key) def encrypt(self, data): return self._cipher.encrypt(data) def decrypt(self, data): return self._cipher.decrypt(data) unicrypto-0.0.10/unicrypto/backends/pycrypto/TDES.py000066400000000000000000000012721437177004600224470ustar00rootroot00000000000000 from Crypto.Cipher import DES3 as _pyCryptoDES3 from unicrypto.symmetric import symmetricBASE, cipherMODE class TDES(symmetricBASE): def __init__(self, key, mode = cipherMODE.ECB, IV = None, pad = None, padMode = None): symmetricBASE.__init__(self, key, mode, IV) def setup_cipher(self): if self.mode == cipherMODE.ECB: self._cipher = _pyCryptoDES3.new(self.key, _pyCryptoDES3.MODE_ECB) elif self.mode == cipherMODE.CBC: self._cipher = _pyCryptoDES3.new(self.key, _pyCryptoDES3.MODE_CBC, self.IV) else: raise Exception('Unknown cipher mode!') def encrypt(self, data): return self._cipher.encrypt(data) def decrypt(self, data): return self._cipher.decrypt(data) unicrypto-0.0.10/unicrypto/backends/pycrypto/__init__.py000066400000000000000000000000431437177004600234420ustar00rootroot00000000000000from . import AES, DES, RC4, TDES unicrypto-0.0.10/unicrypto/backends/pycrypto/extra/000077500000000000000000000000001437177004600224575ustar00rootroot00000000000000unicrypto-0.0.10/unicrypto/backends/pycrypto/extra/AESGCM.py000066400000000000000000000151371437177004600237770ustar00rootroot00000000000000#!/usr/bin/env python """ Copyright (C) 2013 Bo Zhu http://about.bozhu.me Permission is hereby granted, free of charge, to any person obtaining a copy of this software and associated documentation files (the "Software"), to deal in the Software without restriction, including without limitation the rights to use, copy, modify, merge, publish, distribute, sublicense, and/or sell copies of the Software, and to permit persons to whom the Software is furnished to do so, subject to the following conditions: The above copyright notice and this permission notice shall be included in all copies or substantial portions of the Software. THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY, FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE SOFTWARE. SkelSec Note: the original code has been modified to work using questionable crypto libraries by myself who is not a cryptographer. I'd say "use it with suspicion" but in truth: just do not use this at all outside of this library. """ from Crypto.Cipher import AES from Crypto.Util import Counter def int_to_bytes(x: int, blocksize = 0) -> bytes: if blocksize == 0: return x.to_bytes((x.bit_length() + 7) // 8, 'big') else: return x.to_bytes(blocksize, 'big') # GF(2^128) defined by 1 + a + a^2 + a^7 + a^128 # Please note the MSB is x0 and LSB is x127 def gf_2_128_mul(x, y): assert x < (1 << 128) assert y < (1 << 128) res = 0 for i in range(127, -1, -1): res ^= x * ((y >> i) & 1) # branchless x = (x >> 1) ^ ((x & 1) * 0xE1000000000000000000000000000000) assert res < 1 << 128 return res class InvalidInputException(Exception): def __init__(self, msg): self.msg = msg def __str__(self): return str(self.msg) class InvalidTagException(Exception): def __str__(self): return 'The authenticaiton tag is invalid.' # Galois/Counter Mode with AES-128 and 96-bit IV class AES_GCM: def __init__(self, master_key): self.change_key(master_key) def change_key(self, master_key): #if len(master_key) != 16: # raise InvalidInputException('Master key should be 128-bit') self.__master_key = master_key self.__aes_ecb = AES.new(self.__master_key, AES.MODE_ECB) self.__auth_key = self.__aes_ecb.encrypt(b'\x00' * 16) self.__auth_key_int = int.from_bytes(self.__auth_key, byteorder='big', signed=False) # precompute the table for multiplication in finite field table = [] # for 8-bit for i in range(16): row = [] for j in range(256): row.append(gf_2_128_mul(self.__auth_key_int, j << (8 * i))) table.append(tuple(row)) self.__pre_table = tuple(table) self.prev_init_value = None # reset def __times_auth_key(self, val): res = 0 for i in range(16): res ^= self.__pre_table[i][val & 0xFF] val >>= 8 return res def __ghash(self, aad, txt): len_aad = len(aad) len_txt = len(txt) # padding if 0 == len_aad % 16: data = aad else: data = aad + b'\x00' * (16 - len_aad % 16) if 0 == len_txt % 16: data += txt else: data += txt + b'\x00' * (16 - len_txt % 16) tag = 0 assert len(data) % 16 == 0 for i in range(len(data) // 16): tag ^= int.from_bytes(data[i * 16: (i + 1) * 16], byteorder='big', signed=False) tag = self.__times_auth_key(tag) tag ^= ((8 * len_aad) << 64) | (8 * len_txt) tag = self.__times_auth_key(tag) return tag def encrypt(self, init_value, plaintext, auth_data=b''): #if len(init_value) != 12: # raise InvalidInputException('IV should be 96-bit') # a naive checking for IV reuse len_plaintext = len(plaintext) if len_plaintext > 0: if len(init_value) == 12: ctrval_init = init_value + b'\x00\x00\x00\x02' # ends with 2!!! ctrval = int.from_bytes(ctrval_init, byteorder='big', signed=False) iv_int = int.from_bytes(init_value, byteorder='big', signed=False) iv_int = (iv_int << 32) | 1 iv_int = iv_int.to_bytes(16, byteorder='big', signed=False) else: ctrval = self.__ghash(b'', init_value) iv_int = ctrval.to_bytes(16, byteorder='big', signed=False) ctrval += 1 counter = Counter.new( nbits=128, prefix=b'', initial_value=ctrval, # notice this allow_wraparound=False) aes_ctr = AES.new(self.__master_key, AES.MODE_CTR, counter=counter) if 0 != len_plaintext % 16: padded_plaintext = plaintext + \ b'\x00' * (16 - len_plaintext % 16) else: padded_plaintext = plaintext ciphertext = aes_ctr.encrypt(padded_plaintext)[:len_plaintext] else: ciphertext = b'' iv_int = int.from_bytes(init_value, byteorder='big', signed=False) iv_int = (iv_int << 32) | 1 iv_int = iv_int.to_bytes(16, byteorder='big', signed=False) auth_tag = self.__ghash(auth_data, ciphertext) iv_int_enc = self.__aes_ecb.encrypt(iv_int) iv_int_enc = int.from_bytes(iv_int_enc, byteorder='big', signed=False) auth_tag ^= iv_int_enc assert auth_tag < (1 << 128) return ciphertext, auth_tag.to_bytes(16, byteorder='big', signed=False) def decrypt(self, init_value, ciphertext, auth_tag, auth_data=b''): if len(auth_tag) != 16: raise InvalidInputException('Tag should be 128-bit') if len(init_value) == 12: iv_int = int.from_bytes(init_value, byteorder='big', signed=False) iv_int = (iv_int << 32) | 1 iv_int = iv_int.to_bytes(16, byteorder='big', signed=False) ctrval_init = init_value + b'\x00\x00\x00\x02' # ends with 2!!! ctrval = int.from_bytes(ctrval_init, byteorder='big', signed=False) else: ctrval = self.__ghash(b'', init_value) iv_int = int_to_bytes(ctrval, 16) ctrval += 1 iv_int_enc = self.__aes_ecb.encrypt(iv_int) iv_int_enc = int.from_bytes(iv_int_enc, byteorder='big', signed=False) auth_tag_verify = self.__ghash(auth_data, ciphertext) ^ iv_int_enc auth_tag_verify = auth_tag_verify.to_bytes(16, byteorder='big', signed=False) if auth_tag != auth_tag_verify: raise InvalidTagException len_ciphertext = len(ciphertext) if len_ciphertext > 0: counter = Counter.new( nbits=128, prefix=b'', initial_value=ctrval, # notice this allow_wraparound=False) aes_ctr = AES.new(self.__master_key, AES.MODE_CTR, counter=counter) if 0 != len_ciphertext % 16: padded_ciphertext = ciphertext + \ b'\x00' * (16 - len_ciphertext % 16) else: padded_ciphertext = ciphertext plaintext = aes_ctr.decrypt(padded_ciphertext)[:len_ciphertext] else: plaintext = b'' return plaintext unicrypto-0.0.10/unicrypto/backends/pycrypto/extra/__init__.py000066400000000000000000000000001437177004600245560ustar00rootroot00000000000000unicrypto-0.0.10/unicrypto/backends/pycryptodome/000077500000000000000000000000001437177004600222015ustar00rootroot00000000000000unicrypto-0.0.10/unicrypto/backends/pycryptodome/AES.py000066400000000000000000000036361437177004600231730ustar00rootroot00000000000000 from Crypto.Cipher import AES as _pyCryptodomeAES from Crypto.Util import Counter from unicrypto.symmetric import symmetricBASE, cipherMODE class AES(symmetricBASE): def __init__(self, key, mode = cipherMODE.ECB, IV = None, segment_size = 128): symmetricBASE.__init__(self, key, mode, IV, segment_size=segment_size) def setup_cipher(self): if self.mode == cipherMODE.ECB: self._cipher = _pyCryptodomeAES.new(self.key, _pyCryptodomeAES.MODE_ECB) #_pyCryptodomeDES.new(self.key, _pyCryptodomeDES.MODE_ECB) elif self.mode == cipherMODE.CBC: self._cipher = _pyCryptodomeAES.new(self.key, _pyCryptodomeAES.MODE_CBC, iv=self.IV) elif self.mode == cipherMODE.CTR: self._cipher = _pyCryptodomeAES.new(self.key, _pyCryptodomeAES.MODE_CTR, counter=Counter.new(128, initial_value=int.from_bytes(self.IV, byteorder='big', signed=False))) elif self.mode == cipherMODE.CFB: self._cipher = _pyCryptodomeAES.new(self.key, _pyCryptodomeAES.MODE_CFB, iv=self.IV, segment_size=self.segment_size) elif self.mode == cipherMODE.OFB: self._cipher = _pyCryptodomeAES.new(self.key, _pyCryptodomeAES.MODE_OFB, iv=self.IV) elif self.mode == cipherMODE.CCM: self._cipher = _pyCryptodomeAES.new(self.key, _pyCryptodomeAES.MODE_CCM, self.IV, mac_len= self.segment_size) elif self.mode == cipherMODE.GCM: self._cipher = _pyCryptodomeAES.new(self.key, _pyCryptodomeAES.MODE_GCM, self.IV, mac_len= self.segment_size) else: raise Exception('Unknown cipher mode!') def encrypt(self, data, aad = None): if self.mode == cipherMODE.CCM or self.mode == cipherMODE.GCM: self._cipher.update(aad) return self._cipher.encrypt_and_digest(data) else: return self._cipher.encrypt(data) def decrypt(self, data, aad = None, mac = None): if self.mode == cipherMODE.CCM or self.mode == cipherMODE.GCM: self._cipher.update(aad) return self._cipher.decrypt_and_verify(data, mac) else: return self._cipher.decrypt(data)unicrypto-0.0.10/unicrypto/backends/pycryptodome/DES.py000066400000000000000000000013671437177004600231750ustar00rootroot00000000000000 from Crypto.Cipher import DES as _pyCryptodomeDES from unicrypto.symmetric import symmetricBASE, cipherMODE, expand_DES_key class DES(symmetricBASE): def __init__(self, key, mode = cipherMODE.ECB, IV = None): symmetricBASE.__init__(self, key, mode, IV) def setup_cipher(self): if len(self.key) == 7: self.key = expand_DES_key(self.key) if self.mode == cipherMODE.ECB: self._cipher = _pyCryptodomeDES.new(self.key, _pyCryptodomeDES.MODE_ECB) elif self.mode == cipherMODE.CBC: self._cipher = _pyCryptodomeDES.new(self.key, _pyCryptodomeDES.MODE_CBC, self.IV) else: raise Exception('Unknown cipher mode!') def encrypt(self, data): return self._cipher.encrypt(data) def decrypt(self, data): return self._cipher.decrypt(data) unicrypto-0.0.10/unicrypto/backends/pycryptodome/RC4.py000066400000000000000000000005621437177004600231460ustar00rootroot00000000000000 from Crypto.Cipher import ARC4 from unicrypto.symmetric import symmetricBASE, cipherMODE class RC4(symmetricBASE): def __init__(self, key): symmetricBASE.__init__(self, key) def setup_cipher(self): self._cipher = ARC4.new(self.key) def encrypt(self, data): return self._cipher.encrypt(data) def decrypt(self, data): return self._cipher.decrypt(data) unicrypto-0.0.10/unicrypto/backends/pycryptodome/TDES.py000066400000000000000000000011471437177004600233150ustar00rootroot00000000000000 from Crypto.Cipher import DES3 from unicrypto.symmetric import symmetricBASE, cipherMODE class TDES(symmetricBASE): def __init__(self, key, mode = cipherMODE.ECB, IV = None): symmetricBASE.__init__(self, key, mode, IV) def setup_cipher(self): if self.mode == cipherMODE.ECB: self._cipher = DES3.new(self.key, DES3.MODE_ECB) elif self.mode == cipherMODE.CBC: self._cipher = DES3.new(self.key, DES3.MODE_CBC, iv=self.IV) else: raise Exception('Unknown cipher mode!') def encrypt(self, data): return self._cipher.encrypt(data) def decrypt(self, data): return self._cipher.decrypt(data) unicrypto-0.0.10/unicrypto/backends/pycryptodome/__init__.py000066400000000000000000000000431437177004600243070ustar00rootroot00000000000000from . import AES, DES, RC4, TDES unicrypto-0.0.10/unicrypto/backends/pycryptodomex/000077500000000000000000000000001437177004600223715ustar00rootroot00000000000000unicrypto-0.0.10/unicrypto/backends/pycryptodomex/AES.py000066400000000000000000000036461437177004600233640ustar00rootroot00000000000000 from Cryptodome.Cipher import AES as _pyCryptodomeAES from Cryptodome.Util import Counter from unicrypto.symmetric import symmetricBASE, cipherMODE class AES(symmetricBASE): def __init__(self, key, mode = cipherMODE.ECB, IV = None, segment_size = 128): symmetricBASE.__init__(self, key, mode, IV, segment_size=segment_size) def setup_cipher(self): if self.mode == cipherMODE.ECB: self._cipher = _pyCryptodomeAES.new(self.key, _pyCryptodomeAES.MODE_ECB) #_pyCryptodomeDES.new(self.key, _pyCryptodomeDES.MODE_ECB) elif self.mode == cipherMODE.CBC: self._cipher = _pyCryptodomeAES.new(self.key, _pyCryptodomeAES.MODE_CBC, iv=self.IV) elif self.mode == cipherMODE.CTR: self._cipher = _pyCryptodomeAES.new(self.key, _pyCryptodomeAES.MODE_CTR, counter=Counter.new(128, initial_value=int.from_bytes(self.IV, byteorder='big', signed=False))) elif self.mode == cipherMODE.CFB: self._cipher = _pyCryptodomeAES.new(self.key, _pyCryptodomeAES.MODE_CFB, iv=self.IV, segment_size=self.segment_size) elif self.mode == cipherMODE.OFB: self._cipher = _pyCryptodomeAES.new(self.key, _pyCryptodomeAES.MODE_OFB, iv=self.IV) elif self.mode == cipherMODE.CCM: self._cipher = _pyCryptodomeAES.new(self.key, _pyCryptodomeAES.MODE_CCM, self.IV, mac_len= self.segment_size) elif self.mode == cipherMODE.GCM: self._cipher = _pyCryptodomeAES.new(self.key, _pyCryptodomeAES.MODE_GCM, self.IV, mac_len= self.segment_size) else: raise Exception('Unknown cipher mode!') def encrypt(self, data, aad = None): if self.mode == cipherMODE.CCM or self.mode == cipherMODE.GCM: self._cipher.update(aad) return self._cipher.encrypt_and_digest(data) else: return self._cipher.encrypt(data) def decrypt(self, data, aad = None, mac = None): if self.mode == cipherMODE.CCM or self.mode == cipherMODE.GCM: self._cipher.update(aad) return self._cipher.decrypt_and_verify(data, mac) else: return self._cipher.decrypt(data)unicrypto-0.0.10/unicrypto/backends/pycryptodomex/DES.py000066400000000000000000000013731437177004600233620ustar00rootroot00000000000000 from Cryptodome.Cipher import DES as _pyCryptodomeDES from unicrypto.symmetric import symmetricBASE, cipherMODE, expand_DES_key class DES(symmetricBASE): def __init__(self, key, mode = cipherMODE.ECB, IV = None): symmetricBASE.__init__(self, key, mode, IV) def setup_cipher(self): if len(self.key) == 7: self.key = expand_DES_key(self.key) if self.mode == cipherMODE.ECB: self._cipher = _pyCryptodomeDES.new(self.key, _pyCryptodomeDES.MODE_ECB) elif self.mode == cipherMODE.CBC: self._cipher = _pyCryptodomeDES.new(self.key, _pyCryptodomeDES.MODE_CBC, self.IV) else: raise Exception('Unknown cipher mode!') def encrypt(self, data): return self._cipher.encrypt(data) def decrypt(self, data): return self._cipher.decrypt(data) unicrypto-0.0.10/unicrypto/backends/pycryptodomex/RC4.py000066400000000000000000000005661437177004600233420ustar00rootroot00000000000000 from Cryptodome.Cipher import ARC4 from unicrypto.symmetric import symmetricBASE, cipherMODE class RC4(symmetricBASE): def __init__(self, key): symmetricBASE.__init__(self, key) def setup_cipher(self): self._cipher = ARC4.new(self.key) def encrypt(self, data): return self._cipher.encrypt(data) def decrypt(self, data): return self._cipher.decrypt(data) unicrypto-0.0.10/unicrypto/backends/pycryptodomex/TDES.py000066400000000000000000000011531437177004600235020ustar00rootroot00000000000000 from Cryptodome.Cipher import DES3 from unicrypto.symmetric import symmetricBASE, cipherMODE class TDES(symmetricBASE): def __init__(self, key, mode = cipherMODE.ECB, IV = None): symmetricBASE.__init__(self, key, mode, IV) def setup_cipher(self): if self.mode == cipherMODE.ECB: self._cipher = DES3.new(self.key, DES3.MODE_ECB) elif self.mode == cipherMODE.CBC: self._cipher = DES3.new(self.key, DES3.MODE_CBC, iv=self.IV) else: raise Exception('Unknown cipher mode!') def encrypt(self, data): return self._cipher.encrypt(data) def decrypt(self, data): return self._cipher.decrypt(data) unicrypto-0.0.10/unicrypto/backends/pycryptodomex/__init__.py000066400000000000000000000000431437177004600244770ustar00rootroot00000000000000from . import AES, DES, RC4, TDES unicrypto-0.0.10/unicrypto/cmac.py000066400000000000000000000002111437177004600171400ustar00rootroot00000000000000from unicrypto.symmetric import AES from unicrypto.backends.cmac import CMAC def AES_CMAC(K, M, length): return CMAC(K, M, length, AES)unicrypto-0.0.10/unicrypto/hashlib.py000066400000000000000000000024001437177004600176510ustar00rootroot00000000000000from abc import ABC, abstractmethod import hashlib as __builtinHashlib from unicrypto import logging class hashBASE(): def __init__(self, data:bytes): self._hash = None self.setup_hash() if data is not None: self._hash.update(data) @abstractmethod def setup_hash(self): #create the hash object here raise NotImplementedError() @abstractmethod def update(self, data): raise NotImplementedError() @abstractmethod def digest(self): raise NotImplementedError() @abstractmethod def hexdigest(self): raise NotImplementedError() def hashselector(name:str, data:bytes = b''): if name.lower() == 'md4': logging.debug('hashlib using "pure" for "%s"' % name) from unicrypto.backends.pure.MD4 import MD4 return MD4(data) if name.lower() in __builtinHashlib.algorithms_available: logging.debug('hashlib using "builtin" for "%s"' % name) return __builtinHashlib.new(name, data) raise NotImplementedError('Algorithm "%s" is not implemented!' % name) def md4hash(data:bytes = b''): return hashselector('md4', data) new = hashselector md4 = md4hash md5 = __builtinHashlib.md5 sha1 = __builtinHashlib.sha1 sha224 = __builtinHashlib.sha224 sha256 = __builtinHashlib.sha256 sha384 = __builtinHashlib.sha384 sha512 = __builtinHashlib.sha512 unicrypto-0.0.10/unicrypto/hashlib/000077500000000000000000000000001437177004600173035ustar00rootroot00000000000000unicrypto-0.0.10/unicrypto/hashlib/MD4.py000066400000000000000000000111331437177004600202400ustar00rootroot00000000000000#!/usr/bin/env python3 # -*- coding: utf-8 -*- # # Copyright © 2019 James Seo (github.com/kangtastic). # # This file is released under the WTFPL, version 2 (wtfpl.net). # # md4.py: An implementation of the MD4 hash algorithm in pure Python 3. # # Description: Zounds! Yet another rendition of pseudocode from RFC1320! # Bonus points for the algorithm literally being from 1992. # # Usage: Why would anybody use this? This is self-rolled crypto, and # self-rolled *obsolete* crypto at that. DO NOT USE if you need # something "performant" or "secure". :P # # Anyway, from the command line: # # $ ./md4.py [messages] # # where [messages] are some strings to be hashed. # # In Python, use similarly to hashlib (not that it even has MD4): # # from .md4 import MD4 # # digest = MD4("BEES").hexdigest() # # print(digest) # "501af1ef4b68495b5b7e37b15b4cda68" # # # Sample console output: # # Testing the MD4 class. # # Message: b'' # Expected: 31d6cfe0d16ae931b73c59d7e0c089c0 # Actual: 31d6cfe0d16ae931b73c59d7e0c089c0 # # Message: b'The quick brown fox jumps over the lazy dog' # Expected: 1bee69a46ba811185c194762abaeae90 # Actual: 1bee69a46ba811185c194762abaeae90 # # Message: b'BEES' # Expected: 501af1ef4b68495b5b7e37b15b4cda68 # Actual: 501af1ef4b68495b5b7e37b15b4cda68 # import struct class MD4: """An implementation of the MD4 hash algorithm.""" width = 32 mask = 0xFFFFFFFF # Unlike, say, SHA-1, MD4 uses little-endian. Fascinating! h = [0x67452301, 0xEFCDAB89, 0x98BADCFE, 0x10325476] def __init__(self, msg=None): """:param ByteString msg: The message to be hashed.""" if msg is None: msg = b"" self.msg = msg # Pre-processing: Total length is a multiple of 512 bits. ml = len(msg) * 8 msg += b"\x80" msg += b"\x00" * (-(len(msg) + 8) % 64) msg += struct.pack("> (MD4.width - n) return lbits | rbits def main(): # Import is intentionally delayed. import sys if len(sys.argv) > 1: messages = [msg.encode() for msg in sys.argv[1:]] for message in messages: print(MD4(message).hexdigest()) else: messages = [b"", b"The quick brown fox jumps over the lazy dog", b"BEES"] known_hashes = [ "31d6cfe0d16ae931b73c59d7e0c089c0", "1bee69a46ba811185c194762abaeae90", "501af1ef4b68495b5b7e37b15b4cda68", ] print("Testing the MD4 class.") print() for message, expected in zip(messages, known_hashes): print("Message: ", message) print("Expected:", expected) print("Actual: ", MD4(message).hexdigest()) print() if __name__ == "__main__": try: main() except KeyboardInterrupt: pass unicrypto-0.0.10/unicrypto/hmac.py000066400000000000000000000016711437177004600171600ustar00rootroot00000000000000from abc import ABC, abstractmethod import hmac as __builtinHMAC from unicrypto import hashlib from unicrypto import logging class hmacBASE(): def __init__(self, key): self.digest_size = None self.block_size = None self.name = None self._key = key self._hash = None self.setup_hash() @abstractmethod def setup_hash(self): #create the hash object here raise NotImplementedError() @abstractmethod def update(self, data): raise NotImplementedError() @abstractmethod def digest(self): raise NotImplementedError() @abstractmethod def hexdigest(self): raise NotImplementedError() @abstractmethod def copy(self): raise NotImplementedError() @staticmethod def compare_digest(self, a, b): raise NotImplementedError() def hmacselector(key:bytes, msg:bytes = None, digestmod:str = ''): logging.debug('hmac using "builtin" for "%s"' % digestmod) return __builtinHMAC.new(key, msg, digestmod) new = hmacselector unicrypto-0.0.10/unicrypto/kdf.py000066400000000000000000000003171437177004600170100ustar00rootroot00000000000000from unicrypto import hmac from unicrypto.backends.kdf import KDF_CounterMode as KDF_CounterMode_inner def KDF_CounterMode(KI, Label, Context, L): return KDF_CounterMode_inner(KI, Label, Context, L, hmac) unicrypto-0.0.10/unicrypto/pbkdf2.py000066400000000000000000000024441437177004600174170ustar00rootroot00000000000000 #https://codereview.stackexchange.com/questions/87538/python-pbkdf2-using-core-modules from unicrypto import hmac import struct from unicrypto import hashlib def pbkdf2(password, salt, iters, keylen, digestmod = hashlib.sha1): """Run the PBKDF2 (Password-Based Key Derivation Function 2) algorithm and return the derived key. The arguments are: password (bytes or bytearray) -- the input password salt (bytes or bytearray) -- a cryptographic salt iters (int) -- number of iterations keylen (int) -- length of key to derive digestmod -- a cryptographic hash function: either a module supporting PEP 247, a hashlib constructor, or (in Python 3.4 or later) the name of a hash function. For example: >>> import hashlib >>> from binascii import hexlify, unhexlify >>> password = b'Squeamish Ossifrage' >>> salt = unhexlify(b'1234567878563412') >>> hexlify(pbkdf2(password, salt, 500, 16, hashlib.sha1)) b'9e8f1072bdf5ef042bd988c7da83e43b' """ h = hmac.new(password, digestmod=digestmod) def prf(data): hm = h.copy() hm.update(data) return bytearray(hm.digest()) key = bytearray() i = 1 while len(key) < keylen: T = U = prf(salt + struct.pack('>i', i)) for _ in range(iters - 1): U = prf(U) T = bytearray(x ^ y for x, y in zip(T, U)) key += T i += 1 return key[:keylen]unicrypto-0.0.10/unicrypto/symmetric.py000066400000000000000000000055401437177004600202630ustar00rootroot00000000000000from abc import ABC, abstractmethod from unicrypto import get_preferred_cipher import enum from unicrypto import logging class cipherMODE(enum.Enum): ECB = enum.auto() CBC = enum.auto() CTR = enum.auto() CCM = enum.auto() CFB = enum.auto() OFB = enum.auto() GCM = enum.auto() MODE_ECB = cipherMODE.ECB MODE_CBC = cipherMODE.CBC MODE_CTR = cipherMODE.CTR MODE_CCM = cipherMODE.CCM MODE_CFB = cipherMODE.CFB MODE_OFB = cipherMODE.OFB MODE_GCM = cipherMODE.GCM class symmetricBASE: def __init__(self, key:bytes, mode:cipherMODE = cipherMODE.ECB, IV:bytes = None, segment_size:int= 128): self.key = key self.mode = mode self.IV = IV self.segment_size = segment_size self._cipher = None self.setup_cipher() @abstractmethod def setup_cipher(self): #create the _cipher object here raise NotImplementedError() @abstractmethod def encrypt(self, data): raise NotImplementedError() @abstractmethod def decrypt(self): raise NotImplementedError() @abstractmethod def update(self, data): raise NotImplementedError() @abstractmethod def digest(self): raise NotImplementedError() # from impacket def expand_DES_key(key): # Expand the key from a 7-byte password key into a 8-byte DES key key = key[:7] key += b'\x00'*(7-len(key)) s = (((key[0] >> 1) & 0x7f) << 1).to_bytes(1, byteorder = 'big') s += (((key[0] & 0x01) << 6 | ((key[1] >> 2) & 0x3f)) << 1).to_bytes(1, byteorder = 'big') s += (((key[1] & 0x03) << 5 | ((key[2] >> 3) & 0x1f)) << 1).to_bytes(1, byteorder = 'big') s += (((key[2] & 0x07) << 4 | ((key[3] >> 4) & 0x0f)) << 1).to_bytes(1, byteorder = 'big') s += (((key[3] & 0x0f) << 3 | ((key[4] >> 5) & 0x07)) << 1).to_bytes(1, byteorder = 'big') s += (((key[4] & 0x1f) << 2 | ((key[5] >> 6) & 0x03)) << 1).to_bytes(1, byteorder = 'big') s += (((key[5] & 0x3f) << 1 | ((key[6] >> 7) & 0x01)) << 1).to_bytes(1, byteorder = 'big') s += ( (key[6] & 0x7f) << 1).to_bytes(1, byteorder = 'big') return s # def deriveKey(baseKey): # 2.2.11.1.3 Deriving Key1 and Key2 from a Little-Endian, Unsigned Integer Key # Let I be the little-endian, unsigned integer. # Let I[X] be the Xth byte of I, where I is interpreted as a zero-base-index array of bytes. # Note that because I is in little-endian byte order, I[0] is the least significant byte. # Key1 is a concatenation of the following values: I[0], I[1], I[2], I[3], I[0], I[1], I[2]. # Key2 is a concatenation of the following values: I[3], I[0], I[1], I[2], I[3], I[0], I[1] key = baseKey.to_bytes(4, byteorder='little', signed=False) #pack('