PATH:
opt
/
imunify360
/
venv
/
lib
/
python3.11
/
site-packages
/
imav
/
malwarelib
/
scan
/
__pycache__
/
Editing: scan_result.cpython-311.pyc
� e��i�% � �< � d Z ddlZddlZddlZddlmZ ddlmZ ddlm Z m Z ddlmZ ddl mZ ddlmZ dd lmZ dd lmZ ddlmZ ddlmZ ej e� � Zg d �Zg e�d�d�d�Zg d�Z G d� d� � Zd� Z d� Z! G d� d� � Z" G d� d� � Z#dS )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��wraps)�NamedTemporaryFile)�Any�Dict)�uuid4)� HookEvent)� hosting_panel)�encode_filename)�Malware)�MalwareScanType)�fill_results_owner)� intensity_cpu�intensity_io� intensity_ram� detect_elf�use_filters�follow_symlinks�exclude_patterns� file_patterns)r r r r r r c �: � e Zd Zd� Zd� Zd d�Zd� Zd� Zd� Zd� Z dS ) � ScanResultc � � g | _ d| _ d | _ g | _ d x| _ | _ i | _ || _ || _ || _ d | _ d S )Nr )�scans�total_files�error�errors�_begin_time� _end_time�_aggregated_results�_path�_scan_id� _scan_type�args)�self�path�scan_id� scan_types �U/opt/imunify360/venv/lib/python3.11/site-packages/imav/malwarelib/scan/scan_result.py�__init__zScanResult.__init__A sV � ��� ������ ����,0�0���4�>�#%�� ��� ��� �#����� � � � c �V � | j t j t j t j fv S �N)r# r � BACKGROUND� ON_DEMAND�USER�r% s r) �is_detachedzScanResult.is_detachedO s( � ����&��%�� �# � � r+ Nc �. � |r|| _ |r || _ d S d S r- )r r )r% � begin_time�end_times r) �set_start_stopzScanResult.set_start_stopV s/ � �� *�)�D��� &�%�D�N�N�N� &� &r+ c �� � | j | j | j | j | j | j | j | j d�| � � � rd ni d�}| j r| j |d d<