AlkantarClanX12

Your IP : 3.15.31.27


Current Path : /opt/alt/python310/lib64/python3.10/__pycache__/
Upload File :
Current File : //opt/alt/python310/lib64/python3.10/__pycache__/getpass.cpython-310.opt-2.pyc

o

6��ff�@s�	ddlZddlZddlZddlZddlZgd�ZGdd�de�Zddd�Zddd	�Z	dd
d�Z
dd
d�Zdd�Zzddl
Z
e
je
jfWn"eefygzddlZWn
eyae
ZYYdSwe	ZYdSweZdS)�N)�getpass�getuser�GetPassWarningc@seZdZdS)rN)�__name__�
__module__�__qualname__�rr�./opt/alt/python310/lib64/python3.10/getpass.pyrsr�
Password: c

Cs�	d}t����}z%t�dtjtjB�}t�|d�}|�|�t�	|�}|�|�|s,|}Wn/t
y\|��ztj
��}WnttfyQd}t||�}Ynwtj
}|sZtj}Ynw|dur�zLt�|�}|dd�}|dtjM<tj}	ttd�r�|	tjO}	zt�||	|�t|||d�}Wt�||	|�|��nt�||	|�|��wWntjy�|dur��||ur�|��t||�}Ynw|�d�|Wd�S1s�wYdS)Nz/dev/ttyzw+��TCSASOFT)�input�
)�
contextlib�	ExitStack�os�open�O_RDWR�O_NOCTTY�io�FileIO�
enter_context�
TextIOWrapper�OSError�close�sys�stdin�fileno�AttributeError�
ValueError�fallback_getpass�stderr�termios�	tcgetattrZECHOZ	TCSAFLUSH�hasattrr�	tcsetattr�
_raw_input�flush�error�write)
�prompt�streamZpasswd�stack�fdZttyr
�old�newZtcsetattr_flagsrrr	�unix_getpasssd



����



��
$�r0cCs�	tjtjurt||�S|D]}t�|�qd}	t��}|dks%|dkr&n|dkr,t�|dkr7|dd�}n||}qt�d�t�d�|S)N���
r�����)rr�	__stdin__r �msvcrtZputwchZgetwch�KeyboardInterrupt)r*r+�cZpwrrr	�win_getpassas&
�


r;cCs0tjdtdd�|s
tj}td|d�t||�S)Nz%Can not control echo on the terminal.�)�
stacklevelz&Warning: Password input may be echoed.)�file)�warnings�warnrrr!�printr&)r*r+rrr	r xs�
r r1cCs�|stj}|s
tj}t|�}|r7z|�|�Wnty2|�|jd�}|�|j�}|�|�Ynw|�	�|�
�}|s?t�|ddkrK|dd�}|S)N�replacer6r)rr!r�strr)�UnicodeEncodeError�encode�encoding�decoder'�readline�EOFError)r*r+r
�linerrr	r&�s(�r&cCs>	dD]}tj�|�}|r|Sqddl}|�t���dS)N)ZLOGNAMEZUSERZLNAMEZUSERNAMEr)r�environ�get�pwd�getpwuid�getuid)�name�userrMrrr	r�s�r)r
N)r1NN)rrrrr?�__all__�UserWarningrr0r;r r&rr"r#r%�ImportErrorrr8rrrrr	�<module>s2

D

	�
�