관리-도구
편집 파일: queue_supervisor_sync.cpython-311.opt-1.pyc
� ��gl � � � d Z ddlZddlZddlmZmZmZ ddlmZ ddl m Z mZ ddlm Z ddlmZ ej e� � Z G d� d � � ZdS ) u This program is free software: you can redistribute it and/or modify it under the terms of the GNU General Public License as published by the Free Software Foundation, either version 3 of the License, or (at your option) any later version. This program is distributed in the hope that it will be useful, but WITHOUT ANY WARRANTY; without even the implied warranty of MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU General Public License for more details. You should have received a copy of the GNU General Public License along with this program. If not, see <https://www.gnu.org/licenses/>. Copyright © 2019 Cloud Linux Software Inc. This software is also available under ImunifyAV commercial license, see <https://www.imunify360.com/legal/eula> � N)�MalwareScanResourceType�MalwareScanType�QueuedScanState)� DetachedState)�QueuedScanBase� ScanQueue)�create_task_and_log_exceptions)�MessageTypec �~ � e Zd Z e� � Zdd�Z ddefd�Zd� Zd� Z dd�Z d � Zd � Zd� Z d� Zd � Zdefd�Zd� ZdS )�QueueSupervisorSyncNc �� � |pt j � � | _ || _ | j j }|rD|j � � � t j t j fv rt j |_ d S d S d S �N)�asyncio�get_event_loop�loop�sink�queue�current_scan� detached_scan�get_detached_process_stater �RUNNING�FINISHEDr �running�state)�selfr r r s �_/opt/imunify360/venv/lib/python3.11/site-packages/imav/malwarelib/scan/queue_supervisor_sync.py�__init__zQueueSupervisorSync.__init__) s� � ��4�G�2�4�4�� ��� ��z�.��� 9��*�E�E�G�G��%�}�'=�>�?� ?� "1�!8�L���� 9� 9�?� ?� F� resource_typec � �� K � t � d|j d� |� � � � | j j }|D ]:}| j � ||�� � x}r| j � |� � �;|rA|j |v r8|j |k r-|j � | j d|j �� � � d {V �� | j j |f||d�|��� d {V �� | � � � d S )NzQueuing %s scan for %s�, )�pathr T)r �kill�scan_started)r � prioritize)�logger�info�value�joinr r �find�remover"