AlkantarClanX12

Your IP : 18.189.184.237


Current Path : /proc/self/root/opt/alt/python33/lib64/python3.3/__pycache__/
Upload File :
Current File : //proc/self/root/opt/alt/python33/lib64/python3.3/__pycache__/getpass.cpython-33.pyc

�
��f�c@s4dZddlZddlZddlZddlZddlZdddgZGdd�de�Zdddd	�Z
ddd
d�Zdddd
�Zddddd�Z
dd�Zy ddlZejejfWnIeefk
r)yddlZWnek
reZYnXeZYnXe
ZdS(u�Utilities to get a password and/or the current user name.

getpass(prompt[, stream]) - Prompt for a password, with echo turned off.
getuser() - Get the user name from the environment or password database.

GetPassWarning - This UserWarning is issued when getpass() cannot prevent
                 echoing of the password contents while reading.

On Windows, the msvcrt module will be used.
On the Mac EasyDialogs.AskPassword is used, if available.

iNugetpassugetuseruGetPassWarningcBs|EeZdZdS(uGetPassWarningN(u__name__u
__module__u__qualname__(u
__locals__((u,/opt/alt/python33/lib64/python3.3/getpass.pyuGetPassWarningsu
Password: c.Cs5d}tj��}yjtjdtjtjB�}tj|d�}|j	|�tj
|�}|j	|�|s~|}nWn�tk
r}zm|j�yt
jj�}Wn-ttfk
r�d}t||�}YnXt
j}|s�t
j}nWYdd}~XnX|dk	ry�tj|�}|dd�}	|	dtjM<tj}
ttd�rw|
tjO}
nz,tj||
|	�t||d|�}Wdtj||
|�|j�XWqtjk
r|dk	r��n||k	r|j�nt||�}YqXn|jd�|SWdQXdS(uPrompt for a password, with echo turned off.

    Args:
      prompt: Written on stream to ask for the input.  Default: 'Password: '
      stream: A writable file object to display the prompt.  Defaults to
              the tty.  If no tty is available defaults to sys.stderr.
    Returns:
      The seKr3t input.
    Raises:
      EOFError: If our input tty or stdin was closed.
      GetPassWarning: When we were unable to turn echo off on the input.

    Always restores terminal settings before returning.
    u/dev/ttyuw+NiuTCSASOFTuinputu
(uNoneu
contextlibu	ExitStackuosuopenuO_RDWRuO_NOCTTYuiouFileIOu
enter_contextu
TextIOWrapperuOSErrorucloseusysustdinufilenouAttributeErroru
ValueErrorufallback_getpassustderrutermiosu	tcgetattruECHOu	TCSAFLUSHuhasattruTCSASOFTu	tcsetattru
_raw_inputuflushuerroruwrite(upromptustreamupasswdustackufduttyuinputueuoldunewutcsetattr_flags((u,/opt/alt/python33/lib64/python3.3/getpass.pyuunix_getpasssR



		

uunix_getpasscCs�tjtjk	rt||�Sddl}x|D]}|j|�q2Wd}xi|j�}|dksv|dkrzPn|dkr�t�n|dkr�|dd	�}qR||}qR|jd�|jd�|S(
u9Prompt for password with echo off, using Windows getch().iNuu
u
uuii����(usysustdinu	__stdin__ufallback_getpassumsvcrtuputwchugetwchuKeyboardInterrupt(upromptustreamumsvcrtucupw((u,/opt/alt/python33/lib64/python3.3/getpass.pyuwin_getpassbs$

	


uwin_getpasscCsEtjdtdd�|s(tj}ntdd|�t||�S(Nu%Can not control echo on the terminal.u
stackleveliu&Warning: Password input may be echoed.ufile(uwarningsuwarnuGetPassWarningusysustderruprintu
_raw_input(upromptustream((u,/opt/alt/python33/lib64/python3.3/getpass.pyufallback_getpassysufallback_getpassucCs�|stj}n|s$tj}nt|�}|rP|j|�|j�n|j�}|skt�n|ddkr�|dd�}n|S(Niu
i����i����(usysustderrustdinustruwriteuflushureadlineuEOFError(upromptustreamuinputuline((u,/opt/alt/python33/lib64/python3.3/getpass.pyu
_raw_input�s

	u
_raw_inputcCsPx*dD]"}tjj|�}|r|SqWddl}|jtj��dS(u�Get the username from the environment or password database.

    First try various environment variables, then the password
    database.  This works on Windows as long as USERNAME is set.

    uLOGNAMEuUSERuLNAMEuUSERNAMEiN(uLOGNAMEuUSERuLNAMEuUSERNAME(uosuenvironugetupwdugetpwuidugetuid(unameuuserupwd((u,/opt/alt/python33/lib64/python3.3/getpass.pyugetuser�s
(u__doc__u
contextlibuiouosusysuwarningsu__all__uUserWarninguGetPassWarninguNoneuunix_getpassuwin_getpassufallback_getpassu
_raw_inputugetuserutermiosu	tcgetattru	tcsetattruImportErroruAttributeErrorumsvcrtugetpass(((u,/opt/alt/python33/lib64/python3.3/getpass.pyu<module>s,D