grthtrhthjhtyjytjytkergtrhtrjytjerhrfh4:24 29/09/2026a XC?hëã@s2ddlZz ddlZWn.eyBejdkr6edƒ‚nedƒ‚Yn0ddlZddlZddl m Z ddl m ZejejdZe ƒZGdd „d ed d ƒƒZd%dd œd d „Zd&dd„ZgZdd œdd„ZeddddƒeddddƒdD](Zeddeddeeƒdd �rä�qqäeddd d!ƒed"dd#d$ƒ[[dS)'éNZwin32z,The crypt module is not supported on Windowsz;The required _crypt module was not built as part of CPython)Ú SystemRandom)Ú namedtuplez./c@seZdZdd„ZdS)Ú_MethodcCs d |j¡S)Nz)ÚformatÚname)Úself©rú*/opt/alt/python39/lib64/python3.9/crypt.pyÚ__repr__sz_Method.__repr__N)Ú__name__Ú __module__Ú __qualname__r rrrr rsrz name ident salt_chars total_size©ÚroundscCsB|durtd}|dur4t|tƒs4t|jj›d�ƒ‚|js@d}nd|j›d�}|jrÂ|jddkrÂ|durpd}n@t |d¡}|d|>kr’tdƒ‚d |kr¦d ks°ntd ƒ‚||d ›d�7}n^|jd v�r|du�r d|krìdksöntdƒ‚|d|›d�7}n|du�r t|›d�ƒ‚|d  dd„t |j ƒDƒ¡7}|S)Nrz+ object cannot be interpreted as an integerÚú$Ú2é ézrounds must be a power of 2ééz%rounds out of the range 2**4 to 2**31Z02d)Ú5Ú6ièiÿÉš;z+rounds out of the range 1000 to 999_999_999zrounds=z$ doesn't support the rounds argumentcss|]}t t¡VqdS©N)Ú_srZchoiceÚ _saltchars)Ú.0Úcharrrr Ú Bózmksalt..) ÚmethodsÚ isinstanceÚintÚ TypeErrorÚ __class__r ZidentÚ bit_lengthÚ ValueErrorÚjoinÚrangeZ salt_chars)ÚmethodrÚsZ log_roundsrrr Úmksalt s2    r+cCs&|dust|tƒrt|ƒ}t ||¡Sr)r!rr+Ú_cryptÚcrypt)ZwordÚsaltrrr r-Fs r-c Gs¢t|g|¢RŽ}|tƒd|<t||d�}d}ztd|ƒ}Wn@ty|}z(|jtjkrfWYd}~dS‚WYd}~n d}~00|ržt|ƒ|jkržt   |¡dSdS)NZMETHOD_rrFT) rÚglobalsr+r-ÚOSErrorÚerrnoZEINVALÚlenZ total_sizer Úappend)rrÚargsr)r.ÚresultÚerrr Ú _add_methodXs   r7ZSHA512rééjZSHA256ré?)ÚbÚyÚarZBLOWFISHréé;ZMD5Ú1éé"ZCRYPTéé )N)N)ÚsysÚ_sysr,ÚModuleNotFoundErrorÚplatformÚ ImportErrorr1ÚstringZ_stringZrandomrZ _SystemRandomÚ collectionsrZ _namedtupleZ ascii_lettersZdigitsrrrr+r-r r7Z_vr2rrrr Ús2       &