gvdZddlZddlZddlmZmZddlmZmZmZddl m Z dZ ej fde de fd Zd 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 . Copyright © 2019 Cloud Linux Software Inc. This software is also available under ImunifyAV commercial license, see N)datetime timedelta) ConfigFileMalwareScanScheduleMalwareScanScheduleInterval) LicenseCLNc&t|dzS)NM)str) intensity_rams S/opt/imunify360/venv/lib/python3.11/site-packages/imav/malwarelib/utils/__init__.py get_memoryr"s }   ## full_pathreturnc|}|tj||S)zCalculate hash from full path)updateosfsencode hexdigest)r hash_provider hash_objects r hash_pathr&s=-//Kr{9--...  " ""rc(tjrdStjtjtjfvrdStjtdz}|j }dd|ddi}t| |dS) z When ImunifyAV+ falls to free license, we should reset scheduled scanner settings to monthly mode (daily and weekly modes are not supported in free version) N)daysMALWARE_SCAN_SCHEDULEmonth)interval day_of_monthhour)path) ris_valid_av_plusrINTERVALrWEEKDAYrtodayrdayrdict_to_config)config_file_pathtomorrownext_daynew_datas r reset_malware_scheduler/-s "$$##(#', ~)"3"3"33H|H$" " H$%%%44X>>>>>r)N)__doc__hashlibrrr defence360agent.contracts.configrrr!defence360agent.contracts.licenserrsha256r rr/rr r6s* (((((((( 988888$$$-4N###s####??????r