o
    j                     @   s   d dl mZ G dd dZdS )    )Tuplec                   @   s   e Zd Zdd ZdefddZdefddZdefdd	Zdefd
dZ	dede
defddZdede
defddZdedefddZdedeeeef fddZdS )
ClientAuthc                 C   s
   || _ d S )N)settings)selfr    r   /root/aizidognhua/tmp/workspace/projects/ec89d86c-575f-41c9-af57-ac45cbdbf775/venv/lib/python3.10/site-packages/asyauth/protocols/__init__.py__init__   s   
zClientAuth.__init__returnc                 C      t  )z*
		Returns the initial sequence number.
		NotImplementedErrorr   r   r   r   get_seq_number      zClientAuth.get_seq_numberc                 C   r
   )z3
		Checks if integrity protection was negotiated
		r   r   r   r   r   signing_needed   r   zClientAuth.signing_neededc                 C   r
   )z.
		Checks if confidentiality was negotiated
		r   r   r   r   r   encryption_needed   r   zClientAuth.encryption_neededc                 C   r
   )z(
		Returns the negotiated session key
		r   r   r   r   r   get_session_key   r   zClientAuth.get_session_keydata
seq_numberc                       t  )z
		Signs a message. 
		r   r   r   r   r   r   r   sign       zClientAuth.signc                    r   )z
		Encrypts a message. 
		r   r   r   r   r   encrypt&   r   zClientAuth.encryptc                    r   )z9
		Decrypts message. Also performs integrity checking.
		r   )r   r   r   r   r   decrypt,   r   zClientAuth.decrypttokenc                    s   dS )z
		This function is called (multiple times depending on the protocol) to perform authentication.

		returns a tuple of (token, to_continue, error)
		)NNNr   )r   r   kwargsr   r   r   authenticate3   s   zClientAuth.authenticateN)__name__
__module____qualname__r   boolr   r   r   bytesr   intr   r   r   r   	Exceptionr   r   r   r   r   r      s     r   N)typingr   r   r   r   r   r   <module>   s    