AnonSec Shell
Server IP : 85.193.89.191  /  Your IP : 3.143.218.15
Web Server : Apache
System : Linux 956367-cx40159.tmweb.ru 3.10.0-1160.105.1.el7.x86_64 #1 SMP Thu Dec 7 15:39:45 UTC 2023 x86_64
User : bitrix ( 600)
PHP Version : 8.1.27
Disable Function : NONE
MySQL : OFF  |  cURL : OFF  |  WGET : ON  |  Perl : ON  |  Python : ON  |  Sudo : ON  |  Pkexec : ON
Directory :  /lib/python2.7/site-packages/ansible/plugins/connection/

Upload File :
current_dir [ Writeable ] document_root [ Writeable ]

 

Command :


[ HOME ]     

Current File : /lib/python2.7/site-packages/ansible/plugins/connection/local.pyc
�
��\c@`s6ddlmZmZmZeZdZddlZddlZddl	Z	ddl
Z
ddlZddlj
ZddlmZddlmZmZddlmZmZddlmZmZmZddlmZydd	lmZWn*ek
rdd
l m!Z!e!�ZnXdefd��YZ"dS(
i(tabsolute_importtdivisiontprint_functions|
    connection: local
    short_description: execute on controller
    description:
        - This connection plugin allows ansible to execute tasks on the Ansible 'controller' instead of on a remote host.
    author: ansible (@core)
    version_added: historical
    notes:
        - The remote user is ignored, the user with which the ansible CLI was executed is used instead.
N(t	selectors(tAnsibleErrortAnsibleFileNotFound(t	text_typetbinary_type(tto_bytest	to_nativetto_text(tConnectionBase(tdisplay(tDisplayt
ConnectioncB`sMeZdZdZeZd�Zded�Zd�Z	d�Z
d�ZRS(s Local based connections tlocalcC`sStj�|j_|jsOtjdj|jj�d|jj�t	|_n|S(s/ connect to the local host; nothing to do here u(ESTABLISH LOCAL CONNECTION FOR USER: {0}thost(
tgetpasstgetusert
_play_contexttremote_usert
_connectedRtvvvtformattremote_addrtTrue(tself((sD/usr/lib/python2.7/site-packages/ansible/plugins/connection/local.pyt_connect;s
	(cC`s�tt|�j|d|d|�tjd�tjrKtjj�dnd}tj	dj
t|��d|jj
�tjd�t|ttf�r�t|�}ntt|�}tj|dt|ttf�d	|d
tjdtjdtj�}tjd
�|jjry|rytj|jtjtj|jtj�tjB�tj|jtjtj|jtj�tjB�tj�}|j |jtj!�|j |jtj!�d}zx|j"|�r�|j#|�r�|j$|jj%�}|s+|j&�\}	}
t'dt(|���nx\|D]T\}}|j)|jkrb|jj*�}
q2|j)|jkr2|jj*�}
q2q2W|
s�|j&�\}	}
t'dt(|���n||
7}q�WWd|j+�X|j"|�s|j,j-t|jj.dd�d�ntj|jtjtj|jtj�tj@�tj|jtjtj|jtj�tj@�ntjd�|j&|�\}	}
tjd�tjd�|j/|	|
fS(s! run a command on the local host tin_datatsudoablesin local.exec_command()iuEXEC {0}Rsopening command with Popen()tshellt
executabletstdintstdouttstderrs!done running command with Popen()ts:timeout waiting for privilege escalation password prompt:
s;privilege output closed while waiting for password prompt:
Nterrorstsurrogate_or_stricts
s!getting output with communicate()sdone communicatingsdone with local.exec_command()(0tsuperRtexec_commandRtdebugtCtDEFAULT_EXECUTABLEtsplittNoneRRR
RRt
isinstanceRRRtmapt
subprocesstPopentPIPEtprompttfcntlR!tF_SETFLtF_GETFLtost
O_NONBLOCKR"RtDefaultSelectortregistert
EVENT_READtcheck_become_successtcheck_password_prompttselectttimeouttcommunicateRR	tfileobjtreadtcloseR twritetbecome_passt
returncode(RtcmdRRRtptselectort
become_outputteventsR!R"tkeyteventtchunk((sD/usr/lib/python2.7/site-packages/ansible/plugins/connection/local.pyR'Hs`"
"(
		
22#)36


cC`stt|�j||�tjdj||�d|jj�tj	j
t|dd��sztdjt
|����ny,tjt|dd�t|dd��Wnntjk
r�tdjt
|�t
|����n7tk
r}tdjt
|�t
|����nXdS(	s% transfer a file from local to local uPUT {0} TO {1}RR$R%s"file or module does not exist: {0}s(failed to copy: {0} and {1} are the sames#failed to transfer file to {0}: {1}N(R&Rtput_fileRRRRRR6tpathtexistsRRR	tshutiltcopyfiletErrorRtIOError(Rtin_pathtout_pathte((sD/usr/lib/python2.7/site-packages/ansible/plugins/connection/local.pyRN�s%,'cC`sRtt|�j||�tjdj||�d|jj�|j||�dS(s6 fetch a file from local to local -- for copatibility uFETCH {0} TO {1}RN(	R&Rt
fetch_fileRRRRRRN(RRURV((sD/usr/lib/python2.7/site-packages/ansible/plugins/connection/local.pyRX�s%cC`s
t|_dS(s. terminate the connection; nothing to do here N(tFalseR(R((sD/usr/lib/python2.7/site-packages/ansible/plugins/connection/local.pyRB�sN(t__name__t
__module__t__doc__t	transportRthas_pipeliningRR,R'RNRXRB(((sD/usr/lib/python2.7/site-packages/ansible/plugins/connection/local.pyR5s	
C		(#t
__future__RRRttypet
__metaclass__t
DOCUMENTATIONR6RQR/R3Rtansible.constantst	constantsR)tansible.compatRtansible.errorsRRtansible.module_utils.sixRRtansible.module_utils._textRR	R
tansible.plugins.connectionRt__main__RtImportErrortansible.utils.displayR
R(((sD/usr/lib/python2.7/site-packages/ansible/plugins/connection/local.pyt<module>s&



Anon7 - 2022
AnonSec Team