ffU~ddlZddlmZddlmZmZmZmZmZm Z eddZ dZ dZ dZ d Zedd ZdS) N)_create_cipher)load_pycryptodome_raw_lib VoidPointer SmartPointerc_size_t c_uint8_ptrc_uintzCrypto.Cipher._raw_eksblowfishaa int EKSBlowfish_start_operation(const uint8_t key[], size_t key_len, const uint8_t salt[16], size_t salt_len, unsigned cost, unsigned invert, void **pResult); int EKSBlowfish_encrypt(const void *state, const uint8_t *in, uint8_t *out, size_t data_len); int EKSBlowfish_decrypt(const void *state, const uint8_t *in, uint8_t *out, size_t data_len); int EKSBlowfish_stop_operation(void *state); c d |d}|d}|d}n1#t$r$}tdt|zd}~wwxYw|dd}t |t vrt dt |ztj}tj }t}|t|tt |t|tt |t|tt||} | rt d | zt!||S) zThis method instantiates and returns a smart pointer to a low-level base cipher. It will absorb named parameters in the process.keysaltcostzMissing EKSBlowfish parameter: NinvertTz+Incorrect EKSBlowfish key length (%d bytes)z3Error %X while instantiating the EKSBlowfish cipher)popKeyError TypeErrorstrlenkey_size ValueError_raw_blowfish_libEKSBlowfish_start_operationEKSBlowfish_stop_operationrrrr int address_ofrget) dict_parametersr r r erstart_operationstop_operationvoid_presults |/builddir/build/BUILD/imunify360-venv-2.3.5/opt/imunify360/venv/lib64/python3.11/site-packages/Crypto/Cipher/_EKSBlowfish.py_create_base_cipherr#=s D!!%((""6**""6** DDD9CFFBCCCD  4 0 0F 3xxxFSQRRR'CO&AN ]]F _[--%c#hh//(..%c$ii00#D\\#CKK00#..00 22F#N!"## #  n 5 55s?A A0 A++A0cV|||d}ttjt||fi|S)aCreate a new EKSBlowfish cipher Args: key (bytes, bytearray, memoryview): The secret key to use in the symmetric cipher. Its length can vary from 0 to 72 bytes. mode (one of the supported ``MODE_*`` constants): The chaining mode to use for encryption or decryption. salt (bytes, bytearray, memoryview): The salt that bcrypt uses to thwart rainbow table attacks cost (integer): The complexity factor in bcrypt invert (bool): If ``False``, in the inner loop use ``ExpandKey`` first over the salt and then over the key, as defined in the `original bcrypt specification `_. If ``True``, reverse the order, as in the first implementation of `bcrypt` in OpenBSD. :Return: an EKSBlowfish object )r r r)rsysmodules__name__)r moder r rkwargss r"newr*^s484& : :F #+h/d E Ef E EEI)r% Crypto.CipherrCrypto.Util._raw_apirrrrrr rr#r*MODE_ECB block_sizerangerr+r"r5s> ((((((7777777777777777.-(   .666BFFF@  5F  r+